Exemplo n.º 1
0
        public void SendBeaconRequestDoesNotAppendIfAdditionalQueryParametersAreNull()
        {
            // given
            string capturedUrl = null;

            spyClient.DoPostRequest(Arg.Do <string>(u => capturedUrl = u), Arg.Any <string>(), Arg.Any <byte[]>())
            .Returns(CreateSuccessHttpResponse());

            // when
            spyClient.SendBeaconRequest(null, null, null);

            // then
            var expectedUrl = InitializeBaseUrl();

            Assert.That(capturedUrl, Is.EqualTo(expectedUrl.ToString()));
        }