public void CanRenderRaw() { var parser = new ConsoleTokenParser(); var imp = "Hello ^red;World!^;"; parser.Scan(imp); var raw = parser.Render((i, t) => t.RawText); Assert.Equal(imp, raw); }
public void Empty() { var parser = new ConsoleTokenParser(); var imp = "No tokens at all"; parser.Scan(imp); var raw = parser.Render((i, x) => x.IsLiteral ? x.Text : x.Text.Trim('^', ';')); Assert.Equal("No tokens at all", raw); }