private static Entity ParseIntoTree(string text) { var root = new PageEntity(text); var lang = new MarkdownLanguage(); root.Parse(lang); return root; }
public void Format_should_add_html_header_to_page_entity_raw_text() { var entity = new PageEntity(RawText); var htmlResult = Formatter.Format(entity); var htmlHeader = ResourceFile.ResourceManager.GetString("HtmlHeader"); var correctAnswer = string.Format(htmlHeader, RawText + "\r\n\r\n"); Assert.AreEqual(correctAnswer, htmlResult); }