Exemple #1
0
        public void TestMethodCheckFileSize()
        {
            WebRequestHelper wrh = new WebRequestHelper();
            int fsize            = wrh.CheckFileSize(url2);

            Console.WriteLine(fsize);
            Assert.AreEqual(101688487, fsize);

            int fsize2 = wrh.CheckFileSize(url2_2);

            Console.WriteLine(fsize2);
            Assert.AreEqual(-404, fsize2);

            int fsize3 = wrh.CheckFileSize(url4);

            Console.WriteLine(fsize3);
            Assert.AreEqual(122047, fsize3);
        }