diff --git a/src/Controls/samples/Controls.Sample.UITests/CoreViews/CorePageView.cs b/src/Controls/samples/Controls.Sample.UITests/CoreViews/CorePageView.cs index cac261a064e4..ff54e348b2fe 100644 --- a/src/Controls/samples/Controls.Sample.UITests/CoreViews/CorePageView.cs +++ b/src/Controls/samples/Controls.Sample.UITests/CoreViews/CorePageView.cs @@ -64,11 +64,11 @@ public override string ToString() new GalleryPageFactory(() => new ImageButtonCoreGalleryPage(), "Image Button Gallery"), new GalleryPageFactory(() => new ImageCoreGalleryPage(), "Image Gallery"), new GalleryPageFactory(() => new KeyboardScrollingGridGallery(), "Keyboard Scrolling Gallery - Grid with Star Row"), - new GalleryPageFactory(() => new KeyboardScrollingNonScrollingPageLargeTitlesGallery(), "Keyboard Scrolling Gallery - NonScrolling Page / Large Titles"), - new GalleryPageFactory(() => new KeyboardScrollingNonScrollingPageSmallTitlesGallery(), "Keyboard Scrolling Gallery - NonScrolling Page / Small Titles"), + new GalleryPageFactory(() => new KeyboardScrollingNonScrollingPageLargeTitlesGallery(), "Keyboard Scrolling Gallery - NonScrolling Page / Large Titles"), + new GalleryPageFactory(() => new KeyboardScrollingNonScrollingPageSmallTitlesGallery(), "Keyboard Scrolling Gallery - NonScrolling Page / Small Titles"), new GalleryPageFactory(() => new KeyboardScrollingScrollingPageLargeTitlesGallery(), "Keyboard Scrolling Gallery - Scrolling Page / Large Titles"), new GalleryPageFactory(() => new KeyboardScrollingScrollingPageSmallTitlesGallery(), "Keyboard Scrolling Gallery - Scrolling Page / Small Titles"), - new GalleryPageFactory(() => new LabelCoreGalleryPage(), "Label Gallery"), + new GalleryPageFactory(() => new LabelCoreGalleryPage(), "Label Gallery"), new GalleryPageFactory(() => new ListViewCoreGalleryPage(), "ListView Gallery"), new GalleryPageFactory(() => new PickerCoreGalleryPage(), "Picker Gallery"), new GalleryPageFactory(() => new ProgressBarCoreGalleryPage(), "Progress Bar Gallery"), @@ -152,19 +152,34 @@ async Task PushPage(Page contentPage) } readonly Dictionary _titleToPage; - public async Task PushPage(string pageTitle) + public Task NavigateToGalleryPage(string pageTitle) { if (_titleToPage.TryGetValue(pageTitle.ToLowerInvariant(), out GalleryPageFactory pageFactory)) { var page = pageFactory.Realize(); + this.Window.Page = page; + return Task.FromResult(true); + } + + return Task.FromResult(false); + } - await PushPage(page); + public async Task NavigateToTest(string pageTitle) + { + var testCaseScreen = new TestCases.TestCaseScreen(); + if (testCaseScreen.TryToNavigateTo(pageTitle)) + { + return true; + } + else if (await NavigateToGalleryPage(pageTitle)) + { return true; } return false; } + public void FilterPages(string filter) { ItemsSource = string.IsNullOrWhiteSpace(filter) diff --git a/src/Controls/samples/Controls.Sample.UITests/CoreViews/CoreRootPage.cs b/src/Controls/samples/Controls.Sample.UITests/CoreViews/CoreRootPage.cs index a2d15d58edc3..4cc600e2319d 100644 --- a/src/Controls/samples/Controls.Sample.UITests/CoreViews/CoreRootPage.cs +++ b/src/Controls/samples/Controls.Sample.UITests/CoreViews/CoreRootPage.cs @@ -30,7 +30,7 @@ public CoreRootPage(Microsoft.Maui.Controls.Page rootPage) { if (!string.IsNullOrEmpty(searchBar.Text)) { - await corePageView.PushPage(searchBar.Text); + await corePageView.NavigateToTest(searchBar.Text); } else { diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/HideSoftInputOnTappedPage.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/HideSoftInputOnTappedPage.cs index f6d5d9dceb4d..06a29080b924 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/HideSoftInputOnTappedPage.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/HideSoftInputOnTappedPage.cs @@ -6,15 +6,19 @@ namespace Maui.Controls.Sample.Issues { [Issue(IssueTracker.None, 12003, "Hide Soft Input On Tapped Page", PlatformAffected.iOS | PlatformAffected.Android)] - public class HideSoftInputOnTappedPage : TestContentPage + public class HideSoftInputOnTappedPage : NavigationPage { - public HideSoftInputOnTappedPage() + public HideSoftInputOnTappedPage() : base(new StartingPage()) { + } - protected override void Init() + public class StartingPage : TestContentPage { - Content = new VerticalStackLayout() + + protected override void Init() + { + Content = new VerticalStackLayout() { new Button() { @@ -36,48 +40,48 @@ protected override void Init() } }; - (Content as VerticalStackLayout).Spacing = 6; - } + (Content as VerticalStackLayout).Spacing = 6; + } - public class TestPage : ContentPage - { - Label _isKeyboardOpen = new Label(); - public TestPage(bool hideSoftInputOnTapped) + public class TestPage : ContentPage { - this.HideSoftInputOnTapped = hideSoftInputOnTapped; - Title = "Hide Soft Input On Tapped Page"; - _isKeyboardOpen.Text = "Tap Page and Keyboard Should Close"; - _isKeyboardOpen.AutomationId = "EmptySpace"; + Label _isKeyboardOpen = new Label(); + public TestPage(bool hideSoftInputOnTapped) + { + this.HideSoftInputOnTapped = hideSoftInputOnTapped; + Title = "Hide Soft Input On Tapped Page"; + _isKeyboardOpen.Text = "Tap Page and Keyboard Should Close"; + _isKeyboardOpen.AutomationId = "EmptySpace"; - Entry entry = new Entry() { AutomationId = "Entry" }; + Entry entry = new Entry() { AutomationId = "Entry" }; - var checkbox = new CheckBox(); - checkbox.BindingContext = this; - checkbox.SetBinding( - CheckBox.IsCheckedProperty, - nameof(HideSoftInputOnTapped)); + var checkbox = new CheckBox(); + checkbox.BindingContext = this; + checkbox.SetBinding( + CheckBox.IsCheckedProperty, + nameof(HideSoftInputOnTapped)); - checkbox.AutomationId = "ToggleHideSoftInputOnTapped"; + checkbox.AutomationId = "ToggleHideSoftInputOnTapped"; - Entry dontHideKeyboardWhenTappingPage = new Entry() - { - Placeholder = "When this entry is focused tapping the page won't close the keyboard", - AutomationId = "DontHideKeyboardWhenTappingPage" - }; + Entry dontHideKeyboardWhenTappingPage = new Entry() + { + Placeholder = "When this entry is focused tapping the page won't close the keyboard", + AutomationId = "DontHideKeyboardWhenTappingPage" + }; - dontHideKeyboardWhenTappingPage - .Focused += (_, _) => checkbox.IsChecked = false; + dontHideKeyboardWhenTappingPage + .Focused += (_, _) => checkbox.IsChecked = false; - Entry hideKeyboardWhenTappingPage = new Entry() - { - Placeholder = "When this entry is focused tapping the page will close the keyboard", - AutomationId = "HideKeyboardWhenTappingPage" - }; + Entry hideKeyboardWhenTappingPage = new Entry() + { + Placeholder = "When this entry is focused tapping the page will close the keyboard", + AutomationId = "HideKeyboardWhenTappingPage" + }; - hideKeyboardWhenTappingPage - .Focused += (_, _) => checkbox.IsChecked = true; + hideKeyboardWhenTappingPage + .Focused += (_, _) => checkbox.IsChecked = true; - Content = new VerticalStackLayout() + Content = new VerticalStackLayout() { new HorizontalStackLayout() { @@ -90,6 +94,7 @@ public TestPage(bool hideSoftInputOnTapped) dontHideKeyboardWhenTappingPage, hideKeyboardWhenTappingPage }; + } } } } diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue11501.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue11501.cs index ae68e4fe475e..d5154fc75091 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue11501.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue11501.cs @@ -8,49 +8,57 @@ namespace Maui.Controls.Sample.Issues { [Issue(IssueTracker.Github, 11501, "Making Fragment Changes While App is Backgrounded Fails", PlatformAffected.Android)] - public class Issue11501 : TestContentPage + + public class Issue11501 : NavigationPage { - Func _currentTest; - Page _mainPage; - List _modalStack; - Window _window; - public Issue11501() + public Issue11501() : base(new TestPage()) { - Loaded += OnLoaded; } - private void OnLoaded(object sender, EventArgs e) - { - _window = Window; - _mainPage = Application.Current.MainPage; - _modalStack = Navigation.ModalStack.ToList(); - } - private async void OnWindowActivated(object sender, EventArgs e) + public class TestPage : TestContentPage { - DisconnectFromWindow(); - if (_currentTest is not null) + Func _currentTest; + Page _mainPage; + List _modalStack; + Window _window; + public TestPage() { - await Task.Yield(); - await _currentTest(); - _currentTest = null; + Loaded += OnLoaded; } - } - void ConnectToWindow() - { - _window.Stopped -= OnWindowActivated; - _window.Stopped += OnWindowActivated; - } + private void OnLoaded(object sender, EventArgs e) + { + _window = Window; + _mainPage = Application.Current.MainPage; + _modalStack = Navigation.ModalStack.ToList(); + } - void DisconnectFromWindow() - { - _window.Stopped -= OnWindowActivated; - } + private async void OnWindowActivated(object sender, EventArgs e) + { + DisconnectFromWindow(); + if (_currentTest is not null) + { + await Task.Yield(); + await _currentTest(); + _currentTest = null; + } + } - protected override void Init() - { - Content = new VerticalStackLayout() + void ConnectToWindow() + { + _window.Stopped -= OnWindowActivated; + _window.Stopped += OnWindowActivated; + } + + void DisconnectFromWindow() + { + _window.Stopped -= OnWindowActivated; + } + + protected override void Init() + { + Content = new VerticalStackLayout() { new Button() { @@ -151,14 +159,14 @@ protected override void Init() }) }, }; - } + } - ContentPage CreateDestinationPage() - { - return new ContentPage() + ContentPage CreateDestinationPage() { - Title = "Test", - Content = new VerticalStackLayout() + return new ContentPage() + { + Title = "Test", + Content = new VerticalStackLayout() { new Button() { @@ -177,7 +185,8 @@ ContentPage CreateDestinationPage() }) } } - }; + }; + } } } -} +} \ No newline at end of file diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue14829.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue14829.cs index f8c2bf458aa4..cfedb9c0728a 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue14829.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue14829.cs @@ -1,4 +1,5 @@ -using Microsoft.Maui.Controls; +using System; +using Microsoft.Maui.Controls; using Microsoft.Maui.Graphics; namespace Maui.Controls.Sample.Issues @@ -9,12 +10,11 @@ public class Issue14829 : TestContentPage protected override void Init() { var navPage = new NavigationPage(new MainPage()); - NavigatedTo += Issue14829_NavigatedTo; + Loaded += OnLoaded; - async void Issue14829_NavigatedTo(object sender, NavigatedToEventArgs e) + async void OnLoaded(object sender, EventArgs e) { - NavigatedTo -= Issue14829_NavigatedTo; - + Loaded -= OnLoaded; await Navigation.PushModalAsync(navPage); } } diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue16499.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue16499.cs index c886c671ff00..d73801e944b9 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue16499.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue16499.cs @@ -3,32 +3,39 @@ namespace Maui.Controls.Sample.Issues { [Issue(IssueTracker.Github, 16499, "Crash when using NavigationPage.TitleView and Restarting App", PlatformAffected.Android)] - public class Issue16499 : TestContentPage + public class Issue16499 : NavigationPage { - protected override void Init() + public Issue16499() : base(new MainPage()) { - var contentPage = new ContentPage(); - var navPage = new NavigationPage(contentPage); + } - NavigationPage.SetTitleView(contentPage, new Label()); + public class MainPage : ContentPage + { + public MainPage() : base() + { + var contentPage = new ContentPage(); + var navPage = new NavigationPage(contentPage); - NavigatedTo += Issue16499_NavigatedTo; + NavigationPage.SetTitleView(contentPage, new Label()); - async void Issue16499_NavigatedTo(object sender, NavigatedToEventArgs e) - { - NavigatedTo -= Issue16499_NavigatedTo; - await Navigation.PushModalAsync(navPage); - await Navigation.PopModalAsync(); - await Navigation.PushModalAsync(navPage); - await Navigation.PopModalAsync(); - this.Content = new VerticalStackLayout() + NavigatedTo += Issue16499_NavigatedTo; + + async void Issue16499_NavigatedTo(object sender, NavigatedToEventArgs e) { - new Label() + NavigatedTo -= Issue16499_NavigatedTo; + await Navigation.PushModalAsync(navPage); + await Navigation.PopModalAsync(); + await Navigation.PushModalAsync(navPage); + await Navigation.PopModalAsync(); + Content = new VerticalStackLayout() { - Text = "If the app didn't crash this test was a success", - AutomationId = "SuccessLabel" - } - }; + new Label() + { + Text = "If the app didn't crash this test was a success", + AutomationId = "SuccessLabel" + } + }; + } } } } diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue17022.xaml b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue17022.xaml index 818a40baa44a..8fe7409889c1 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/Issue17022.xaml +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/Issue17022.xaml @@ -4,28 +4,29 @@ AutomationId="NavBarTranslucentPage" x:Class="Maui.Controls.Sample.Issues.Issue17022" xmlns:ios="clr-namespace:Microsoft.Maui.Controls.PlatformConfiguration.iOSSpecific;assembly=Microsoft.Maui.Controls"> - - - + + + - \ No newline at end of file + \ No newline at end of file diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/Issues16321.xaml.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/Issues16321.xaml.cs index dca39801fe85..ea75962617fe 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/Issues16321.xaml.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/Issues16321.xaml.cs @@ -14,9 +14,17 @@ namespace Maui.Controls.Sample.Issues { [XamlCompilation(XamlCompilationOptions.Compile)] [Issue(IssueTracker.Github, 16321, "Alerts Open on top of current presented view", PlatformAffected.All)] + public class Issue16321NavPage : NavigationPage + { + public Issue16321NavPage() : base(new Issue16321()) + { + + } + } + public partial class Issue16321 : ContentPage { - public Issue16321() + public Issue16321() : base() { InitializeComponent(); } @@ -67,10 +75,10 @@ async void OpenAlertWithNewUIWindow(System.Object sender, System.EventArgs e) this.RemoveLogicalChild(page); } #else - async void OpenAlertWithNewUIWindow(System.Object sender, System.EventArgs e) - { - await this.DisplayAlert("hello", "message", "Cancel"); - } + async void OpenAlertWithNewUIWindow(System.Object sender, System.EventArgs e) + { + await this.DisplayAlert("hello", "message", "Cancel"); + } #endif } -} +} \ No newline at end of file diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/ScrollViewIsEnabled.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/ScrollViewIsEnabled.cs index 600481cb1131..4256187fd02c 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/ScrollViewIsEnabled.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/ScrollViewIsEnabled.cs @@ -8,80 +8,87 @@ namespace Maui.Controls.Sample.Issues // ScrollViewInitiallyNotEnabled (src\Compatibility\ControlGallery\src\Issues.Shared\ScrollViewIsEnabled.cs) // ScrollViewInitiallyNotEnabledThenEnabled (src\Compatibility\ControlGallery\src\Issues.Shared\ScrollViewIsEnabled.cs) [Issue(IssueTracker.None, 0112358, "ScrollView set to disabled will still allow scrolling", PlatformAffected.All)] - public class ScrollViewIsEnabled : ContentPage + public class ScrollViewIsEnabled : NavigationPage { - const string InitiallyEnabled = "Initially Enabled"; - const string InitiallyNotEnabled = "Initially Not Enabled"; - const string ToggleButton = "ToggleButton"; - const string ScrollView = "TheScrollView"; - const string FirstItem = "FirstItem"; - const string Success = "Success"; - - public ScrollViewIsEnabled() + public ScrollViewIsEnabled() : base(new TestPage()) { - var initiallyEnabled = new Button { AutomationId = "InitiallyEnabled", Text = InitiallyEnabled }; - initiallyEnabled.Clicked += (sender, args) => { Navigation.PushAsync(ScrollViewTestPage(true)); }; + } - var initiallyNotEnabled = new Button { AutomationId= "InitiallyNotEnabled", Text = InitiallyNotEnabled }; - initiallyNotEnabled.Clicked += (sender, args) => { Navigation.PushAsync(ScrollViewTestPage(false)); }; + public class TestPage : ContentPage + { + const string InitiallyEnabled = "Initially Enabled"; + const string InitiallyNotEnabled = "Initially Not Enabled"; + const string ToggleButton = "ToggleButton"; + const string ScrollView = "TheScrollView"; + const string FirstItem = "FirstItem"; + const string Success = "Success"; + + public TestPage() + { + var initiallyEnabled = new Button { AutomationId = "InitiallyEnabled", Text = InitiallyEnabled }; + initiallyEnabled.Clicked += (sender, args) => { Navigation.PushAsync(ScrollViewTestPage(true)); }; - var layout = new StackLayout { Children = { initiallyNotEnabled, initiallyEnabled } }; + var initiallyNotEnabled = new Button { AutomationId = "InitiallyNotEnabled", Text = InitiallyNotEnabled }; + initiallyNotEnabled.Clicked += (sender, args) => { Navigation.PushAsync(ScrollViewTestPage(false)); }; - Content = layout; - } + var layout = new StackLayout { Children = { initiallyNotEnabled, initiallyEnabled } }; - static ContentPage ScrollViewTestPage(bool initiallyEnabled) - { - var scrollViewContents = new StackLayout(); - scrollViewContents.Children.Add(new Label { AutomationId = FirstItem, Text = FirstItem }); + Content = layout; + } - for (int n = 0; n < 100; n++) + static ContentPage ScrollViewTestPage(bool initiallyEnabled) { - scrollViewContents.Children.Add(new Label { AutomationId = $"Item{n + 1}", Text = $"Item{n + 1}" }); - } + var scrollViewContents = new StackLayout(); + scrollViewContents.Children.Add(new Label { AutomationId = FirstItem, Text = FirstItem }); - var sv = new ScrollView { Content = scrollViewContents, IsEnabled = initiallyEnabled, AutomationId = ScrollView }; - var layout = new Grid { Margin = new Thickness(5, 40, 5, 0) }; + for (int n = 0; n < 100; n++) + { + scrollViewContents.Children.Add(new Label { AutomationId = $"Item{n + 1}", Text = $"Item{n + 1}" }); + } - layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); - layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); - layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); - layout.RowDefinitions.Add(new RowDefinition()); + var sv = new ScrollView { Content = scrollViewContents, IsEnabled = initiallyEnabled, AutomationId = ScrollView }; + var layout = new Grid { Margin = new Thickness(5, 40, 5, 0) }; - var toggleButton = new Button { Text = $"Toggle IsEnabled (currently {sv.IsEnabled})", AutomationId = ToggleButton }; + layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); + layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); + layout.RowDefinitions.Add(new RowDefinition() { Height = GridLength.Auto }); + layout.RowDefinitions.Add(new RowDefinition()); - toggleButton.Clicked += (sender, args) => - { - sv.IsEnabled = !sv.IsEnabled; - toggleButton.Text = $"Toggle IsEnabled (currently {sv.IsEnabled})"; - }; + var toggleButton = new Button { Text = $"Toggle IsEnabled (currently {sv.IsEnabled})", AutomationId = ToggleButton }; - var instructions = new Label - { - Text = @"Attempt to scroll the ScrollView below. + toggleButton.Clicked += (sender, args) => + { + sv.IsEnabled = !sv.IsEnabled; + toggleButton.Text = $"Toggle IsEnabled (currently {sv.IsEnabled})"; + }; + + var instructions = new Label + { + Text = @"Attempt to scroll the ScrollView below. If 'IsEnabled' is false and the ScrollView scrolls, this test has failed. If 'IsEnabled' is true and the ScrollView does not scroll, this test has failed. Use the toggle button to check both values of 'IsEnabled'." - }; + }; - var success = new Label - { - AutomationId = Success - }; + var success = new Label + { + AutomationId = Success + }; - layout.Children.Add(instructions); - layout.Children.Add(toggleButton); - layout.Children.Add(success); - layout.Children.Add(sv); + layout.Children.Add(instructions); + layout.Children.Add(toggleButton); + layout.Children.Add(success); + layout.Children.Add(sv); - Grid.SetRow(instructions, 0); - Grid.SetRow(toggleButton, 1); - Grid.SetRow(success, 2); - Grid.SetRow(sv, 3); + Grid.SetRow(instructions, 0); + Grid.SetRow(toggleButton, 1); + Grid.SetRow(success, 2); + Grid.SetRow(sv, 3); - sv.Scrolled += (sender, args) => success.Text = Success; + sv.Scrolled += (sender, args) => success.Text = Success; - return new ContentPage { Content = layout }; + return new ContentPage { Content = layout }; + } } } } \ No newline at end of file diff --git a/src/Controls/samples/Controls.Sample.UITests/Issues/XFIssue2681.cs b/src/Controls/samples/Controls.Sample.UITests/Issues/XFIssue2681.cs index f0976d6d2e37..db781eec1417 100644 --- a/src/Controls/samples/Controls.Sample.UITests/Issues/XFIssue2681.cs +++ b/src/Controls/samples/Controls.Sample.UITests/Issues/XFIssue2681.cs @@ -9,54 +9,61 @@ namespace Maui.Controls.Sample.Issues; [Issue(IssueTracker.None, 2681, "[UWP] Label inside Listview gets stuck inside infinite loop", PlatformAffected.UWP)] -public class XFIssue2681 : TestContentPage + +public class XFIssue2681 : NavigationPage { - const string NavigateToPage = "Click Me."; - protected override void Init() + public XFIssue2681() : base(new TestPage()) { - Content = new Button() - { - Text = NavigateToPage, - AutomationId = "ClickMe", - Command = new Command(async () => await this.Navigation.PushAsync(new FreezeMe())) - }; } - public partial class FreezeMe : ContentPage + public class TestPage : TestContentPage { - public List Items { get; set; } - - public FreezeMe() + const string NavigateToPage = "Click Me."; + protected override void Init() { - this.BindingContext = this; - var lv = new ListView() + Content = new Button() { - Margin = new Thickness(20, 5, 5, 5) + Text = NavigateToPage, + AutomationId = "ClickMe", + Command = new Command(async () => await this.Navigation.PushAsync(new FreezeMe())) }; + } + + public partial class FreezeMe : ContentPage + { + public List Items { get; set; } - lv.ItemTemplate = new DataTemplate(() => + public FreezeMe() { - var label = new Label() { Text = "sassifrass" }; - label.SetBinding(Label.TextProperty, "."); - label.SetBinding(Label.AutomationIdProperty, "."); - return new ViewCell() { View = label }; - }); + this.BindingContext = this; + var lv = new ListView() + { + Margin = new Thickness(20, 5, 5, 5) + }; - lv.SetBinding(ListView.ItemsSourceProperty, "Items"); + lv.ItemTemplate = new DataTemplate(() => + { + var label = new Label() { Text = "sassifrass" }; + label.SetBinding(Label.TextProperty, "."); + label.SetBinding(Label.AutomationIdProperty, "."); + return new ViewCell() { View = label }; + }); - this.Content = new ScrollView() - { - Content = new StackLayout() + lv.SetBinding(ListView.ItemsSourceProperty, "Items"); + + this.Content = new ScrollView() { - Children = + Content = new StackLayout() + { + Children = { new Label(){ Text = "If page is not frozen this test has passed" }, new StackLayout() { Orientation = StackOrientation.Horizontal, - Children = + Children = { - lv + lv } }, new Button(){ @@ -68,14 +75,15 @@ public FreezeMe() }) } } - } - }; + } + }; - this.Appearing += (s, e) => - { - this.Items = new List { 1, 2, 3 }; - this.OnPropertyChanged("Items"); - }; + this.Appearing += (s, e) => + { + this.Items = new List { 1, 2, 3 }; + this.OnPropertyChanged("Items"); + }; + } } } -} +} \ No newline at end of file diff --git a/src/Controls/samples/Controls.Sample.UITests/TestCases.cs b/src/Controls/samples/Controls.Sample.UITests/TestCases.cs index a070a2c41d22..30e43adfeb0d 100644 --- a/src/Controls/samples/Controls.Sample.UITests/TestCases.cs +++ b/src/Controls/samples/Controls.Sample.UITests/TestCases.cs @@ -39,7 +39,6 @@ Action ActivatePageAndNavigate(IssueAttribute issueAttribute, Type type) return async () => { var page = ActivatePage(type); - TrackOnInsights(page); await Navigation.PushAsync(page); }; } @@ -49,38 +48,16 @@ Action ActivatePageAndNavigate(IssueAttribute issueAttribute, Type type) return async () => { var page = ActivatePage(type); - TrackOnInsights(page); await Navigation.PushModalAsync(page); }; } - if (issueAttribute.NavigationBehavior == NavigationBehavior.Default) - { - return async () => - { - var page = ActivatePage(type); - TrackOnInsights(page); - if (page is ContentPage /*|| page is CarouselPage*/) - { - await Navigation.PushAsync(page); - } - else if (page is Shell) - { - Application.Current.MainPage = page; - } - else - { - await Navigation.PushModalAsync(page); - } - }; - } - - if (issueAttribute.NavigationBehavior == NavigationBehavior.SetApplicationRoot) + if (issueAttribute.NavigationBehavior == NavigationBehavior.SetApplicationRoot || + issueAttribute.NavigationBehavior == NavigationBehavior.Default) { return () => { var page = ActivatePage(type); - TrackOnInsights(page); Application.Current.MainPage = page; }; } @@ -88,11 +65,6 @@ Action ActivatePageAndNavigate(IssueAttribute issueAttribute, Type type) return navigationAction; } - static void TrackOnInsights(Page page) - { - - } - Page ActivatePage(Type type) { var page = Activator.CreateInstance(type) as Page; @@ -182,7 +154,6 @@ public TestCaseScreen() }).ToList(); VerifyNoDuplicates(); - FilterIssues(); } @@ -212,6 +183,8 @@ public void FilterTracker(IssueTracker tracker) public bool TryToNavigateTo(string name) { var issue = _issues.SingleOrDefault(x => string.Equals(x.Name, name, StringComparison.OrdinalIgnoreCase)); + issue = _issues.SingleOrDefault(x => string.Equals(x.Description, name, StringComparison.OrdinalIgnoreCase)); + if (issue == null) return false; @@ -219,12 +192,11 @@ public bool TryToNavigateTo(string name) return true; } - public async void FilterIssues(string filter = null) + public void FilterIssues(string filter = null) { filter = filter?.Trim(); _filter = filter; - await Task.Delay(10); if (_filter != filter) { return; diff --git a/src/Controls/tests/UITests/Tests/BorderUITests.cs b/src/Controls/tests/UITests/Tests/BorderUITests.cs index 5e218610c210..552bd34e3c90 100644 --- a/src/Controls/tests/UITests/Tests/BorderUITests.cs +++ b/src/Controls/tests/UITests/Tests/BorderUITests.cs @@ -19,12 +19,6 @@ protected override void FixtureSetup() App.NavigateToGallery(BorderGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - // TODO: Enable this as a test once fully working //[Test] //[Category(UITestCategories.Border)] diff --git a/src/Controls/tests/UITests/Tests/CarouselViewUITests.cs b/src/Controls/tests/UITests/Tests/CarouselViewUITests.cs index 830ba398d276..b915ae834e45 100644 --- a/src/Controls/tests/UITests/Tests/CarouselViewUITests.cs +++ b/src/Controls/tests/UITests/Tests/CarouselViewUITests.cs @@ -19,12 +19,6 @@ protected override void FixtureSetup() App.NavigateToGallery(CarouselViewGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.CarouselView)] public async Task CarouselViewSetPosition() diff --git a/src/Controls/tests/UITests/Tests/CoreGalleryBasePageTest.cs b/src/Controls/tests/UITests/Tests/CoreGalleryBasePageTest.cs index 1c3c248795cc..a5f48db1e630 100644 --- a/src/Controls/tests/UITests/Tests/CoreGalleryBasePageTest.cs +++ b/src/Controls/tests/UITests/Tests/CoreGalleryBasePageTest.cs @@ -33,20 +33,6 @@ protected override void FixtureSetup() } } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - try - { - this.Back(); - } - catch (Exception e) - { - var name = TestContext.CurrentContext.Test.MethodName ?? TestContext.CurrentContext.Test.Name; - TestContext.Error.WriteLine($">>>>> {DateTime.Now} The FixtureTeardown threw an exception during {name}.{Environment.NewLine}Exception details: {e}"); - } - } - protected abstract void NavigateToGallery(); } } diff --git a/src/Controls/tests/UITests/Tests/DragAndDropUITests.cs b/src/Controls/tests/UITests/Tests/DragAndDropUITests.cs index 79f52dbe8c0d..3e2af31f632a 100644 --- a/src/Controls/tests/UITests/Tests/DragAndDropUITests.cs +++ b/src/Controls/tests/UITests/Tests/DragAndDropUITests.cs @@ -20,12 +20,6 @@ protected override void FixtureSetup() App.NavigateToGallery(DragAndDropGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.Gestures)] public void DragEvents() diff --git a/src/Controls/tests/UITests/Tests/GestureRecognizerUITests.cs b/src/Controls/tests/UITests/Tests/GestureRecognizerUITests.cs index 5e56a8e1bb53..09db4e794044 100644 --- a/src/Controls/tests/UITests/Tests/GestureRecognizerUITests.cs +++ b/src/Controls/tests/UITests/Tests/GestureRecognizerUITests.cs @@ -19,12 +19,6 @@ protected override void FixtureSetup() App.NavigateToGallery(GestureRecognizerGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.Gestures)] public void PointerGestureTest() diff --git a/src/Controls/tests/UITests/Tests/Issues/HideSoftInputOnTappedPageTests.cs b/src/Controls/tests/UITests/Tests/Issues/HideSoftInputOnTappedPageTests.cs index 4a3a28131671..42d30f69d438 100644 --- a/src/Controls/tests/UITests/Tests/Issues/HideSoftInputOnTappedPageTests.cs +++ b/src/Controls/tests/UITests/Tests/Issues/HideSoftInputOnTappedPageTests.cs @@ -70,6 +70,7 @@ void HideSoftInputOnTappedPageTestForAndroidiOS(string control, bool hideOnTappe else App.Tap("HideSoftInputOnTappedFalse"); + App.WaitForElement(control); App.Tap(control); Assert.True(App.IsKeyboardShown()); @@ -142,6 +143,7 @@ public void TogglingHideSoftInputOnTappedForAndroidiOS() // Switch between enabling/disabling feature for (int i = 0; i < 2; i++) { + App.WaitForElement("HideKeyboardWhenTappingPage"); App.Tap("HideKeyboardWhenTappingPage"); Assert.True(App.IsKeyboardShown()); App.Tap("EmptySpace"); diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue14257.cs b/src/Controls/tests/UITests/Tests/Issues/Issue14257.cs index 09fc3ce12447..302e4a053c22 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue14257.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue14257.cs @@ -14,6 +14,8 @@ public Issue14257(TestDevice device) : base(device) { } [Category(UITestCategories.ScrollView)] public void ResizeScrollViewAndTapButtonTest() { + App.WaitForElement("Resize"); + // Tapping the Resize button will change the height of the ScrollView content App.Tap("Resize"); diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue14829.cs b/src/Controls/tests/UITests/Tests/Issues/Issue14829.cs index 992ab47d6ca8..3a3d1fa03fbd 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue14829.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue14829.cs @@ -14,7 +14,7 @@ public Issue14829(TestDevice device) : base(device) [Test] [Category(UITestCategories.ActionSheet)] - public void Issue14829Test() + public void DisplayActionSheetStillNotWorkingOnWindows() { this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.Android, TestDevice.Mac, TestDevice.iOS }, "Only affects Windows."); diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue16094.cs b/src/Controls/tests/UITests/Tests/Issues/Issue16094.cs index 91a1b430e712..fd0a9b474e6d 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue16094.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue16094.cs @@ -14,8 +14,12 @@ public Issue16094(TestDevice device) [Test] [Category(UITestCategories.Editor)] - public void Issue16094Test() + public void ShadowsDontRespectControlShape() { + this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.Mac }); + + App.WaitForElement("TestScrollView"); + App.ScrollDown("TestScrollView", ScrollStrategy.Gesture); App.WaitForElement("EditorControl"); VerifyScreenshot(); } diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue16386.cs b/src/Controls/tests/UITests/Tests/Issues/Issue16386.cs index d8cf963e8a03..e666f7de6567 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue16386.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue16386.cs @@ -24,6 +24,7 @@ public void HittingEnterKeySendsDone() TestDevice.Windows, }); + App.WaitForElement("HardwareEnterKeyEntry"); App.Tap("HardwareEnterKeyEntry"); App.SendKeys(66); App.WaitForElement("Success"); diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue19283.cs b/src/Controls/tests/UITests/Tests/Issues/Issue19283.cs index d40f54b91493..954c7f4567ac 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue19283.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue19283.cs @@ -14,6 +14,7 @@ public Issue19283(TestDevice device) : base(device) { } [Category(UITestCategories.Button)] public void ButtonStillWorksWhenItHasPointerOverVSMSet() { + App.WaitForElement("btn"); App.Tap("btn"); App.WaitForElement("Success"); } diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue21631.cs b/src/Controls/tests/UITests/Tests/Issues/Issue21631.cs index c14ad533a888..b99b38986d93 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue21631.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue21631.cs @@ -12,6 +12,8 @@ public Issue21631(TestDevice device) : base(device) { } "Injecting base tag in Webview2 works"; [Test] + [Ignore("WebView seems to be unreliably loading the image")] + [Category(UITestCategories.WebView)] public async Task NavigateToStringWithWebviewWorks() { this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.Android, TestDevice.Mac, TestDevice.iOS }); diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue5354.cs b/src/Controls/tests/UITests/Tests/Issues/Issue5354.cs index e19d341519d2..3ad93ff12ed7 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue5354.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue5354.cs @@ -4,7 +4,7 @@ using UITest.Core; -namespace Maui.Controls.Sample.Issues +namespace Microsoft.Maui.AppiumTests.Issues { public partial class Issue5354 : _IssuesUITest { @@ -16,14 +16,14 @@ public Issue5354(TestDevice device) : base(device) { } [Category(UITestCategories.CollectionView)] public void CollectionViewItemsLayoutUpdate() { - this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.iOS, TestDevice.Mac, TestDevice.Windows }, - "This is a product bug."); - + this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.iOS, TestDevice.Mac, TestDevice.Windows }, + "This is a product bug."); + App.WaitForElement("CollectionView5354"); App.WaitForElement("Button5354"); - - for(int i = 0; i < 3; i++) - { + + for (int i = 0; i < 3; i++) + { var linearRect0 = App.WaitForElement("Image0").GetRect(); var linearRect1 = App.WaitForElement("Image1").GetRect(); @@ -37,7 +37,7 @@ public void CollectionViewItemsLayoutUpdate() Assert.AreEqual(gridRect0.Y, gridRect1.Y); Assert.AreEqual(gridRect0.Height, gridRect1.Height); - + App.Click("Button5354"); } } diff --git a/src/Controls/tests/UITests/Tests/Issues/Issue5555.cs b/src/Controls/tests/UITests/Tests/Issues/Issue5555.cs index dcc5fa6b1e85..82981ff19bd0 100644 --- a/src/Controls/tests/UITests/Tests/Issues/Issue5555.cs +++ b/src/Controls/tests/UITests/Tests/Issues/Issue5555.cs @@ -10,7 +10,7 @@ public class Issue5555 : _IssuesUITest public Issue5555(TestDevice device) : base(device) { } - + [Test] [Category(UITestCategories.TableView)] public void TableViewMemoryLeakWhenUsingSwitchCellOrEntryCell() diff --git a/src/Controls/tests/UITests/Tests/Issues/RefreshViewTests.cs b/src/Controls/tests/UITests/Tests/Issues/RefreshViewTests.cs index b572fbc6c338..a4c8e215b6e8 100644 --- a/src/Controls/tests/UITests/Tests/Issues/RefreshViewTests.cs +++ b/src/Controls/tests/UITests/Tests/Issues/RefreshViewTests.cs @@ -16,6 +16,7 @@ public RefreshViewTests(TestDevice device) [Category(UITestCategories.RefreshView)] public void IsRefreshingAndCommandTest() { + App.WaitForElement("ToggleRefresh"); App.Tap("ToggleRefresh"); Assert.IsTrue(App.WaitForTextToBePresentInElement("IsRefreshingLabel", "IsRefreshing: True")); Assert.IsTrue(App.WaitForTextToBePresentInElement("IsRefreshingLabel", "IsRefreshing: False")); diff --git a/src/Controls/tests/UITests/Tests/Issues/ScrollViewUITests.ScrollChangeOrientation.cs b/src/Controls/tests/UITests/Tests/Issues/ScrollViewUITests.ScrollChangeOrientation.cs index 31356f450c36..e5f24b935bd6 100644 --- a/src/Controls/tests/UITests/Tests/Issues/ScrollViewUITests.ScrollChangeOrientation.cs +++ b/src/Controls/tests/UITests/Tests/Issues/ScrollViewUITests.ScrollChangeOrientation.cs @@ -20,23 +20,28 @@ public void ScrollRotationRelayoutIssue() { this.IgnoreIfPlatforms(new TestDevice[] { TestDevice.Mac, TestDevice.Windows }); - App.WaitForElement("Button1"); + try + { + App.WaitForElement("Button1"); - App.SetOrientationLandscape(); + App.SetOrientationLandscape(); - var buttonAutomationIds = new[] - { + var buttonAutomationIds = new[] + { "Button1", "Button2", "Button3", }; - foreach (string buttonAutomationId in buttonAutomationIds) - App.WaitForElement(buttonAutomationId); + foreach (string buttonAutomationId in buttonAutomationIds) + App.WaitForElement(buttonAutomationId); - App.Screenshot("StackLayout respects rotation"); - - App.SetOrientationPortrait(); + App.Screenshot("StackLayout respects rotation"); + } + finally + { + App.SetOrientationPortrait(); + } } } } \ No newline at end of file diff --git a/src/Controls/tests/UITests/Tests/Issues/_IssuesUITest.cs b/src/Controls/tests/UITests/Tests/Issues/_IssuesUITest.cs index 779ea35ca49b..747ab9fd00c6 100644 --- a/src/Controls/tests/UITests/Tests/Issues/_IssuesUITest.cs +++ b/src/Controls/tests/UITests/Tests/Issues/_IssuesUITest.cs @@ -34,31 +34,14 @@ protected override void FixtureSetup() } } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - try - { - this.Back(); - App.Tap("GoBackToGalleriesButton"); - } - catch (Exception e) - { - var name = TestContext.CurrentContext.Test.MethodName ?? TestContext.CurrentContext.Test.Name; - TestContext.Error.WriteLine($">>>>> {DateTime.Now} The FixtureTeardown threw an exception during {name}.{Environment.NewLine}Exception details: {e}"); - } - } - public abstract string Issue { get; } private void NavigateToIssue(string issue) { - App.NavigateToIssues(); - - App.EnterText("SearchBarGo", issue); - - App.WaitForElement("SearchButton"); - App.Tap("SearchButton"); + App.WaitForElement("GoToTestButton", issue); + App.EnterText("SearchBar", issue); + App.WaitForElement("GoToTestButton"); + App.Tap("GoToTestButton"); } } } \ No newline at end of file diff --git a/src/Controls/tests/UITests/Tests/KeyboardScrollingGridTests.cs b/src/Controls/tests/UITests/Tests/KeyboardScrollingGridTests.cs index fb97d91ee304..1313ea460d5d 100644 --- a/src/Controls/tests/UITests/Tests/KeyboardScrollingGridTests.cs +++ b/src/Controls/tests/UITests/Tests/KeyboardScrollingGridTests.cs @@ -18,12 +18,6 @@ protected override void FixtureSetup() App.NavigateToGallery(KeyboardScrollingGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] public void GridStarRowScrollingTest() { diff --git a/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageLargeTitlesTests.cs b/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageLargeTitlesTests.cs index 4b89e207a56e..38e287b52886 100644 --- a/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageLargeTitlesTests.cs +++ b/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageLargeTitlesTests.cs @@ -18,12 +18,6 @@ protected override void FixtureSetup() App.NavigateToGallery(KeyboardScrollingGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] public void EntriesScrollingPageTest() { diff --git a/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageSmallTitlesTests.cs b/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageSmallTitlesTests.cs index 7bc43407c191..cf265205451a 100644 --- a/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageSmallTitlesTests.cs +++ b/src/Controls/tests/UITests/Tests/KeyboardScrollingNonScrollingPageSmallTitlesTests.cs @@ -18,12 +18,6 @@ protected override void FixtureSetup() App.NavigateToGallery(KeyboardScrollingGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - // [Test] // public void EntriesScrollingPageTest() // { diff --git a/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageLargeTitlesTests.cs b/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageLargeTitlesTests.cs index bbcc54f587a3..7eb93d60cf51 100644 --- a/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageLargeTitlesTests.cs +++ b/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageLargeTitlesTests.cs @@ -18,12 +18,6 @@ protected override void FixtureSetup() App.NavigateToGallery(KeyboardScrollingGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - // [Test] // public void EntriesScrollingPageTest() // { diff --git a/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageSmallTitlesTests.cs b/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageSmallTitlesTests.cs index a8638ef6f56e..94ce78e53723 100644 --- a/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageSmallTitlesTests.cs +++ b/src/Controls/tests/UITests/Tests/KeyboardScrollingScrollingPageSmallTitlesTests.cs @@ -18,12 +18,6 @@ protected override void FixtureSetup() App.NavigateToGallery(KeyboardScrollingGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - // [Test] // public void EntriesScrollingPageTest() // { diff --git a/src/Controls/tests/UITests/Tests/ScrollViewUITests.cs b/src/Controls/tests/UITests/Tests/ScrollViewUITests.cs index 7d450d9edda3..fe87c3a88a4e 100644 --- a/src/Controls/tests/UITests/Tests/ScrollViewUITests.cs +++ b/src/Controls/tests/UITests/Tests/ScrollViewUITests.cs @@ -20,12 +20,6 @@ protected override void FixtureSetup() App.NavigateToGallery(LayoutGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.ScrollView)] [Description("Scroll element to the start")] diff --git a/src/Controls/tests/UITests/Tests/SliderUITests.cs b/src/Controls/tests/UITests/Tests/SliderUITests.cs index 223f7591672d..acb73cffaabd 100644 --- a/src/Controls/tests/UITests/Tests/SliderUITests.cs +++ b/src/Controls/tests/UITests/Tests/SliderUITests.cs @@ -19,12 +19,6 @@ protected override void FixtureSetup() App.NavigateToGallery(SliderGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.Slider)] [Description("Set different slider values")] diff --git a/src/Controls/tests/UITests/Tests/SwipeViewUITests.cs b/src/Controls/tests/UITests/Tests/SwipeViewUITests.cs index 798138852f2d..7b864462c61f 100644 --- a/src/Controls/tests/UITests/Tests/SwipeViewUITests.cs +++ b/src/Controls/tests/UITests/Tests/SwipeViewUITests.cs @@ -24,12 +24,6 @@ protected override void FixtureSetup() App.NavigateToGallery(ScrollViewGallery); } - protected override void FixtureTeardown() - { - base.FixtureTeardown(); - this.Back(); - } - [Test] [Category(UITestCategories.SwipeView)] [Description("Swipe to right the SwipeView")] diff --git a/src/Controls/tests/UITests/UtilExtensions.cs b/src/Controls/tests/UITests/UtilExtensions.cs index f6c2d484f23d..7b5c834ec464 100644 --- a/src/Controls/tests/UITests/UtilExtensions.cs +++ b/src/Controls/tests/UITests/UtilExtensions.cs @@ -47,17 +47,6 @@ public static void NavigateTo(this IApp app, string text) app.WaitForNoElement(goToTestButtonId, "Timed out waiting for Go To Test button to disappear", TimeSpan.FromMinutes(1)); } - public static void NavigateToIssues(this IApp app) - { - app.WaitForElement(goToTestButtonId, "Timed out waiting for Go To Test button to appear", TimeSpan.FromMinutes(2)); - - app.WaitForElement("SearchBar"); - app.ClearText("SearchBar"); - - app.Tap(goToTestButtonId); - app.WaitForElement("TestCasesIssueList"); - } - public static int CenterX(this Rectangle rect) { return rect.X + rect.Width / 2; diff --git a/src/Controls/tests/UITests/snapshots/android/ContentPageBackgroundImageSourceWorks.png b/src/Controls/tests/UITests/snapshots/android/ContentPageBackgroundImageSourceWorks.png index db24d826488c..ca7cc44daa44 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/ContentPageBackgroundImageSourceWorks.png and b/src/Controls/tests/UITests/snapshots/android/ContentPageBackgroundImageSourceWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/EditorBackgroundWorks.png b/src/Controls/tests/UITests/snapshots/android/EditorBackgroundWorks.png index 8521481b5075..b17c7b29fa6b 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/EditorBackgroundWorks.png and b/src/Controls/tests/UITests/snapshots/android/EditorBackgroundWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/EditorIsReadOnlyPreventModify.png b/src/Controls/tests/UITests/snapshots/android/EditorIsReadOnlyPreventModify.png index 3b670127e726..d87d4ba8b628 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/EditorIsReadOnlyPreventModify.png and b/src/Controls/tests/UITests/snapshots/android/EditorIsReadOnlyPreventModify.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/EntryIsPasswordObscureText.png b/src/Controls/tests/UITests/snapshots/android/EntryIsPasswordObscureText.png index 951d2a3bd147..60444f599170 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/EntryIsPasswordObscureText.png and b/src/Controls/tests/UITests/snapshots/android/EntryIsPasswordObscureText.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png b/src/Controls/tests/UITests/snapshots/android/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png index 9f93e6312beb..53f2ce251618 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png and b/src/Controls/tests/UITests/snapshots/android/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/Issue15330Test.png b/src/Controls/tests/UITests/snapshots/android/Issue15330Test.png index 8aefbfe51fa5..9fdffd54c815 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/Issue15330Test.png and b/src/Controls/tests/UITests/snapshots/android/Issue15330Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/Issue16094Test.png b/src/Controls/tests/UITests/snapshots/android/Issue16094Test.png deleted file mode 100644 index 09a645f9fa2f..000000000000 Binary files a/src/Controls/tests/UITests/snapshots/android/Issue16094Test.png and /dev/null differ diff --git a/src/Controls/tests/UITests/snapshots/android/Issue18242Test.png b/src/Controls/tests/UITests/snapshots/android/Issue18242Test.png index 5c70351fed51..334c07d5c133 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/Issue18242Test.png and b/src/Controls/tests/UITests/snapshots/android/Issue18242Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/Issue18896Test.png b/src/Controls/tests/UITests/snapshots/android/Issue18896Test.png index 2c26c1bf7a2e..f9f7a84dd283 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/Issue18896Test.png and b/src/Controls/tests/UITests/snapshots/android/Issue18896Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/Issue21513Test.png b/src/Controls/tests/UITests/snapshots/android/Issue21513Test.png index 246b8fb1af7d..c822b763aae4 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/Issue21513Test.png and b/src/Controls/tests/UITests/snapshots/android/Issue21513Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyGif.png b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyGif.png index 59a6e6c09daa..533e7cc8a05a 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyGif.png and b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyGif.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyJpg.png b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyJpg.png index 98cf290fe970..20a50fd78c08 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyJpg.png and b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyJpg.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyPng.png b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyPng.png index d15518a20f4e..8e9dc59030f8 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyPng.png and b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifyPng.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifySvg.png b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifySvg.png index 47f1581f02b2..0de03721b2a8 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/LoadAndVerifySvg.png and b/src/Controls/tests/UITests/snapshots/android/LoadAndVerifySvg.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/PropertiesShouldBeCorrectlyApplied.png b/src/Controls/tests/UITests/snapshots/android/PropertiesShouldBeCorrectlyApplied.png index 64928b2d107a..5644305ccb38 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/PropertiesShouldBeCorrectlyApplied.png and b/src/Controls/tests/UITests/snapshots/android/PropertiesShouldBeCorrectlyApplied.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/RefreshIconDisappearsWhenUserCancelsRefreshByScrollingBackUp.png b/src/Controls/tests/UITests/snapshots/android/RefreshIconDisappearsWhenUserCancelsRefreshByScrollingBackUp.png index a0623eddb150..4a944c45a096 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/RefreshIconDisappearsWhenUserCancelsRefreshByScrollingBackUp.png and b/src/Controls/tests/UITests/snapshots/android/RefreshIconDisappearsWhenUserCancelsRefreshByScrollingBackUp.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/ShadowsDontRespectControlShape.png b/src/Controls/tests/UITests/snapshots/android/ShadowsDontRespectControlShape.png new file mode 100644 index 000000000000..348375c09eb1 Binary files /dev/null and b/src/Controls/tests/UITests/snapshots/android/ShadowsDontRespectControlShape.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/SpanLineHeightShouldNotGrowProgressively.png b/src/Controls/tests/UITests/snapshots/android/SpanLineHeightShouldNotGrowProgressively.png index d271ee66bfc9..786df402c4bc 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/SpanLineHeightShouldNotGrowProgressively.png and b/src/Controls/tests/UITests/snapshots/android/SpanLineHeightShouldNotGrowProgressively.png differ diff --git a/src/Controls/tests/UITests/snapshots/android/SystemFontsShouldRenderCorrectly.png b/src/Controls/tests/UITests/snapshots/android/SystemFontsShouldRenderCorrectly.png index de1843b4e012..f3396c693a1c 100644 Binary files a/src/Controls/tests/UITests/snapshots/android/SystemFontsShouldRenderCorrectly.png and b/src/Controls/tests/UITests/snapshots/android/SystemFontsShouldRenderCorrectly.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/CarouselItemLoadsInCorrectPosition.png b/src/Controls/tests/UITests/snapshots/ios/CarouselItemLoadsInCorrectPosition.png index a6afe1da22eb..4d13c4404e93 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/CarouselItemLoadsInCorrectPosition.png and b/src/Controls/tests/UITests/snapshots/ios/CarouselItemLoadsInCorrectPosition.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/ContentPageBackgroundImageSourceWorks.png b/src/Controls/tests/UITests/snapshots/ios/ContentPageBackgroundImageSourceWorks.png index 3ff9fdef4313..8faf623e6aa5 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/ContentPageBackgroundImageSourceWorks.png and b/src/Controls/tests/UITests/snapshots/ios/ContentPageBackgroundImageSourceWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/EditorBackgroundWorks.png b/src/Controls/tests/UITests/snapshots/ios/EditorBackgroundWorks.png index f512a188e3b3..19938ed2fb3c 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/EditorBackgroundWorks.png and b/src/Controls/tests/UITests/snapshots/ios/EditorBackgroundWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/EditorIsReadOnlyPreventModify.png b/src/Controls/tests/UITests/snapshots/ios/EditorIsReadOnlyPreventModify.png index ed59e56dd566..52ea570441f3 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/EditorIsReadOnlyPreventModify.png and b/src/Controls/tests/UITests/snapshots/ios/EditorIsReadOnlyPreventModify.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/EditorPlaceholderPosition.png b/src/Controls/tests/UITests/snapshots/ios/EditorPlaceholderPosition.png index 9969b4d5d25b..7d39e08438fa 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/EditorPlaceholderPosition.png and b/src/Controls/tests/UITests/snapshots/ios/EditorPlaceholderPosition.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png b/src/Controls/tests/UITests/snapshots/ios/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png index 42a2d0d756c9..bbe483d85c1c 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png and b/src/Controls/tests/UITests/snapshots/ios/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/Issue16094Test.png b/src/Controls/tests/UITests/snapshots/ios/Issue16094Test.png deleted file mode 100644 index 9b89426ba8b9..000000000000 Binary files a/src/Controls/tests/UITests/snapshots/ios/Issue16094Test.png and /dev/null differ diff --git a/src/Controls/tests/UITests/snapshots/ios/Issue17366Test.png b/src/Controls/tests/UITests/snapshots/ios/Issue17366Test.png index 412baccd7cca..21695b0ef1e4 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/Issue17366Test.png and b/src/Controls/tests/UITests/snapshots/ios/Issue17366Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyGif.png b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyGif.png index e8e996f940cd..df1dcb84d13f 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyGif.png and b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyGif.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyJpg.png b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyJpg.png index 2d00ea1ab13f..5d7f9a53f25e 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyJpg.png and b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyJpg.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyPng.png b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyPng.png index a352b083cda3..9b1197980b95 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyPng.png and b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifyPng.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifySvg.png b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifySvg.png index 9079a111e768..de53753de38b 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifySvg.png and b/src/Controls/tests/UITests/snapshots/ios/LoadAndVerifySvg.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks-iOS-UITestBaseTearDown-ScreenShot-0b04d693dcdb426aa0e39747f469b61d.png b/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks-iOS-UITestBaseTearDown-ScreenShot-0b04d693dcdb426aa0e39747f469b61d.png new file mode 100644 index 000000000000..e6b8c0840685 Binary files /dev/null and b/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks-iOS-UITestBaseTearDown-ScreenShot-0b04d693dcdb426aa0e39747f469b61d.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks.png b/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks.png index 604b6313ab85..2e86d5197131 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks.png and b/src/Controls/tests/UITests/snapshots/ios/SettingMaximumTrackColorOnSliderWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/ShadowsDontRespectControlShape.png b/src/Controls/tests/UITests/snapshots/ios/ShadowsDontRespectControlShape.png new file mode 100644 index 000000000000..5e758de331f6 Binary files /dev/null and b/src/Controls/tests/UITests/snapshots/ios/ShadowsDontRespectControlShape.png differ diff --git a/src/Controls/tests/UITests/snapshots/ios/UpdateCollectionViewHeaderTest.png b/src/Controls/tests/UITests/snapshots/ios/UpdateCollectionViewHeaderTest.png index 916365046f78..1c32e31b0813 100644 Binary files a/src/Controls/tests/UITests/snapshots/ios/UpdateCollectionViewHeaderTest.png and b/src/Controls/tests/UITests/snapshots/ios/UpdateCollectionViewHeaderTest.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/ContentPageBackgroundImageSourceWorks.png b/src/Controls/tests/UITests/snapshots/windows/ContentPageBackgroundImageSourceWorks.png index 77566b899dfb..31676402a888 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/ContentPageBackgroundImageSourceWorks.png and b/src/Controls/tests/UITests/snapshots/windows/ContentPageBackgroundImageSourceWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/DisplayActionSheetStillNotWorkingOnWindows.png b/src/Controls/tests/UITests/snapshots/windows/DisplayActionSheetStillNotWorkingOnWindows.png new file mode 100644 index 000000000000..6c0ac292b475 Binary files /dev/null and b/src/Controls/tests/UITests/snapshots/windows/DisplayActionSheetStillNotWorkingOnWindows.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/EditorBackgroundWorks.png b/src/Controls/tests/UITests/snapshots/windows/EditorBackgroundWorks.png index 33e6acd3a1ab..beb7cb6c7c8b 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/EditorBackgroundWorks.png and b/src/Controls/tests/UITests/snapshots/windows/EditorBackgroundWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/EditorIsReadOnlyPreventModify.png b/src/Controls/tests/UITests/snapshots/windows/EditorIsReadOnlyPreventModify.png index a07bbe6f07ea..97bebd1de54d 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/EditorIsReadOnlyPreventModify.png and b/src/Controls/tests/UITests/snapshots/windows/EditorIsReadOnlyPreventModify.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/EntryIsPasswordObscureText.png b/src/Controls/tests/UITests/snapshots/windows/EntryIsPasswordObscureText.png index bdc68b37d70f..af010d67a12f 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/EntryIsPasswordObscureText.png and b/src/Controls/tests/UITests/snapshots/windows/EntryIsPasswordObscureText.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png b/src/Controls/tests/UITests/snapshots/windows/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png index 00820118a827..1ca2c8e92158 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png and b/src/Controls/tests/UITests/snapshots/windows/EntryTextColorStopsWorkingAfterPropertyIsUpdatedFromBinding.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue14829Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue14829Test.png deleted file mode 100644 index 851285bd3e03..000000000000 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue14829Test.png and /dev/null differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue15330Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue15330Test.png index f618fcd1ef21..09b56a6bc1a9 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue15330Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue15330Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue16094Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue16094Test.png deleted file mode 100644 index 89c83e1410ad..000000000000 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue16094Test.png and /dev/null differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue16918Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue16918Test.png index 659307eedaa0..c1f75e07c6ea 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue16918Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue16918Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue17400Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue17400Test.png index 1191e3aea546..a286afdbbf02 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue17400Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue17400Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue17694Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue17694Test.png index 2527dca6fed3..2123f5e764dd 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue17694Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue17694Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue18242Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue18242Test.png index ea9a862f4bdf..d7d7f46e7811 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue18242Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue18242Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue21202Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue21202Test.png index 4ade659ee1a5..8a5dfec91506 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue21202Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue21202Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue21394Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue21394Test.png index 7f6451a606e1..935d6c83233a 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue21394Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue21394Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/Issue21513Test.png b/src/Controls/tests/UITests/snapshots/windows/Issue21513Test.png index d8f59f86d625..32f6179c5624 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/Issue21513Test.png and b/src/Controls/tests/UITests/snapshots/windows/Issue21513Test.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyGif.png b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyGif.png index b9ae142b1759..3164c2f8d217 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyGif.png and b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyGif.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyJpg.png b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyJpg.png index 76f476ac1705..5a8e2b372ff9 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyJpg.png and b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyJpg.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyPng.png b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyPng.png index f9b5c230e433..e2a27d10c753 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyPng.png and b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifyPng.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifySvg.png b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifySvg.png index 6543fe3c5805..0be5c5278b05 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifySvg.png and b/src/Controls/tests/UITests/snapshots/windows/LoadAndVerifySvg.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/NavigateToStringWithWebviewWorks.png b/src/Controls/tests/UITests/snapshots/windows/NavigateToStringWithWebviewWorks.png index aecb430ed3c8..3db8889f2b85 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/NavigateToStringWithWebviewWorks.png and b/src/Controls/tests/UITests/snapshots/windows/NavigateToStringWithWebviewWorks.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/ShadowsDontRespectControlShape.png b/src/Controls/tests/UITests/snapshots/windows/ShadowsDontRespectControlShape.png new file mode 100644 index 000000000000..6fd5df1edce0 Binary files /dev/null and b/src/Controls/tests/UITests/snapshots/windows/ShadowsDontRespectControlShape.png differ diff --git a/src/Controls/tests/UITests/snapshots/windows/VerifyCollectionViewItemsAfterScrolling.png b/src/Controls/tests/UITests/snapshots/windows/VerifyCollectionViewItemsAfterScrolling.png index 3d0655289de1..fab42bab7a57 100644 Binary files a/src/Controls/tests/UITests/snapshots/windows/VerifyCollectionViewItemsAfterScrolling.png and b/src/Controls/tests/UITests/snapshots/windows/VerifyCollectionViewItemsAfterScrolling.png differ diff --git a/src/TestUtils/src/UITest.Appium/HelperExtensions.cs b/src/TestUtils/src/UITest.Appium/HelperExtensions.cs index 4acac365e99b..e99caac17f61 100644 --- a/src/TestUtils/src/UITest.Appium/HelperExtensions.cs +++ b/src/TestUtils/src/UITest.Appium/HelperExtensions.cs @@ -34,11 +34,6 @@ public static void Click(this IApp app, string element) app.FindElement(element).Click(); } - public static void Tap(this IApp app, string element) - { - app.FindElement(element).Click(); - } - public static string? GetText(this IUIElement element) { var response = element.Command.Execute("getText", new Dictionary() diff --git a/src/TestUtils/src/UITest.NUnit/UITestBase.cs b/src/TestUtils/src/UITest.NUnit/UITestBase.cs index 6ca6ad3b47f3..02773797d69b 100644 --- a/src/TestUtils/src/UITest.NUnit/UITestBase.cs +++ b/src/TestUtils/src/UITest.NUnit/UITestBase.cs @@ -49,8 +49,15 @@ protected virtual void FixtureSetup() protected virtual void FixtureTeardown() { - var name = TestContext.CurrentContext.Test.MethodName ?? TestContext.CurrentContext.Test.Name; - TestContext.Progress.WriteLine($">>>>> {DateTime.Now} {nameof(FixtureTeardown)} for {name}"); + try + { + Reset(); + } + catch (Exception e) + { + var name = TestContext.CurrentContext.Test.MethodName ?? TestContext.CurrentContext.Test.Name; + TestContext.Error.WriteLine($">>>>> {DateTime.Now} The FixtureTeardown threw an exception during {name}.{Environment.NewLine}Exception details: {e}"); + } } [TearDown]