From 9fab9d9280c8450a7e4627e0db45c2157a049503 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Valentin=20Breu=C3=9F?= Date: Thu, 20 Nov 2025 16:21:09 +0100 Subject: [PATCH] fix: disable failing mutation tests This PR temporarily disables mutation tests by adding a configuration flag and applying conditional execution logic. The change allows the build pipeline to skip mutation testing until https://github.com/stryker-mutator/stryker-net/issues/3327 is resolved. ### Key changes - Added a `DisableMutationTests` boolean flag set to `true` - Applied conditional execution to `MutationTests` and `MutationTestDashboard` targets using the new flag --- Pipeline/Build.MutationTests.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Pipeline/Build.MutationTests.cs b/Pipeline/Build.MutationTests.cs index 5480033db..d418c56b5 100644 --- a/Pipeline/Build.MutationTests.cs +++ b/Pipeline/Build.MutationTests.cs @@ -22,11 +22,13 @@ namespace Build; partial class Build { + private static bool DisableMutationTests = true; AbsolutePath StrykerOutputDirectory => ArtifactsDirectory / "Stryker"; AbsolutePath StrykerToolPath => TestResultsDirectory / "dotnet-stryker"; Target MutationTestsCore => _ => _ .DependsOn(Compile) + .OnlyWhenDynamic(() => !DisableMutationTests) .OnlyWhenDynamic(() => BuildScope == BuildScope.Default) .OnlyWhenDynamic(() => Repository.Branch != "main" && Repository.Tags.Count == 0) .Executes(() => @@ -37,6 +39,7 @@ partial class Build Target MutationTestsMain => _ => _ .DependsOn(Compile) + .OnlyWhenDynamic(() => !DisableMutationTests) .OnlyWhenDynamic(() => BuildScope == BuildScope.Default) .Executes(() => { @@ -48,6 +51,7 @@ partial class Build .After(MutationTestsMain) .After(MutationTestsCore) .DependsOn(MutationTestsDashboard) + .OnlyWhenDynamic(() => !DisableMutationTests) .OnlyWhenDynamic(() => BuildScope == BuildScope.Default) .Executes(async () => { @@ -113,6 +117,7 @@ await gitHubClient.Issue.Comment.Update("aweXpect", "aweXpect", Target MutationTestsDashboard => _ => _ .After(MutationTestsMain) .After(MutationTestsCore) + .OnlyWhenDynamic(() => !DisableMutationTests) .OnlyWhenDynamic(() => BuildScope == BuildScope.Default) .Executes(async () => {