public void TestCrawSimpleStructure()
        {
            var content = new XHtmlContent();

            content.LoadFromFile("product-info.html");

            var crawler          = new NetCrawler(content);
            var quickTimeProduct = crawler.Crawl <TestAppStoreProduct>();

            Assert.AreEqual("QuickTime 7 Pro for Windows", quickTimeProduct.Title);
            Assert.IsTrue(!string.IsNullOrEmpty(quickTimeProduct.Description));
            Assert.IsTrue(quickTimeProduct.IconUrl.IndexOf("http://store.storeimages.cdn-apple.com/6270") == 0);
        }
        public void TestCrawlDataTypes()
        {
            var content = new XHtmlContent();

            content.LoadFromFile("data-types.html");

            var crawler   = new NetCrawler(content);
            var dateTypes = crawler.Crawl <TestDateTypesModel>();

            Assert.AreEqual(123, dateTypes.IntData);
            Assert.AreEqual(true, dateTypes.Bool1Data);
            Assert.AreEqual(true, dateTypes.Bool2Data);
            Assert.AreEqual(123.123, dateTypes.FloatData);
            Assert.AreEqual(123.123, dateTypes.DecimalData);
            Assert.AreEqual(123.123, dateTypes.DoubleData);
            Assert.AreEqual(eTestDateTypesModelEnum.EnumValue2, dateTypes.EnumData);
            Assert.AreEqual(new DateTime(2012, 06, 02), dateTypes.DateTimeData.Date);
        }
        public void TestCrawlDataTypes()
        {
            var content = new XHtmlContent();
            content.LoadFromFile("data-types.html");

            var crawler = new NetCrawler(content);
            var dateTypes = crawler.Crawl<TestDateTypesModel>();

            Assert.AreEqual(123, dateTypes.IntData);
            Assert.AreEqual(true, dateTypes.Bool1Data);
            Assert.AreEqual(true, dateTypes.Bool2Data);
            Assert.AreEqual(123.123, dateTypes.FloatData);
            Assert.AreEqual(123.123, dateTypes.DecimalData);
            Assert.AreEqual(123.123, dateTypes.DoubleData);
            Assert.AreEqual(eTestDateTypesModelEnum.EnumValue2, dateTypes.EnumData);
            Assert.AreEqual(new DateTime(2012, 06, 02), dateTypes.DateTimeData.Date);
        }
        public void TestCrawSimpleStructure()
        {
            var content = new XHtmlContent();
            content.LoadFromFile("product-info.html");

            var crawler = new NetCrawler(content);
            var quickTimeProduct = crawler.Crawl<TestAppStoreProduct>();

            Assert.AreEqual("QuickTime 7 Pro for Windows", quickTimeProduct.Title);
            Assert.IsTrue(!string.IsNullOrEmpty(quickTimeProduct.Description));
            Assert.IsTrue(quickTimeProduct.IconUrl.IndexOf("http://store.storeimages.cdn-apple.com/6270") == 0);
        }