Skip to content

Commit

Permalink
Port UI tests from #20953
Browse files Browse the repository at this point in the history
  • Loading branch information
Mike Corsaro committed Mar 27, 2024
1 parent 2a6e814 commit 4f9c994
Show file tree
Hide file tree
Showing 6 changed files with 792 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,11 +43,24 @@
<ItemGroup>
<MauiImage Include="Resources\Images\*" />
<MauiImage Update="Resources\Images\dotnet_bot.svg" Color="#FFFFFF" BaseSize="168,208" />
<MauiImage Update="Resources\Images\dotnet_bot_resized.svg" Color="#FFFFFF" BaseSize="20,20" />
<MauiImage Include="Resources\Images\dotnet_bot.svg" Link="Resources\Images\small_dotnet_bot.svg" Color="#FFFFFF" BaseSize="64,64" />
<MauiImage Include="Resources\AppIcons\appicon.svg" ForegroundFile="Resources\AppIcons\appicon_foreground.svg" IsAppIcon="true" />
<MauiSplashScreen Include="Resources\Splash\splash.svg" Color="#FFFFFF" BaseSize="168,208" />
<MauiFont Include="Resources\Fonts\OpenSans-Regular.ttf" />
</ItemGroup>

<ItemGroup>
<Compile Update="Issues\Issue21394.xaml.cs">
<DependentUpon>Issue21394.xaml</DependentUpon>
</Compile>
</ItemGroup>

<Import Project="$(MauiSrcDirectory)Maui.InTree.props" Condition=" '$(UseMaui)' != 'true' " />

<ItemGroup>
<MauiXaml Update="Issues\Issue21394.xaml">
<Generator>MSBuild:Compile</Generator>
</MauiXaml>
</ItemGroup>
</Project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
<?xml version="1.0" encoding="utf-8" ?>
<ContentPage xmlns="http://schemas.microsoft.com/dotnet/2021/maui"
xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml"
x:Class="Maui.Controls.Sample.Issues.Issue21394"
Title="Issue21394">
<VerticalStackLayout>
<Button Background="Lightgray" ContentLayout="Right, 20" ImageSource="dotnet_bot_resized.png" Text="Button Title" AutomationId="WaitForStubControl"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Top, 20" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Left, 20" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Bottom, 20" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="20" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Right, 0" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Top, 20" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Left, 30" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Bottom, 0" ImageSource="dotnet_bot_resized.png" Text="Button Title"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Right, 10" ImageSource="dotnet_bot_resized.png" Text="Button Title" HeightRequest="60"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Top, 10" ImageSource="dotnet_bot_resized.png" Text="Button Title" HeightRequest="60"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Left, 10" ImageSource="dotnet_bot_resized.png" Text="Button Title" HeightRequest="60"/>
<BoxView HeightRequest="5" />

<Button Background="Lightgray" ContentLayout="Bottom, 10" ImageSource="dotnet_bot_resized.png" Text="Button Title" HeightRequest="60"/>
<BoxView HeightRequest="5" />
</VerticalStackLayout>
</ContentPage>
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
using Microsoft.Maui.Controls;
using Microsoft.Maui.Controls.Xaml;

namespace Maui.Controls.Sample.Issues;

[XamlCompilation(XamlCompilationOptions.Compile)]
[Issue(IssueTracker.Github, 21394, "Buttons with Images layouts", PlatformAffected.UWP)]
public partial class Issue21394 : ContentPage
{
public Issue21394()
{
InitializeComponent();
}
}
Loading

0 comments on commit 4f9c994

Please sign in to comment.