public void ReturnsEverythingFieldIsNullOrWhiteSpace() { var sut = new DummyEntity(); var list = sut.ShapeDataObject() as IDictionary <string, object>; Assert.Equal(sut.Fizz, list?["Fizz"]); Assert.Equal(sut.Buzz, list?["Buzz"]); Assert.Equal(sut.Id, list?["Id"]); }
public void ShapeData(string field, string key) { var sut = new DummyEntity(); var list = sut.ShapeDataObject(field) as IDictionary <string, object>; Assert.Equal(sut.Fizz, list?[key]); Assert.Throws <KeyNotFoundException>(() => list?["Buzz"]); Assert.Throws <KeyNotFoundException>(() => list?["Id"]); }