Ejemplo n.º 1
0
        public void CountryInfoReturnsCountryInfo()
        {
            var countryInfoClient = new TestableCountryInfo(webClient.Object);

            countryInfoClient.Run("Bolivia");
            this.webClient.Verify(x => x.DownloadString(It.IsAny <string>()), Times.Once);
        }
Ejemplo n.º 2
0
        public void CountryInfoDoesNotThrowsIfNoResult()
        {
            this.webClient.Setup(x => x.DownloadString(It.IsAny <string>())).Returns("");

            var countryInfoClient = new TestableCountryInfo(webClient.Object);

            countryInfoClient.Run("Bolivia");
            this.webClient.Verify(x => x.DownloadString(It.IsAny <string>()), Times.Once);
        }