diff --git a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/TapGestureRecognizerNotWorkingOnEntry.png b/src/Controls/tests/TestCases.Android.Tests/snapshots/android/TapGestureRecognizerNotWorkingOnEntry.png deleted file mode 100644 index bc1c6dbd76bb..000000000000 Binary files a/src/Controls/tests/TestCases.Android.Tests/snapshots/android/TapGestureRecognizerNotWorkingOnEntry.png and /dev/null differ diff --git a/src/Controls/tests/TestCases.HostApp/Issues/Issue12213.cs b/src/Controls/tests/TestCases.HostApp/Issues/Issue12213.cs index b3ec6d474a85..dddbe6fe3d67 100644 --- a/src/Controls/tests/TestCases.HostApp/Issues/Issue12213.cs +++ b/src/Controls/tests/TestCases.HostApp/Issues/Issue12213.cs @@ -29,7 +29,11 @@ protected override void Init() private void TapGestureRecognizer_Tapped(object sender, TappedEventArgs e) { - DisplayAlert("Entry", "Tapped", "OK"); + Label label = new Label { Text = "Tapped" }; + if (Content is Layout layout) + { + layout.Children.Add(label); + } } } } diff --git a/src/Controls/tests/TestCases.HostApp/Issues/Issue25038.xaml.cs b/src/Controls/tests/TestCases.HostApp/Issues/Issue25038.xaml.cs index fdb134a62479..0e7a12626b91 100644 --- a/src/Controls/tests/TestCases.HostApp/Issues/Issue25038.xaml.cs +++ b/src/Controls/tests/TestCases.HostApp/Issues/Issue25038.xaml.cs @@ -1,7 +1,7 @@ namespace Maui.Controls.Sample.Issues { - [Issue(IssueTracker.Github, 25038, "MAUI Entry in Windows always shows ClearButton if initially hidden and shown even if ClearButtonVisibility set to 'Never'", PlatformAffected.UWP)] + [Issue(IssueTracker.Github, 25038, "MAUI Entry in Windows always shows ClearButton if initially hidden and shown even if ClearButtonVisibility set to Never", PlatformAffected.UWP)] public partial class Issue25038 : ContentPage { public Issue25038() diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CarouselViewShouldScrollToRightPosition.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CarouselViewShouldScrollToRightPosition.png new file mode 100644 index 000000000000..ecb503d6478a Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CarouselViewShouldScrollToRightPosition.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewFooterMovestoBottomWithEmptyvieworEmptyviewTemplate.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewFooterMovestoBottomWithEmptyvieworEmptyviewTemplate.png new file mode 100644 index 000000000000..917ee3b824f1 Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewFooterMovestoBottomWithEmptyvieworEmptyviewTemplate.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewHeaderBlankWhenLastItemRemoved.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewHeaderBlankWhenLastItemRemoved.png new file mode 100644 index 000000000000..5d9f2ab9ef3d Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionViewHeaderBlankWhenLastItemRemoved.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionviewFooterHideswhenDynamicallyAddorRemoveItems.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionviewFooterHideswhenDynamicallyAddorRemoveItems.png new file mode 100644 index 000000000000..5eae1467a75e Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/CollectionviewFooterHideswhenDynamicallyAddorRemoveItems.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/Shell_Issue21916.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/Shell_Issue21916.png new file mode 100644 index 000000000000..d50f0fa5635e Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/Shell_Issue21916.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/TabbedPageUnselectedBarTextColorConsistency.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/TabbedPageUnselectedBarTextColorConsistency.png new file mode 100644 index 000000000000..dd5a29fee0bf Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/TabbedPageUnselectedBarTextColorConsistency.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyCollectionViewVisualState.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyCollectionViewVisualState.png new file mode 100644 index 000000000000..b793a730f5af Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyCollectionViewVisualState.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryClearButtonVisibility.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryClearButtonVisibility.png new file mode 100644 index 000000000000..9ef17bba2a13 Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryClearButtonVisibility.png differ diff --git a/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryHorizontalEndTextAlignmentPosition.png b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryHorizontalEndTextAlignmentPosition.png new file mode 100644 index 000000000000..4ce8bfabfb84 Binary files /dev/null and b/src/Controls/tests/TestCases.Mac.Tests/snapshots/mac/VerifyEntryHorizontalEndTextAlignmentPosition.png differ diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Bugzilla/Bugzilla39702.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Bugzilla/Bugzilla39702.cs index ea9753f4b2fd..a120dc4dab0a 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Bugzilla/Bugzilla39702.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Bugzilla/Bugzilla39702.cs @@ -23,7 +23,7 @@ public void ControlCanBeFocusedByUnfocusedEvent() { App.WaitForElement(TheEntry); App.EnterText(TheEntry, Success); - App.WaitForElement(Success); + App.WaitForElementTillPageNavigationSettled(Success); } } } \ No newline at end of file diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue11896.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue11896.cs index a057489b7ddf..9226ae8ecaff 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue11896.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue11896.cs @@ -1,4 +1,4 @@ -#if !MACCATALYST && !WINDOWS +#if TEST_FAILS_ON_WINDOWS //for more information:https://github.com/dotnet/maui/issues/24968 using NUnit.Framework; using UITest.Appium; using UITest.Core; diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue12213.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue12213.cs index 2105e1c52033..b7b41454779a 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue12213.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue12213.cs @@ -1,5 +1,4 @@ -#if !MACCATALYST -using NUnit.Framework; +using NUnit.Framework; using UITest.Appium; using UITest.Core; @@ -20,8 +19,7 @@ public void TapGestureRecognizerNotWorkingOnEntry() { App.WaitForElement("Entry"); App.Tap("Entry"); - VerifyScreenshot(); + App.WaitForElement("Tapped"); } } -} -#endif \ No newline at end of file +} \ No newline at end of file diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue17283.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue17283.cs index dc752dca3cd9..049fa2b24081 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue17283.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue17283.cs @@ -1,4 +1,5 @@ -using NUnit.Framework; +#if TEST_FAILS_ON_WINDOWS +using NUnit.Framework; using UITest.Appium; using UITest.Core; @@ -13,7 +14,6 @@ public Issue17283(TestDevice testDevice) : base(testDevice) { } [Test] [Category(UITestCategories.CarouselView)] [FailsOnWindowsWhenRunningOnXamarinUITest("Currently fails on Windows; see https://github.com/dotnet/maui/issues/24482")] - [FailsOnMacWhenRunningOnXamarinUITest("VerifyScreenshot is not implemented on Mac")] public void CarouselViewShouldScrollToRightPosition() { App.WaitForElement("goToLastItemButton"); @@ -24,4 +24,5 @@ public void CarouselViewShouldScrollToRightPosition() VerifyScreenshot(); } } -} \ No newline at end of file +} +#endif \ No newline at end of file diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue18775.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue18775.cs index 9c968ca40f7f..45fe13a028c7 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue18775.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue18775.cs @@ -15,7 +15,6 @@ public Issue18775(TestDevice device) : base(device) [Test] [Category(UITestCategories.TabbedPage)] - [FailsOnMacWhenRunningOnXamarinUITest] public void TabbedPageUnselectedBarTextColorConsistency() { App.WaitForElement("MauiLabel"); diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue21916.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue21916.cs index 0c6c8e5ab3c5..323a063f03ef 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue21916.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue21916.cs @@ -1,4 +1,4 @@ -#if !ANDROID && !MACCATALYST +#if TEST_FAILS_ON_ANDROID //more information: https://github.com/dotnet/maui/issues/26050 using NUnit.Framework; using UITest.Appium; using UITest.Core; diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue22104.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue22104.cs index d5b8849a8778..003e83d698a3 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue22104.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue22104.cs @@ -14,8 +14,6 @@ public Issue22104(TestDevice testDevice) : base(testDevice) [Test] [Category(UITestCategories.CollectionView)] - [FailsOnMacWhenRunningOnXamarinUITest] - [FailsOnIOSWhenRunningOnXamarinUITest] public void VerifyCollectionViewVisualState() { App.WaitForElement("CollectionView"); diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue23291.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue23291.cs index e0107c2d4ab0..3542d68bbc7b 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue23291.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue23291.cs @@ -18,9 +18,9 @@ public void Issue23291Test() { App.WaitForElement("button"); App.Click("button"); - App.WaitForElement("openFragmentTwoButton"); + App.WaitForElementTillPageNavigationSettled("openFragmentTwoButton"); App.Click("openFragmentTwoButton"); - App.WaitForElement("fragmentTwoLabel"); + App.WaitForElementTillPageNavigationSettled("fragmentTwoLabel"); } } } \ No newline at end of file diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24405.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24405.cs index 6ff2c9666713..1897ae670a39 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24405.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24405.cs @@ -14,7 +14,6 @@ public Issue24405(TestDevice testDevice) : base(testDevice) [Test] [Category(UITestCategories.Entry)] - [FailsOnMacWhenRunningOnXamarinUITest] public void VerifyEntryHorizontalEndTextAlignmentPosition() { App.WaitForElement("button"); diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24966.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24966.cs index bf748724280f..6780ec1d9fe4 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24966.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue24966.cs @@ -1,4 +1,4 @@ -#if !MACCATALYST && !WINDOWS +#if TEST_FAILS_ON_WINDOWS // more information: https://github.com/dotnet/maui/issues/24968 using NUnit.Framework; using UITest.Appium; using UITest.Core; diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue25038.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue25038.cs index 08fd6f4542df..7ce3ea7fe536 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue25038.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue25038.cs @@ -10,11 +10,10 @@ public Issue25038(TestDevice testDevice) : base(testDevice) { } - public override string Issue => "MAUI Entry in Windows always shows ClearButton if initially hidden and shown even if ClearButtonVisibility set to 'Never'"; + public override string Issue => "MAUI Entry in Windows always shows ClearButton if initially hidden and shown even if ClearButtonVisibility set to Never"; [Test] [Category(UITestCategories.Entry)] - [FailsOnMacWhenRunningOnXamarinUITest] public void VerifyEntryClearButtonVisibility() { App.WaitForElement("button"); diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue5669.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue5669.cs index 4b8998bf0f2b..bdf8ca9b5022 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue5669.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue5669.cs @@ -1,4 +1,3 @@ -#if !MACCATALYST using NUnit.Framework; using UITest.Appium; using UITest.Core; @@ -20,9 +19,14 @@ public void SearchBarMaxLength() App.EnterText("SearchBar", "r"); App.Click("ChangeValue"); App.EnterText("SearchBar", "r"); - App.EnterText("SearchBar", "c"); + App.EnterText("SearchBar", "c"); +#if MACCATALYST + // On MacCatalyst, pressing the ESC key during screenshot capture clears the text. + // This causes the image generated in CI to differ from local runs. + Assert.That(App.WaitForElement("Sear").GetText(), Is.EqualTo("Sear")); +#else VerifyScreenshot(); +#endif } } -} -#endif \ No newline at end of file +} \ No newline at end of file diff --git a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue7453.cs b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue7453.cs index b8672f3e2f37..e54909b1f654 100644 --- a/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue7453.cs +++ b/src/Controls/tests/TestCases.Shared.Tests/Tests/Issues/Issue7453.cs @@ -1,4 +1,4 @@ -#if !MACCATALYST +#if TEST_FAILS_ON_CATALYST // more information:https://github.com/dotnet/maui/issues/26864 using System; using System.Collections.Generic; using System.Linq; diff --git a/src/Controls/tests/TestCases.WinUI.Tests/snapshots/windows/TapGestureRecognizerNotWorkingOnEntry.png b/src/Controls/tests/TestCases.WinUI.Tests/snapshots/windows/TapGestureRecognizerNotWorkingOnEntry.png deleted file mode 100644 index 5a6ad6daf8cf..000000000000 Binary files a/src/Controls/tests/TestCases.WinUI.Tests/snapshots/windows/TapGestureRecognizerNotWorkingOnEntry.png and /dev/null differ diff --git a/src/Controls/tests/TestCases.iOS.Tests/snapshots/ios/TapGestureRecognizerNotWorkingOnEntry.png b/src/Controls/tests/TestCases.iOS.Tests/snapshots/ios/TapGestureRecognizerNotWorkingOnEntry.png deleted file mode 100644 index da86e9ffe4fc..000000000000 Binary files a/src/Controls/tests/TestCases.iOS.Tests/snapshots/ios/TapGestureRecognizerNotWorkingOnEntry.png and /dev/null differ