Exemplo n.º 1
0
        public XMLWriterTests()
        {
            HTMLScanner = new HTMLScanner();
            HtmlPage    = null;
            FilePath    = Path.Combine(TestContext.CurrentContext.WorkDirectory, @"HTML\index.html");

            using (FileStream fileStream = File.OpenRead(FilePath))
                using (StreamReader streamReader = new StreamReader(fileStream))
                {
                    HtmlPage = streamReader.ReadToEnd();
                }

            PageObjects = HTMLScanner.ScanHtmlPage(HtmlPage);
            XmlWriter   = new XMLWriter();
            Document    = XmlWriter.CreateDocument(PageObjects, "http://www.totallyratted.com", "main");
        }