public void NotExistsValue() { //arrange var filter = new InvalidCaseFilter { NotExistsValue = "WrongEnumName" }; //act //asssert Assert.ThrowsAny <Exception>(() => InvalidCasesTestsData.Items.AutoFilter(filter)); }
public void NotExistsProperty() { //arrange var filter = new InvalidCaseFilter { NotExistsProperty = "First" }; //act //asssert Assert.ThrowsAny <Exception>(() => InvalidCasesTestsData.Items.AutoFilter(filter)); }
public void NotExistsProperty() { //arrange var filter = new InvalidCaseFilter { NotExistsProperty = "First" }; //act var result = InvalidCasesTestsData.Items.AutoFilter(filter).ToList(); //assert Assert.Equal(InvalidCasesTestsData.Items.Count, result.Count); }
public void NotExistsProperty() { //arrange Init(); var filter = new InvalidCaseFilter { NotExistsProperty = "First" }; //act //asssert Assert.ThrowsAny <Exception>(() => Context.InvalidCaseItems.AutoFilter(filter).ToList()); }
public void NotExistsValue() { //arrange Init(); var filter = new InvalidCaseFilter { NotExistsValue = "WrongEnumName" }; //act //asssert Assert.ThrowsAny <Exception>(() => Context.InvalidCaseItems.AutoFilter(filter).ToList()); }
public void WithTargetType() { //arrange var filter = new InvalidCaseFilter { EnumTargetType = "Default" }; //act var filtered = InvalidCasesTestsData.Items.AutoFilter(filter).ToList(); //asssert Assert.Equal(1, filtered.Count); Assert.Equal(TargetEnum.Default, filtered[0].TargetEnum); }
public void NotExistsProperty() { //arrange Init(); var filter = new InvalidCaseFilter { NotExistsProperty = "First" }; //act var result = Context.InvalidCaseItems.AutoFilter(filter).ToList(); //asssert Assert.Equal(result.Count, Context.InvalidCaseItems.Count()); }