Skip to content

Commit 058c896

Browse files
committed
Added Diagnostics skoke test project
1 parent e7d166f commit 058c896

File tree

3 files changed

+42
-0
lines changed

3 files changed

+42
-0
lines changed
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<Page
2+
x:Class="SmokeTest.MainPage"
3+
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
4+
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
5+
xmlns:local="using:SmokeTest"
6+
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
7+
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
8+
mc:Ignorable="d"
9+
Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
10+
11+
<Grid>
12+
<StackPanel HorizontalAlignment="Center" VerticalAlignment="Center" Width="200">
13+
<TextBox x:Name="textBox" Text="text"/>
14+
<Button Content="Is not null or empty?" Click="Button_Click" HorizontalAlignment="Center"/>
15+
<TextBlock x:Name="textBlock"/>
16+
</StackPanel>
17+
</Grid>
18+
</Page>
Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
// Licensed to the .NET Foundation under one or more agreements.
2+
// The .NET Foundation licenses this file to you under the MIT license.
3+
// See the LICENSE file in the project root for more information.
4+
5+
using Microsoft.Toolkit.Diagnostics;
6+
7+
namespace SmokeTest
8+
{
9+
public sealed partial class MainPage
10+
{
11+
public MainPage()
12+
{
13+
InitializeComponent();
14+
}
15+
16+
private void Button_Click(object sender, Windows.UI.Xaml.RoutedEventArgs e)
17+
{
18+
Guard.IsNotNullOrEmpty(textBox.Text, nameof(textBox));
19+
20+
textBlock.Text = "Ok";
21+
}
22+
}
23+
}

SmokeTests/SmokeTests.proj

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
<ToolkitPackages>
88
UWPBaseline;
99
Microsoft.Toolkit;
10+
Microsoft.Toolkit.Diagnostics;
1011
Microsoft.Toolkit.HighPerformance;
1112
Microsoft.Toolkit.Mvvm;
1213
Microsoft.Toolkit.Parsers;

0 commit comments

Comments
 (0)