protected override async Task RunScenario() { for (var i = 200; i < 400; i++) { ClosedPcts.Add(TestSubject.ClosedPct); ShouldAccepts.Add(TestSubject.ShouldAccept()); TestSubject.LogSuccessResponse(i.ToString()); await Task.Delay(5); } }
protected override async Task RunScenario() { for (var i = 0; i < 100; i++) { ClosedPcts.Add(TestSubject.ClosedPct); ShouldAccepts.Add(TestSubject.ShouldAccept()); TestSubject.LogFailureResponse(HttpStatusCode.InternalServerError.ToString()); await Task.Delay(5); } for (var i = 0; i < 100; i++) { ClosedPcts.Add(TestSubject.ClosedPct); ShouldAccepts.Add(TestSubject.ShouldAccept()); TestSubject.LogSuccessResponse(HttpStatusCode.OK.ToString()); await Task.Delay(5); } }
public void should_end_by_accepting_requests() { ShouldAccepts.Last().ShouldBe(true); }
public void should_start_by_accepting_requests() { ShouldAccepts.First().ShouldBe(true); }
public void should_remain_accepting_all_requests() { Assert.That(ShouldAccepts.All(c => c), Is.True); }
public void should_end_by_not_accepting_requests() { ShouldAccepts.Last().ShouldBe(false); }