コード例 #1
0
        public void ShouldVerifyBetweenSuccess()
        {
            SendHello(2);

            Assert.NotNull(MockServerClient.Verify(Request()
                                                   .WithMethod(HttpMethod.Get)
                                                   .WithPath("/hello"), VerificationTimes.Between(1, 3)));
        }
コード例 #2
0
        public void ShouldVerifyBetweenFailed()
        {
            var ex = Assert.Throws <AssertionException>(() =>
            {
                MockServerClient.Verify(Request()
                                        .WithMethod(HttpMethod.Get)
                                        .WithPath("/hello"), VerificationTimes.Between(1, 2));
            });

            Assert.StartsWith("Request not found between 1 and 2", ex.Message);
        }
コード例 #3
0
 /// <inheritdoc />
 public void Between(int min, int max)
 {
     _verificationTimes = VerificationTimes.Between(min, max);
 }