From cd193f3a11cd697656f456738c5750b36346fdce Mon Sep 17 00:00:00 2001 From: nohwnd Date: Fri, 6 Mar 2026 18:47:06 +0100 Subject: [PATCH 1/7] Annotated --- .../BlameDataCollectorTests.cs | 3 +++ .../CodeCoverageTests.cs | 1 + .../DataCollectionTests.cs | 1 + .../DataCollectorAttachmentsProcessorsFactoryTests.cs | 1 + .../DataCollectorTests.Coverlet.cs | 1 + .../DebugAssertTests.cs | 1 + .../DeprecateExtensionsPathWarningTests.cs | 1 + .../DifferentTestFrameworkSimpleTests.cs | 1 + .../DisableAppdomainTests.cs | 1 + .../DiscoveryTests.cs | 1 + .../DotnetArchitectureSwitchTests.Windows.cs | 1 + .../DotnetHostArchitectureVerifierTests.cs | 1 + .../DotnetTestMSBuildOutputTests.cs | 1 + .../DotnetTestTests.cs | 1 + .../EventLogCollectorTests.cs | 1 + .../ExecutionTests.cs | 1 + .../ExecutionThreadApartmentStateTests.cs | 1 + .../FilePatternParserTests.cs | 1 + .../FrameworkTests.cs | 1 + .../ListExtensionsTests.cs | 1 + .../LoggerTests.cs | 1 + .../MultitargetingTestHostTests.cs | 1 + .../PlatformTests.cs | 1 + .../PortableNugetPackageTests.cs | 1 + .../PostProcessingTests.cs | 1 + .../ProcessesInteractionTests.cs | 1 + .../RecursiveResourcesLookupTests.cs | 1 + .../ResultsDirectoryTests.cs | 1 + .../RunsettingsTests.cs | 1 + .../SelfContainedAppTests.cs | 1 + .../TelemetryTests.cs | 1 + .../TestCaseFilterTests.cs | 1 + .../TestPlatformNugetPackageTests.cs | 1 + 33 files changed, 35 insertions(+) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs index f61f8939de..63f2c99b32 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs @@ -22,6 +22,8 @@ namespace Microsoft.TestPlatform.AcceptanceTests; // this whole thing is complicated and depends on versions of OS and the target runtime // keeping this for later [TestCategory("Windows-Review")] +[TestCategory("aaa")] +[TestCategory("Windows-Skip-NETFXTFM")] public class BlameDataCollectorTests : AcceptanceTestBase { public const string NETCOREANDFX = "net462;net472;net8.0"; @@ -41,6 +43,7 @@ public BlameDataCollectorTests() } [TestMethod] + [TestCategory("aaa")] [TestCategory("Windows-Review")] [NetFullTargetFrameworkDataSource] [NetCoreTargetFrameworkDataSource] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs index 9bad647034..f9442ffd60 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs @@ -45,6 +45,7 @@ public enum SettingsType [TestClass] //Code coverage only supported on windows (based on the message in output) [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class CodeCoverageTests : CodeCoverageAcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs index 2ff6512274..2f4964ebef 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs @@ -17,6 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DataCollectionTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs index 5a7284c7cf..e12577b492 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs @@ -22,6 +22,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests.DataCollectorAttachmentsProcessorsFactoryTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DataCollectorAttachmentsProcessorsFactoryTests : AcceptanceTestBase { private readonly DataCollectorAttachmentsProcessorsFactory _dataCollectorAttachmentsProcessorsFactory = new(); diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs index 9931acf617..ebff7d1405 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs @@ -12,6 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DataCollectorTestsCoverlets : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs index abff214c4a..783183f687 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs @@ -10,6 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; public class DebugAssertTests : AcceptanceTestBase { [TestMethod] + [TestCategory("Windows-Skip-NETFXTFM")] // this is core only, there is nothing we can do about TPDebug.Assert crashing the process on framework [NetCoreTargetFrameworkDataSource(useDesktopRunner: false)] public void RunningTestWithAFailingDebugAssertDoesNotCrashTheHostingProcess(RunnerInfo runnerInfo) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DeprecateExtensionsPathWarningTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DeprecateExtensionsPathWarningTests.cs index 7f0ca13acc..6a515ec7f9 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DeprecateExtensionsPathWarningTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DeprecateExtensionsPathWarningTests.cs @@ -11,6 +11,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] +// TODO: but where are some tests? :D public class DeprecateExtensionsPathWarningTests : AcceptanceTestBase { private readonly IList _adapterDependencies; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs index cde8909ee8..c87924e232 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs @@ -12,6 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class DifferentTestFrameworkSimpleTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs index ba8b103749..19b4c75f2d 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs @@ -12,6 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows")] +[TestCategory("Windows-Skip-NETFXTFM")] public class DisableAppdomainTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs index 5fc1cd39a3..fadfda33e0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs @@ -15,6 +15,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DiscoveryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs index e9c803cfde..b1cc69948b 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs @@ -18,6 +18,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class DotnetArchitectureSwitchTestsWindowsOnly : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs index b74d03f42c..da6f163089 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs @@ -17,6 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // On Linux/Mac we don't download the same .NET SDK bundles [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class DotnetHostArchitectureVerifierTests : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs index 995ee1e133..22fb941d3d 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs @@ -13,6 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; /// Running dotnet test + csproj and using MSBuild for the output. /// [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DotnetTestMSBuildOutputTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs index 621ca677eb..2c3eb47e1a 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class DotnetTestTests : AcceptanceTestBase { private static string GetFinalVersion(string version) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs index abadb1e3e5..d69d2ebaf4 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs @@ -13,6 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class EventLogCollectorTests : AcceptanceTestBase { // Fails randomly https://ci.dot.net/job/Microsoft_vstest/job/master/job/Windows_NT_Release_prtest/2084/console diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs index 47761acff0..c82b3b64ff 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs @@ -16,6 +16,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class ExecutionTests : AcceptanceTestBase { //TODO: It looks like the first 3 tests would be useful to multiply by all 3 test frameworks, should we make the test even more generic, or duplicate them? diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs index 2a1c903c4c..e392699092 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs @@ -8,6 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class ExecutionThreadApartmentStateTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs index a7f30c2ad9..8c62229f61 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class FilePatternParserTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs index 29f2bccb69..8fac77987e 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class FrameworkTests : AcceptanceTestBase { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs index b268f3e639..6769cbbde6 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs @@ -8,6 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // this is tested only on .NET Framework [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class ListExtensionsTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs index 4bf30e4da6..30ad19cbf7 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs @@ -12,6 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class LoggerTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs index aa90fc1833..4a29e4bef8 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class MultitargetingTestHostTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs index ce0d229720..ea160ba83c 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class PlatformTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs index 7c14708898..4ce855351c 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class PortableNugetPackageTests : AcceptanceTestBase { private static string s_portablePackageFolder = string.Empty; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs index af147a3afc..f3b0095263 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs @@ -20,6 +20,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class PostProcessingTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs index 32228f1da8..1f3460b829 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs @@ -8,6 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class ProcessesInteractionTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs index f18852d87f..7333e312ec 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs @@ -7,6 +7,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class RecursiveResourcesLookupTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs index e6961f7fb4..d821ca0c85 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs @@ -10,6 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class ResultsDirectoryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs index 4eec7dc7d0..d0394edb4f 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs @@ -14,6 +14,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] +[TestCategory("Windows-Skip-NETFXTFM")] public class RunsettingsTests : AcceptanceTestBase { #region Runsettings precedence tests diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs index 531f35c012..163c7e52fa 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs @@ -13,6 +13,7 @@ public class SelfContainedAppTests : AcceptanceTestBase { [TestMethod] [TestCategory("Windows-Review")] + [TestCategory("Windows-Skip-NETFXTFM")] [NetCoreTargetFrameworkDataSourceAttribute(useDesktopRunner: false)] public void RunningApplicationThatIsBuiltAsSelfContainedWillNotFailToFindHostpolicyDll(RunnerInfo runnerInfo) { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs index 33efe78895..9596e7051b 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs @@ -13,6 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class TelemetryTests : AcceptanceTestBase { private const string TELEMETRY_OPTEDIN = "VSTEST_TELEMETRY_OPTEDIN"; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs index e5e451ddd4..6d8750d60b 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs @@ -9,6 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class TestCaseFilterTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs index 712e00b6e8..ae5719ff4e 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs @@ -10,6 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] +[TestCategory("Windows-Skip-NETFXTFM")] public class TestPlatformNugetPackageTests : CodeCoverageAcceptanceTestBase { private static string s_nugetPackageFolder = string.Empty; From 3e4608a28daaa99c341dbd74f34d0ce2166d3a78 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 09:19:26 +0100 Subject: [PATCH 2/7] Replace dotnet.config, with global.json dotnet.config is no longer suppported way of configuring mtp, replace it with global.json --- dotnet.config | 2 -- global.json | 5 +++- .../IntegrationTestBase.cs | 23 +++++++++++++++---- 3 files changed, 23 insertions(+), 7 deletions(-) delete mode 100644 dotnet.config diff --git a/dotnet.config b/dotnet.config deleted file mode 100644 index da0410e32d..0000000000 --- a/dotnet.config +++ /dev/null @@ -1,2 +0,0 @@ -[dotnet.test.runner] -name = "Microsoft.Testing.Platform" diff --git a/global.json b/global.json index 78c60c808b..5be95d1a74 100644 --- a/global.json +++ b/global.json @@ -40,5 +40,8 @@ }, "msbuild-sdks": { "Microsoft.DotNet.Arcade.Sdk": "11.0.0-beta.26127.1" + }, + "test": { + "runner": "Microsoft.Testing.Platform" } -} +} \ No newline at end of file diff --git a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs index a49811291f..32dc4a564f 100644 --- a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs +++ b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs @@ -202,13 +202,28 @@ public void InvokeVsTest(string? arguments, Dictionary? environ /// public void InvokeDotnetTest(string arguments, Dictionary? environmentVariables = null, string? workingDirectory = null) { - if (workingDirectory is not null && !File.Exists(Path.Combine(workingDirectory, "dotnet.config"))) + string globalJsonPath = Path.Combine(workingDirectory!, "global.json"); + if (workingDirectory is not null && !File.Exists(globalJsonPath)) { - File.WriteAllText(Path.Combine(workingDirectory, "dotnet.config"), """ - [dotnet.test.runner] - name = "VSTest" + // Add global.json to the working directory, to ensure we use vstest to run tests, + // global.json is resolved from the working directory, and its parents, so this just makes sure we enforce vstest, + // even though we use TestingPlatform to run unit tests. + File.WriteAllText(Path.Combine(workingDirectory, "global.json"), """ + { + "test": { + "runner": "vstest", + } + } """); } + else + { + string globalJsonText = File.ReadAllText(globalJsonPath); + if (!globalJsonText.Contains("\"runner\": \"vstest\"")) + { + throw new InvalidOperationException($"Custom global.json in path '{globalJsonPath}' does not specify test runner as VSTest.\nContent:\n{globalJsonText}"); + } + } var debugEnvironmentVariables = AddDebugEnvironmentVariables(environmentVariables); From 79f1475e197fdd192a3eb3599b9ca99de44987a2 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 10:00:09 +0100 Subject: [PATCH 3/7] Add conditional attribute to skip tests --- ...pIntegrationTestOnNetConditionAttribute.cs | 23 +++++++++++++++++++ 1 file changed, 23 insertions(+) create mode 100644 test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs new file mode 100644 index 0000000000..931b816ff4 --- /dev/null +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs @@ -0,0 +1,23 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT license. See LICENSE file in the project root for full license information. + +using System.Runtime.InteropServices; + +using Microsoft.VisualStudio.TestTools.UnitTesting; + +namespace Microsoft.TestPlatform.AcceptanceTests; + +public class SkipIntegrationTestOnNetConditionAttribute : ConditionBaseAttribute +{ + private readonly bool _include; + + public SkipIntegrationTestOnNetConditionAttribute() : base(ConditionMode.Include) + { + _include = RuntimeInformation.FrameworkDescription.StartsWith(".NET Framework"); + IgnoreMessage = "Test was skipped to avoid duplication of the same out-of-process tests between .NET and .NET Framework."; + } + + public override string GroupName => "tfm"; + + public override bool IsConditionMet => _include; +} From 71d3da95cdc849f4459c94ebda6f0c86816e7503 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 10:43:42 +0100 Subject: [PATCH 4/7] Skip duplicated tests on .NET --- .../BlameDataCollectorTests.cs | 5 +---- .../CodeCoverageTests.cs | 2 +- .../DataCollectionTests.cs | 2 +- .../DataCollectorAttachmentsProcessorsFactoryTests.cs | 2 +- .../DataCollectorTests.Coverlet.cs | 2 +- .../DebugAssertTests.cs | 2 +- .../DifferentTestFrameworkSimpleTests.cs | 2 +- .../DisableAppdomainTests.cs | 2 +- .../DiscoveryTests.cs | 2 +- .../DotnetArchitectureSwitchTests.Windows.cs | 2 +- .../DotnetHostArchitectureVerifierTests.cs | 2 +- .../DotnetTestMSBuildOutputTests.cs | 2 +- .../DotnetTestTests.cs | 2 +- .../EventLogCollectorTests.cs | 2 +- .../ExecutionTests.cs | 2 +- .../ExecutionThreadApartmentStateTests.cs | 2 +- .../FilePatternParserTests.cs | 2 +- .../FrameworkTests.cs | 2 +- .../ListExtensionsTests.cs | 2 +- .../LoggerTests.cs | 2 +- .../MultitargetingTestHostTests.cs | 2 +- .../PlatformTests.cs | 2 +- .../PortableNugetPackageTests.cs | 2 +- .../PostProcessingTests.cs | 2 +- .../ProcessesInteractionTests.cs | 2 +- .../RecursiveResourcesLookupTests.cs | 2 +- .../ResultsDirectoryTests.cs | 2 +- .../RunsettingsTests.cs | 2 +- .../SelfContainedAppTests.cs | 2 +- .../TelemetryTests.cs | 2 +- .../TestCaseFilterTests.cs | 2 +- .../TestPlatformNugetPackageTests.cs | 2 +- 32 files changed, 32 insertions(+), 35 deletions(-) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs index 63f2c99b32..551ffc12bd 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs @@ -19,11 +19,8 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -// this whole thing is complicated and depends on versions of OS and the target runtime -// keeping this for later [TestCategory("Windows-Review")] -[TestCategory("aaa")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class BlameDataCollectorTests : AcceptanceTestBase { public const string NETCOREANDFX = "net462;net472;net8.0"; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs index f9442ffd60..860c90ab54 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs @@ -45,7 +45,7 @@ public enum SettingsType [TestClass] //Code coverage only supported on windows (based on the message in output) [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class CodeCoverageTests : CodeCoverageAcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs index 2f4964ebef..79a949079c 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs @@ -17,7 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DataCollectionTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs index d64d07f39d..d1676c40f9 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs @@ -22,7 +22,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests.DataCollectorAttachmentsProcessorsFactoryTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DataCollectorAttachmentsProcessorsFactoryTests : AcceptanceTestBase { private readonly DataCollectorAttachmentsProcessorsFactory _dataCollectorAttachmentsProcessorsFactory = new(); diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs index ebff7d1405..39e43ca091 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DataCollectorTestsCoverlets : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs index 783183f687..24320e7c0c 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; public class DebugAssertTests : AcceptanceTestBase { [TestMethod] - [TestCategory("Windows-Skip-NETFXTFM")] + [SkipIntegrationTestOnNetCondition] // this is core only, there is nothing we can do about TPDebug.Assert crashing the process on framework [NetCoreTargetFrameworkDataSource(useDesktopRunner: false)] public void RunningTestWithAFailingDebugAssertDoesNotCrashTheHostingProcess(RunnerInfo runnerInfo) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs index c87924e232..0239035b75 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DifferentTestFrameworkSimpleTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs index 19b4c75f2d..5eebeafbc2 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DisableAppdomainTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs index fadfda33e0..f1763381e2 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs @@ -15,7 +15,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DiscoveryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs index b1cc69948b..b89a827ad4 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs @@ -18,7 +18,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DotnetArchitectureSwitchTestsWindowsOnly : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs index da6f163089..2a5c4cc51e 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs @@ -17,7 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // On Linux/Mac we don't download the same .NET SDK bundles [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DotnetHostArchitectureVerifierTests : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs index 43e039645c..61079eec91 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; /// Running dotnet test + csproj and using MSBuild for the output. /// [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DotnetTestMSBuildOutputTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs index 2c3eb47e1a..5323719ab9 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class DotnetTestTests : AcceptanceTestBase { private static string GetFinalVersion(string version) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs index d69d2ebaf4..f423873482 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class EventLogCollectorTests : AcceptanceTestBase { // Fails randomly https://ci.dot.net/job/Microsoft_vstest/job/master/job/Windows_NT_Release_prtest/2084/console diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs index 9a8d40d5bd..8855f9349d 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs @@ -16,7 +16,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class ExecutionTests : AcceptanceTestBase { //TODO: It looks like the first 3 tests would be useful to multiply by all 3 test frameworks, should we make the test even more generic, or duplicate them? diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs index e392699092..65a9599540 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class ExecutionThreadApartmentStateTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs index 8c62229f61..e5fc6563ec 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class FilePatternParserTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs index 8fac77987e..b137fbad8a 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class FrameworkTests : AcceptanceTestBase { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs index 6769cbbde6..50a0e2f81d 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // this is tested only on .NET Framework [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class ListExtensionsTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs index 30ad19cbf7..7fc61e2b34 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class LoggerTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs index 4a29e4bef8..216e20bfe0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class MultitargetingTestHostTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs index ea160ba83c..4aa28ae455 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class PlatformTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs index 4ce855351c..dbd404fd0d 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class PortableNugetPackageTests : AcceptanceTestBase { private static string s_portablePackageFolder = string.Empty; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs index abfdebb924..64a1755aa0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs @@ -20,7 +20,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class PostProcessingTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs index 1f3460b829..487b05d9b2 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class ProcessesInteractionTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs index 7333e312ec..fb8b0994e0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs @@ -7,7 +7,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class RecursiveResourcesLookupTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs index d821ca0c85..00d102072c 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class ResultsDirectoryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs index d0394edb4f..acbb6c4585 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs @@ -14,7 +14,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class RunsettingsTests : AcceptanceTestBase { #region Runsettings precedence tests diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs index 163c7e52fa..46ed5321b1 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs @@ -13,7 +13,7 @@ public class SelfContainedAppTests : AcceptanceTestBase { [TestMethod] [TestCategory("Windows-Review")] - [TestCategory("Windows-Skip-NETFXTFM")] + [SkipIntegrationTestOnNetCondition] [NetCoreTargetFrameworkDataSourceAttribute(useDesktopRunner: false)] public void RunningApplicationThatIsBuiltAsSelfContainedWillNotFailToFindHostpolicyDll(RunnerInfo runnerInfo) { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs index 1453233b85..fda01b0a40 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class TelemetryTests : AcceptanceTestBase { private const string TELEMETRY_OPTEDIN = "VSTEST_TELEMETRY_OPTEDIN"; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs index 6d8750d60b..a128eb9a9e 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class TestCaseFilterTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs index ae5719ff4e..717a6ac77f 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[TestCategory("Windows-Skip-NETFXTFM")] +[SkipIntegrationTestOnNetCondition] public class TestPlatformNugetPackageTests : CodeCoverageAcceptanceTestBase { private static string s_nugetPackageFolder = string.Empty; From f1602e24681d5bbb8f65dc3916139b6a9bdc8cc7 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 11:57:25 +0100 Subject: [PATCH 5/7] Fix attachVS when used for debugging integration tests --- .../IntegrationTestBase.cs | 3 +++ .../Microsoft.TestPlatform.TestUtilities.csproj | 1 + 2 files changed, 4 insertions(+) diff --git a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs index a49811291f..7402bce1b0 100644 --- a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs +++ b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs @@ -8,6 +8,7 @@ using System.Globalization; using System.IO; using System.Linq; +using System.Reflection; using System.Text; using System.Text.RegularExpressions; using System.Xml; @@ -262,6 +263,8 @@ public void InvokeVsTestForExecution(string testAssembly, if (_testEnvironment.DebugInfo != null) { + environmentVariables["VSTEST_DEBUG_ATTACHVS_PATH"] = + Path.Combine(Path.GetDirectoryName(Assembly.GetCallingAssembly().Location)!, "AttachVS.exe"); if (_testEnvironment.DebugInfo.DebugVSTestConsole) { environmentVariables["VSTEST_RUNNER_DEBUG_ATTACHVS"] = "1"; diff --git a/test/Microsoft.TestPlatform.TestUtilities/Microsoft.TestPlatform.TestUtilities.csproj b/test/Microsoft.TestPlatform.TestUtilities/Microsoft.TestPlatform.TestUtilities.csproj index 14a64925bc..a06b1bd18f 100644 --- a/test/Microsoft.TestPlatform.TestUtilities/Microsoft.TestPlatform.TestUtilities.csproj +++ b/test/Microsoft.TestPlatform.TestUtilities/Microsoft.TestPlatform.TestUtilities.csproj @@ -17,6 +17,7 @@ + From 686cb949abaf39ef4534674d7de09db244fb2892 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 12:28:22 +0100 Subject: [PATCH 6/7] Fix comma --- .../Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs index 429af828bc..2b232a4d28 100644 --- a/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs +++ b/test/Microsoft.TestPlatform.TestUtilities/IntegrationTestBase.cs @@ -212,7 +212,7 @@ public void InvokeDotnetTest(string arguments, Dictionary? envi File.WriteAllText(Path.Combine(workingDirectory, "global.json"), """ { "test": { - "runner": "vstest", + "runner": "vstest" } } """); From 8e58288f00ca7f2f9855376982643a3e5ec67de0 Mon Sep 17 00:00:00 2001 From: nohwnd Date: Mon, 9 Mar 2026 15:42:29 +0100 Subject: [PATCH 7/7] Run on .NET, skip on .NET Framework --- .../BlameDataCollectorTests.cs | 3 +-- .../CodeCoverageTests.cs | 2 +- .../DataCollectionTests.cs | 2 +- .../DataCollectorAttachmentsProcessorsFactoryTests.cs | 2 +- .../DataCollectorTests.Coverlet.cs | 2 +- .../DebugAssertTests.cs | 2 +- .../DifferentTestFrameworkSimpleTests.cs | 2 +- .../DisableAppdomainTests.cs | 2 +- .../DiscoveryTests.cs | 2 +- .../DotnetArchitectureSwitchTests.Windows.cs | 2 +- .../DotnetHostArchitectureVerifierTests.cs | 2 +- .../DotnetTestMSBuildOutputTests.cs | 2 +- .../DotnetTestTests.cs | 2 +- .../EventLogCollectorTests.cs | 2 +- .../ExecutionTests.cs | 2 +- .../ExecutionThreadApartmentStateTests.cs | 2 +- .../FilePatternParserTests.cs | 2 +- .../FrameworkTests.cs | 2 +- .../ListExtensionsTests.cs | 2 +- .../LoggerTests.cs | 2 +- .../MultitargetingTestHostTests.cs | 2 +- .../PlatformTests.cs | 2 +- .../PortableNugetPackageTests.cs | 2 +- .../PostProcessingTests.cs | 2 +- .../ProcessesInteractionTests.cs | 2 +- .../RecursiveResourcesLookupTests.cs | 2 +- .../ResultsDirectoryTests.cs | 2 +- .../RunsettingsTests.cs | 2 +- .../SelfContainedAppTests.cs | 2 +- ...kipIOutOfProcessTestOnNetFrameworkConditionAttribute.cs} | 6 +++--- .../TelemetryTests.cs | 2 +- .../TestCaseFilterTests.cs | 2 +- .../TestPlatformNugetPackageTests.cs | 2 +- 33 files changed, 35 insertions(+), 36 deletions(-) rename test/Microsoft.TestPlatform.Acceptance.IntegrationTests/{SkipIntegrationTestOnNetConditionAttribute.cs => SkipIOutOfProcessTestOnNetFrameworkConditionAttribute.cs} (68%) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs index 551ffc12bd..7bc5dbc814 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/BlameDataCollectorTests.cs @@ -20,7 +20,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class BlameDataCollectorTests : AcceptanceTestBase { public const string NETCOREANDFX = "net462;net472;net8.0"; @@ -40,7 +40,6 @@ public BlameDataCollectorTests() } [TestMethod] - [TestCategory("aaa")] [TestCategory("Windows-Review")] [NetFullTargetFrameworkDataSource] [NetCoreTargetFrameworkDataSource] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs index 860c90ab54..8d36a32493 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/CodeCoverageTests.cs @@ -45,7 +45,7 @@ public enum SettingsType [TestClass] //Code coverage only supported on windows (based on the message in output) [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class CodeCoverageTests : CodeCoverageAcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs index 79a949079c..d1215d1557 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectionTests.cs @@ -17,7 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DataCollectionTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs index d1676c40f9..8d9d9df7ed 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorAttachmentsProcessorsFactoryTests.cs @@ -22,7 +22,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests.DataCollectorAttachmentsProcessorsFactoryTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DataCollectorAttachmentsProcessorsFactoryTests : AcceptanceTestBase { private readonly DataCollectorAttachmentsProcessorsFactory _dataCollectorAttachmentsProcessorsFactory = new(); diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs index 39e43ca091..106b1300e4 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DataCollectorTests.Coverlet.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DataCollectorTestsCoverlets : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs index 24320e7c0c..a618295ec6 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DebugAssertTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; public class DebugAssertTests : AcceptanceTestBase { [TestMethod] - [SkipIntegrationTestOnNetCondition] + [SkipIOutOfProcessTestOnNetFrameworkCondition] // this is core only, there is nothing we can do about TPDebug.Assert crashing the process on framework [NetCoreTargetFrameworkDataSource(useDesktopRunner: false)] public void RunningTestWithAFailingDebugAssertDoesNotCrashTheHostingProcess(RunnerInfo runnerInfo) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs index 0239035b75..c16bb39140 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DifferentTestFrameworkSimpleTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DifferentTestFrameworkSimpleTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs index 5eebeafbc2..fda1dbba98 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DisableAppdomainTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DisableAppdomainTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs index f1763381e2..6d96a921bf 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DiscoveryTests.cs @@ -15,7 +15,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DiscoveryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs index b89a827ad4..8183b0d5d1 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetArchitectureSwitchTests.Windows.cs @@ -18,7 +18,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DotnetArchitectureSwitchTestsWindowsOnly : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs index 2a5c4cc51e..100394f7be 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetHostArchitectureVerifierTests.cs @@ -17,7 +17,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // On Linux/Mac we don't download the same .NET SDK bundles [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DotnetHostArchitectureVerifierTests : IntegrationTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs index 61079eec91..d61602db26 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestMSBuildOutputTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; /// Running dotnet test + csproj and using MSBuild for the output. /// [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DotnetTestMSBuildOutputTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs index 5323719ab9..36b81f4201 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/DotnetTestTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class DotnetTestTests : AcceptanceTestBase { private static string GetFinalVersion(string version) diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs index f423873482..a13dc4e0e4 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/EventLogCollectorTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class EventLogCollectorTests : AcceptanceTestBase { // Fails randomly https://ci.dot.net/job/Microsoft_vstest/job/master/job/Windows_NT_Release_prtest/2084/console diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs index 8855f9349d..5c32e27320 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionTests.cs @@ -16,7 +16,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class ExecutionTests : AcceptanceTestBase { //TODO: It looks like the first 3 tests would be useful to multiply by all 3 test frameworks, should we make the test even more generic, or duplicate them? diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs index 65a9599540..e663a43e82 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ExecutionThreadApartmentStateTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class ExecutionThreadApartmentStateTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs index e5fc6563ec..54782ae862 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FilePatternParserTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class FilePatternParserTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs index b137fbad8a..e966e4d349 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/FrameworkTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class FrameworkTests : AcceptanceTestBase { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs index 50a0e2f81d..e4855fc49b 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ListExtensionsTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // this is tested only on .NET Framework [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class ListExtensionsTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs index 7fc61e2b34..f8ab02a54f 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/LoggerTests.cs @@ -12,7 +12,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class LoggerTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs index 216e20bfe0..f573ac3cc1 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/MultitargetingTestHostTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class MultitargetingTestHostTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs index 4aa28ae455..c741080a8b 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PlatformTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class PlatformTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs index dbd404fd0d..39b9848938 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PortableNugetPackageTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class PortableNugetPackageTests : AcceptanceTestBase { private static string s_portablePackageFolder = string.Empty; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs index 64a1755aa0..78ffd02587 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/PostProcessingTests.cs @@ -20,7 +20,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class PostProcessingTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs index 487b05d9b2..b1cc171cd0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ProcessesInteractionTests.cs @@ -8,7 +8,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class ProcessesInteractionTests : AcceptanceTestBase { /// diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs index fb8b0994e0..6171a7faa8 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RecursiveResourcesLookupTests.cs @@ -7,7 +7,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class RecursiveResourcesLookupTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs index 00d102072c..863f297274 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/ResultsDirectoryTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class ResultsDirectoryTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs index acbb6c4585..3054994bc6 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/RunsettingsTests.cs @@ -14,7 +14,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] // monitoring the processes does not work correctly [TestCategory("Windows-Review")] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class RunsettingsTests : AcceptanceTestBase { #region Runsettings precedence tests diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs index 46ed5321b1..d6dc821edd 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SelfContainedAppTests.cs @@ -13,7 +13,7 @@ public class SelfContainedAppTests : AcceptanceTestBase { [TestMethod] [TestCategory("Windows-Review")] - [SkipIntegrationTestOnNetCondition] + [SkipIOutOfProcessTestOnNetFrameworkCondition] [NetCoreTargetFrameworkDataSourceAttribute(useDesktopRunner: false)] public void RunningApplicationThatIsBuiltAsSelfContainedWillNotFailToFindHostpolicyDll(RunnerInfo runnerInfo) { diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIOutOfProcessTestOnNetFrameworkConditionAttribute.cs similarity index 68% rename from test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs rename to test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIOutOfProcessTestOnNetFrameworkConditionAttribute.cs index 931b816ff4..11ae3783b0 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIntegrationTestOnNetConditionAttribute.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/SkipIOutOfProcessTestOnNetFrameworkConditionAttribute.cs @@ -7,13 +7,13 @@ namespace Microsoft.TestPlatform.AcceptanceTests; -public class SkipIntegrationTestOnNetConditionAttribute : ConditionBaseAttribute +public class SkipIOutOfProcessTestOnNetFrameworkConditionAttribute : ConditionBaseAttribute { private readonly bool _include; - public SkipIntegrationTestOnNetConditionAttribute() : base(ConditionMode.Include) + public SkipIOutOfProcessTestOnNetFrameworkConditionAttribute() : base(ConditionMode.Include) { - _include = RuntimeInformation.FrameworkDescription.StartsWith(".NET Framework"); + _include = !RuntimeInformation.FrameworkDescription.StartsWith(".NET Framework"); IgnoreMessage = "Test was skipped to avoid duplication of the same out-of-process tests between .NET and .NET Framework."; } diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs index fda01b0a40..cba0e70b70 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TelemetryTests.cs @@ -13,7 +13,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class TelemetryTests : AcceptanceTestBase { private const string TELEMETRY_OPTEDIN = "VSTEST_TELEMETRY_OPTEDIN"; diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs index a128eb9a9e..5cfe93a700 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestCaseFilterTests.cs @@ -9,7 +9,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class TestCaseFilterTests : AcceptanceTestBase { [TestMethod] diff --git a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs index 717a6ac77f..918a6b21bb 100644 --- a/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs +++ b/test/Microsoft.TestPlatform.Acceptance.IntegrationTests/TestPlatformNugetPackageTests.cs @@ -10,7 +10,7 @@ namespace Microsoft.TestPlatform.AcceptanceTests; [TestClass] -[SkipIntegrationTestOnNetCondition] +[SkipIOutOfProcessTestOnNetFrameworkCondition] public class TestPlatformNugetPackageTests : CodeCoverageAcceptanceTestBase { private static string s_nugetPackageFolder = string.Empty;