Repository navigation
Conversation
The integration tests that restore and build a generated project write a global.json pinning SDK 8.0.204 with rollForward latestMinor. The Stryker container (mcr.microsoft.com/dotnet/sdk:10.0) only ships SDK 10.x, so dotnet exits with "A compatible .NET SDK was not found", never writes result.sarif and 30 initial tests fail. Their mutants are then reported as only covered by failing tests. Use latestMajor in the test-side global.json for those builds so any installed SDK >= 8.0.204 satisfies it. The public default in Constants and WithDefaults is unchanged; the CSharp/VB VerifyDirectory snapshots are updated accordingly.
CS1998 for an async void Main without await is no longer reported by the SDK 10 compiler, which latestMajor roll-forward now selects. Use an unused local (CS0168) so the expected-warning case holds on every SDK.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #258 +/- ##
=======================================
Coverage 89.69% 89.69%
=======================================
Files 31 31
Lines 728 728
Branches 85 85
=======================================
Hits 653 653
Misses 67 67
Partials 8 8 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
In the scheduled mutation run the initial test run reports
16 tests are failing,14 tests are failingand30 tests are failing. Stryker will continue but outcome will be impacted., followed by 51Mutant N is only covered by failing testslines. Run 40488203974 (TUnit test report artifact 12728695723) shows 16 failing tests, all withFileNotFoundException '.../result.sarif'; the captured stderr in that artifact (not in the job log) saysA compatible .NET SDK was not found. Requested SDK version: 8.0.204 ... Installed SDKs:(empty). The mutation report has 40 mutantsSurvivedwith reason "Only covered by already failing tests" plus about 16 more NoCoverage mutants in the same code (ProjectFactory, ProjectFactoryExtensions, GlobalJsonBuilderExtensions, TestPackageBuilder).Root cause
The integration tests that restore/build a generated project write a
global.jsonpinning SDK 8.0.204 withrollForward: latestMinor. The shared mutation pipeline runslyndychivs/dotnet-stryker-actionin a Docker image based onmcr.microsoft.com/dotnet/sdk:10.0, which only has SDK 10.x. SDK 10 does not satisfy 8.0.204/latestMinor, sodotnetfails,result.sarifis never written and the test fails. The same tests pass in cicd.yml, which installs the needed SDKs via setup-dotnet. The 14 XUnit failures are assumed to share this cause; only the TUnit artifact was decoded, and the run on this branch verifies that.Change
Test-side only: the tests that build real projects now use
rollForward: latestMajor(ProjectFactoryTests,TestPackageBuilderTests, and the CSharp/VBBuildAsync_*tests in both integration projects). The CSharp/VBVerifyDirectorysnapshots (global.verified.json) are updated fromlatestMinortolatestMajor. The public default (Constants.RuntimeSdkDefault,WithDefaults()=latestMinor) and theGlobalJsonBuildersnapshots are unchanged.A fix in
dailydevops/pipelines(provide SDK 8/9 to the mutation job) would address the cause for all repos but would mean replacing the shared Docker action, which is a larger cross-repo change; this PR is the small repo-local alternative.Before / After
Measured with a manual mutation.yml dispatch on this branch (commit e0a086d, before the formatting-only follow-up): https://github.com/dailydevops/projectbuilders/actions/runs/40810054858 (before: the latest successful scheduled run, 2026-10-27).
Notes: the environment no longer deflates the score, but runtime grew about 10x because every covered mutant now runs a real restore and build. The 28 Timeout mutants count as detected. Two tests still fail in the initial run (one per integration project, not yet analysed); the cause is not confirmed to be the SDK. The mutation job still passes.
Risk / what this does not change
latestMajorthese builds run on whichever SDK is newest, so they no longer prove that an 8.0.x SDK specifically works.WithDefaults()output itself is still covered by the unit tests and GlobalJsonBuilder snapshots.