Пример #1
0
 public void TestSimpleGeneration()
 {
     TokenTree toGenerate = new TokenTree
     {
         Key = new StringToken("Field"),
         Value = new StringToken("Grid"),
         Children =
         {
             new TokenTree
             {
                 Key = new StringToken("Field"),
                 Value = new StringToken("Label"),
                 Children =
                 {
                     new TokenTree {Key = new StringToken("Content"), Value = new StringToken("Hi")},
                     new TokenTree {Key = new StringToken("Width"), Value = new StringToken("200")}
                 }
             }
         }
     };
     string generated = new XamlGenerator("").GenerateXaml(toGenerate);
     Assert.AreEqual(XAML, generated);
 }
Пример #2
0
 public void TestVTL()
 {
     TokenTree tokenTree = Parser.ParseString(VTL);
     string generated = new XamlGenerator("").GenerateXaml(tokenTree);
     Assert.AreEqual(XAML, generated);
 }