public void GetResultAsyncShouldReturnFailForQueryableWithCountOutsideRange(CountInRange <int> sut, [RuleContext] RuleContext context) { sut.Min = 1; sut.Max = 2; Assert.That(() => sut.GetResultAsync(new[] { 1, 2, 3 }.AsQueryable(), context), Is.FailingValidationResult); }
public void GetResultAsyncShouldReturnPassForQueryableWithCountInRange(CountInRange <int> sut, [RuleContext] RuleContext context) { sut.Min = 1; sut.Max = 3; Assert.That(() => sut.GetResultAsync(new[] { 1, 2 }.AsQueryable(), context), Is.PassingValidationResult); }