diff --git a/src/libraries/System.Diagnostics.Process/tests/ProcessTests.cs b/src/libraries/System.Diagnostics.Process/tests/ProcessTests.cs index f270f518296791..8efb40c1dc1332 100644 --- a/src/libraries/System.Diagnostics.Process/tests/ProcessTests.cs +++ b/src/libraries/System.Diagnostics.Process/tests/ProcessTests.cs @@ -1558,7 +1558,9 @@ public void MainWindowHandle_GetNotStarted_ThrowsInvalidOperationException() Assert.Throws(() => process.MainWindowHandle); } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoServer))] // it needs Notepad + [ConditionalFact(typeof(PlatformDetection), + nameof(PlatformDetection.IsNotWindowsNanoServer), // it needs Notepad + nameof(PlatformDetection.IsNotWindowsServerCore))] // explained in https://github.com/dotnet/runtime/pull/44972 [OuterLoop("Pops UI")] [PlatformSpecific(TestPlatforms.Windows)] public void MainWindowHandle_GetWithGui_ShouldRefresh_Windows() @@ -1591,7 +1593,9 @@ public void MainWindowHandle_GetWithGui_ShouldRefresh_Windows() } } - [ConditionalFact(typeof(PlatformDetection), nameof(PlatformDetection.IsNotWindowsNanoServer))] // it needs Notepad + [ConditionalFact(typeof(PlatformDetection), + nameof(PlatformDetection.IsNotWindowsNanoServer), // it needs Notepad + nameof(PlatformDetection.IsNotWindowsServerCore))] // explained in https://github.com/dotnet/runtime/pull/44972 [OuterLoop("Pops UI")] [PlatformSpecific(TestPlatforms.Windows)] public void MainWindowTitle_GetWithGui_ShouldRefresh_Windows() @@ -1603,8 +1607,6 @@ public void MainWindowTitle_GetWithGui_ShouldRefresh_Windows() { try { - Assert.Equal(string.Empty, process.MainWindowTitle); - for (int attempt = 0; attempt < 50; ++attempt) { process.Refresh();