From b2183925f2f50394e3eca24b802b65a9ae538cc5 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 9 Sep 2026 07:10:28 +0000 Subject: [PATCH 1/3] [main] Bump MSTest.TestFramework to 4.5.0-preview.26458.16, 4.5.0-preview.26458.17 --- updated-dependencies: - dependency-name: MSTest.TestFramework dependency-version: 4.5.0-preview.26458.16 dependency-type: direct:production update-type: version-update:semver-patch - dependency-name: MSTest.TestFramework dependency-version: 4.5.0-preview.26458.17 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- eng/Versions.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Versions.props b/eng/Versions.props index 5ac810f00a..85da720f97 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -10,7 +10,7 @@ 11.0.0-beta.26458.13 18.12.0-preview.26458.2 - 4.5.0-preview.26457.5 + 4.5.0-preview.26458.17 2.5.0-preview.26457.5 From 94c6ea8cfe6202815870893e41be1b38272092fb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 9 Sep 2026 07:52:27 +0000 Subject: [PATCH 2/3] Fix nullable-reference build errors from MSTest bump [build-failure-analysis] --- .../DotnetTestPipe/DotnetTestPipeArtifactPostProcessingTests.cs | 2 +- .../CtrfReportMergerTests.cs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/DotnetTestPipe/DotnetTestPipeArtifactPostProcessingTests.cs b/test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/DotnetTestPipe/DotnetTestPipeArtifactPostProcessingTests.cs index b3896bfa3f..ada3770a16 100644 --- a/test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/DotnetTestPipe/DotnetTestPipeArtifactPostProcessingTests.cs +++ b/test/IntegrationTests/Microsoft.Testing.Platform.Acceptance.IntegrationTests/DotnetTestPipe/DotnetTestPipeArtifactPostProcessingTests.cs @@ -254,7 +254,7 @@ public async Task Dispatcher_ReportsOnlyInputsRepresentedByEachOutput() Assert.AreSequenceEqual( [firstManifestPath, secondPath], artifacts[0].InputArtifactPaths); - Assert.DoesNotContain(unrelatedPath, artifacts[0].InputArtifactPaths); + Assert.DoesNotContain(unrelatedPath, artifacts[0].InputArtifactPaths!); } finally { diff --git a/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs b/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs index 02d60a3f2a..7855e895d4 100644 --- a/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs +++ b/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs @@ -50,7 +50,7 @@ public void Merge_ConcatenatesTests() var testArray = (JsonArray)merged["results"]!["tests"]!; Assert.HasCount(3, testArray); - List names = [.. testArray.Select(t => (string?)t!["name"])]; + List names = [.. testArray.Select(t => (string)t!["name"]!)]; Assert.Contains("TestA", names); Assert.Contains("TestC", names); } From ee82fa4f5775664a1b69b6fa6b15c11d827ff80a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Amaury=20Lev=C3=A9?= Date: Wed, 9 Sep 2026 21:10:21 +0200 Subject: [PATCH 3/3] Fix analyzer regressions from MSTest update Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- test/.editorconfig | 1 + .../CtrfReportMergerTests.cs | 2 +- .../MtpServerClientInProcessTests.cs | 7 +++---- .../Microsoft.Testing.Platform.UnitTests.csproj | 2 ++ 4 files changed, 7 insertions(+), 5 deletions(-) diff --git a/test/.editorconfig b/test/.editorconfig index cf74f1f347..85d1d6ad7b 100644 --- a/test/.editorconfig +++ b/test/.editorconfig @@ -34,6 +34,7 @@ dotnet_diagnostic.CA2201.severity = none # CA2201: Do not raise reser dotnet_diagnostic.CA3075.severity = none # CA3075: Insecure DTD processing in XML dotnet_diagnostic.IDE0060.severity = none # IDE0060: Remove unused parameter +dotnet_diagnostic.IDE0300.severity = suggestion # IDE0300: Simplify collection initialization dotnet_diagnostic.MSTEST0001.severity = warning # MSTEST0001: Explicitly enable or disable tests parallelization dotnet_diagnostic.MSTEST0016.severity = warning # MSTEST0016: Test class should have test method diff --git a/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs b/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs index 7855e895d4..8fa121fdbf 100644 --- a/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs +++ b/test/UnitTests/Microsoft.Testing.Extensions.UnitTests/CtrfReportMergerTests.cs @@ -1084,7 +1084,7 @@ static JsonObject Row(string status, JsonNode? parameters, string? filePath) Assert.HasCount(4, tests, "Rows differing only by parameters or filePath are distinct tests."); Assert.AreSequenceEqual( - (string?[])["failed", "passed", "skipped", "passed"], + ["failed", "passed", "skipped", "passed"], tests.Select(t => (string?)t!["status"]).ToArray()); } diff --git a/test/UnitTests/Microsoft.Testing.Platform.ServerMode.Client.Sources.UnitTests/MtpServerClientInProcessTests.cs b/test/UnitTests/Microsoft.Testing.Platform.ServerMode.Client.Sources.UnitTests/MtpServerClientInProcessTests.cs index 75bcd5f39d..73adaaf245 100644 --- a/test/UnitTests/Microsoft.Testing.Platform.ServerMode.Client.Sources.UnitTests/MtpServerClientInProcessTests.cs +++ b/test/UnitTests/Microsoft.Testing.Platform.ServerMode.Client.Sources.UnitTests/MtpServerClientInProcessTests.cs @@ -41,7 +41,7 @@ public async Task LaunchInProcessAsync_PassesCompleteServerModeArguments() string[] arguments = server.Arguments; Assert.AreSequenceEqual( - new[] { "--server", "jsonrpc", "--client-host", "127.0.0.1", "--client-port" }, + ["--server", "jsonrpc", "--client-host", "127.0.0.1", "--client-port"], arguments.Take(5), $"The client must hand the callback a complete, ordered server-mode argument array. Actual: {string.Join(" ", arguments)}"); Assert.IsTrue( @@ -737,13 +737,12 @@ public async Task LaunchInProcessAsync_MultipleRequestsOnOneSession_ReuseTheSame server.ConnectionCount, "A stateful session must serve every request over the single connection the launch established."); Assert.AreSequenceEqual( - new[] - { + [ JsonRpcMethods.Initialize, JsonRpcMethods.TestingDiscoverTests, JsonRpcMethods.TestingRunTests, JsonRpcMethods.TestingRunTests, - }, + ], server.Value.ReceivedRequestMethods, "The stateful session must reuse one connection for the expected initialize, discover, and run requests."); } diff --git a/test/UnitTests/Microsoft.Testing.Platform.UnitTests/Microsoft.Testing.Platform.UnitTests.csproj b/test/UnitTests/Microsoft.Testing.Platform.UnitTests/Microsoft.Testing.Platform.UnitTests.csproj index 832b25fcdc..8f3d38d094 100644 --- a/test/UnitTests/Microsoft.Testing.Platform.UnitTests/Microsoft.Testing.Platform.UnitTests.csproj +++ b/test/UnitTests/Microsoft.Testing.Platform.UnitTests/Microsoft.Testing.Platform.UnitTests.csproj @@ -8,6 +8,8 @@ $(DefineConstants);IS_MTP_UNIT_TESTS true $(RepoRoot)src\Platform\Microsoft.Testing.Platform\BuildInfo.cs.template + + $(NoWarn);MSTEST0084