From 8626bdc3c5e153981c131634607a4ef66031d03e Mon Sep 17 00:00:00 2001 From: Shane Neuville Date: Tue, 8 Oct 2024 05:47:07 -0500 Subject: [PATCH] Disable TitleViewSetOnShellWorksAfterNavigation (#25125) --- .../DeviceTests/Elements/Shell/ShellTests.cs | 67 ------------------- 1 file changed, 67 deletions(-) diff --git a/src/Controls/tests/DeviceTests/Elements/Shell/ShellTests.cs b/src/Controls/tests/DeviceTests/Elements/Shell/ShellTests.cs index 0451f97fc292..f1a8fba6e7bc 100644 --- a/src/Controls/tests/DeviceTests/Elements/Shell/ShellTests.cs +++ b/src/Controls/tests/DeviceTests/Elements/Shell/ShellTests.cs @@ -595,73 +595,6 @@ bool viewIsTitleView(IView view) }); } - [Fact(DisplayName = "TitleView Set On Shell Works After Navigation")] - public async Task TitleViewSetOnShellWorksAfterNavigation() - { - SetupBuilder(); - - var page1 = new ContentPage(); - var page2 = new ContentPage(); - var page3 = new ContentPage(); - - var shellTitleView = new Editor(); - - var shell = await CreateShellAsync((shell) => - { - Shell.SetTitleView(shell, shellTitleView); - shell.Items.Add(new TabBar() - { - Items = - { - new ShellContent() - { - Route = "Item1", - Content = page1 - }, - new ShellContent() - { - Route = "Item2", - Content = page2 - }, - } - }); - }); - - await CreateHandlerAndAddToWindow(shell, async (handler) => - { - await OnLoadedAsync(page1); - await AssertEventually(WaitCondition); - - await shell.GoToAsync("//Item2"); - await AssertEventually(WaitCondition); - - await shell.GoToAsync("//Item1"); - await AssertEventually(WaitCondition); - - await shell.GoToAsync("//Item2"); - await AssertEventually(WaitCondition); - - await shell.Navigation.PushAsync(page3); - await AssertEventually(WaitCondition); - - await shell.Navigation.PopAsync(); - await AssertEventually(WaitCondition); - - bool WaitCondition() - { - if (shellTitleView.Handler == null) - return false; - - var titleView = GetTitleView(handler); - - if (titleView == null) - return false; - - return shellTitleView.ToPlatform() == titleView; - } - }); - } - [Fact(DisplayName = "Handlers not recreated when changing tabs")] public async Task HandlersNotRecreatedWhenChangingTabs() {