Exemple #1
0
        public void GetContent_ContentWasFound_ContentIsCorrect()
        {
            WebDownloaderResult result = WebDownloader.GetContent("http://laboru.co/hello.txt");

            Assert.AreEqual("hello", result.HtmlContent);
        }
Exemple #2
0
        public void GetContent_UrlIsNotFound_ResponseStatusIsUrlNotFound()
        {
            WebDownloaderResult result = WebDownloader.GetContent("http://laboru.co/hello.tx");

            Assert.AreEqual(true, result.Status == DownloadResultStatus.UrlNotFound);
        }
Exemple #3
0
        public void GetContent_ContentWasFound_HtmlHasContent()
        {
            WebDownloaderResult result = WebDownloader.GetContent("http://laboru.co/hello.txt");

            Assert.AreEqual(true, !String.IsNullOrEmpty(result.HtmlContent));
        }