public void GivenTestXXX_generatesExpectedResult() { var text = Util.LoadText("MainWindow.md"); var markdown = new Markdown.Avalonia.Markdown(); var control = markdown.Transform(text); control.Styles.Add(new StyleInclude(new Uri("avares://Avalonia.Themes.Default/")) { Source = new Uri("avares://Avalonia.Themes.Default/DefaultTheme.xaml") }); control.Styles.Add(new StyleInclude(new Uri("avares://Avalonia.Themes.Default/")) { Source = new Uri("avares://Avalonia.Themes.Default/Accents/BaseLight.xaml") }); control.Styles.Add(MarkdownStyle.DefaultTheme); control.Resources.Add("FontSizeNormal", 16d); var umefont = new FontFamily(new Uri("avares://UnitTest.CTxt/Assets/Fonts/ume-ugo4.ttf"), "Ume UI Gothic"); TextBlock.SetFontFamily(control, umefont); var info = new MetryHolder(control, 500, 10000); Approvals.Verify( new ApprovalImageWriter(info.Image), Approvals.GetDefaultNamer(), new DiffToolReporter(DiffEngine.DiffTool.WinMerge)); }
public void GivenTest2_generatesExpectedResult() { var tst2 = new Test2(); var ctxt = (CTextBlock)tst2.Content; var info = new MetryHolder(ctxt, 1000, 1000); Approvals.Verify( new ApprovalImageWriter(info.Image), Approvals.GetDefaultNamer(), new DiffToolReporter(DiffEngine.DiffTool.WinMerge)); }
public void GivenTest3_generatesExpectedResult_sub2() { var tst3 = new Test3(); var spnl = (StackPanel)tst3.Content; var ctxt = (CTextBlock)spnl.Children[2]; var info = new MetryHolder(ctxt, 1000, 1000); Approvals.Verify( new ApprovalImageWriter(info.Image), Approvals.GetDefaultNamer(), new DiffToolReporter(DiffEngine.DiffTool.WinMerge)); }