Skip to content

Fix IndexWatchRunner cancellation test race - #3354

Merged
Widthdom merged 2 commits into
mainfrom
fix-issue3343
Jun 7, 2026
Merged

Fix IndexWatchRunner cancellation test race#3354
Widthdom merged 2 commits into
mainfrom
fix-issue3343

Conversation

@Widthdom

@Widthdom Widthdom commented Jun 6, 2026

Copy link
Copy Markdown
Owner

Summary

  • Synchronize IndexWatchRunnerTests cancellation checks on the actual watch-start output instead of a fixed sleep.
  • Always cancel/drain the dedicated watch task before restoring redirected console writers.
  • Document the watch-loop test synchronization rule in TESTING_GUIDE.md.
  • Keep the Windows/net9.0 CI lane bounded by skipping coverage on that slowest matrix leg and not retrying TestSessionTimeout aborts.

Validation

  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj -c Debug -p:UseSharedCompilation=false --filter "FullyQualifiedName~IndexWatchRunnerTests"
  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj -c Debug --no-restore --filter "FullyQualifiedName~CiWorkflowTests|FullyQualifiedName~IndexWatchRunnerTests"
  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj -c Debug --no-restore --filter "FullyQualifiedName~CiWorkflowTests"
  • dotnet test tests/CodeIndex.Tests/CodeIndex.Tests.csproj -c Release --framework net9.0 --no-restore --filter "FullyQualifiedName~CiWorkflowTests|FullyQualifiedName~IndexWatchRunnerTests"
  • dotnet run --project tools/CodeIndex.Changelog -- check
  • dotnet format CodeIndex.sln --verify-no-changes --no-restore
  • dotnet test CodeIndex.sln -c Debug --no-build -p:UseSharedCompilation=false
  • PowerShell probe: Tee-Object preserves $LASTEXITCODE for success and failure paths.
  • Codex adversarial review: No blocking/actionable issues found.

Documentation / Changelog

  • Updated TESTING_GUIDE.md.
  • Added changelog.d/unreleased/3343.fixed.md.
  • Added changelog.d/unreleased/3358.fixed.md.

Follow-up Candidates

None.

Fixes #3343
Fixes #3358

@Widthdom
Widthdom marked this pull request as ready for review June 7, 2026 06:01
@Widthdom
Widthdom merged commit ed69645 into main Jun 7, 2026
10 checks passed
@Widthdom
Widthdom deleted the fix-issue3343 branch June 7, 2026 06:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

1 participant