Skip to content

Serialize conflicting dotnet-new template tests - #56020

Merged
nagilson merged 5 commits into
mainfrom
copilot/dotnet-new-integration-tests-hang
Sep 4, 2026
Merged

nagilson merged 5 commits into
mainfrom
copilot/dotnet-new-integration-tests-hang

Conversation

Copilot AI commented Aug 29, 2026 •

Copy link
Copy Markdown
Contributor

Three Linux Helix runs hung with CommonTemplatesTests and DotnetClassTemplateTests executing nested dotnet build processes concurrently.

  • Keep class-level parallelism for the rest of dotnet-new.IntegrationTests.
  • Give the two repeatedly implicated classes the same MSTest ResourceLock.
  • Remove MSTestParallelizeWorkers=2: the affected two-core Helix workers already selected two workers by default, so that setting did not reduce concurrency and the PR validation reproduced the hang.

The focused run completed all 304 tests from both classes (303 passed, 1 skipped), and its TRX contained no overlapping execution intervals between the classes.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
3 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI changed the title [WIP] Fix dotnet-new integration tests hang on Linux until Helix timeout Limit dotnet-new integration test parallelism Aug 29, 2026
Copilot AI requested a review from nagilson August 29, 2026 16:40
@Evangelink Evangelink changed the title Limit dotnet-new integration test parallelism Serialize conflicting dotnet-new template tests Aug 31, 2026
@nagilson
nagilson marked this pull request as ready for review September 2, 2026 19:03
@nagilson
nagilson requested a review from a team as a code owner September 2, 2026 19:03
Copilot AI lite review requested due to automatic review settings September 2, 2026 19:03
@nagilson
nagilson requested a review from a team as a code owner September 2, 2026 19:03
@nagilson
nagilson requested a review from a team September 2, 2026 19:03
@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 1 pipeline(s).
2 pipeline(s) were filtered out due to trigger conditions.
There may be pipelines that require an authorized user to comment /azp run to run.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The changes are low-risk test-serialization annotations, with only minor maintainability nits (comment traceability) identified.

Pull request overview

This PR mitigates recurring Linux Helix hangs in dotnet-new.IntegrationTests by preventing two specific template test classes from running concurrent dotnet build workloads against each other, while keeping class-level parallelism enabled for the rest of the test project.

Changes:

  • Add an MSTest ResourceLock to DotnetClassTemplateTests to serialize against the shared lock key.
  • Add the same MSTest ResourceLock to CommonTemplatesTests so the two classes cannot execute concurrently.
File summaries
File Description
test/dotnet-new.IntegrationTests/DotnetClassTemplateTests.cs Adds a class-level ResourceLock to prevent concurrent execution with CommonTemplatesTests.
test/dotnet-new.IntegrationTests/CommonTemplatesTests.cs Adds a class-level ResourceLock to prevent concurrent execution with DotnetClassTemplateTests.
Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 2
  • Review effort level: Lite

@Evangelink Evangelink left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Note

This approval was generated with GitHub Copilot after reviewing the code and linked CI evidence.

@nagilson
nagilson disabled auto-merge September 3, 2026 16:46
@nagilson
nagilson enabled auto-merge September 3, 2026 16:47
@nagilson
nagilson requested a review from a team September 3, 2026 16:47
@nagilson
nagilson merged commit fcd632a into main Sep 4, 2026
23 checks passed
@nagilson
nagilson deleted the copilot/dotnet-new-integration-tests-hang branch September 4, 2026 18:54
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 12.0-preview1 milestone Sep 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[AI discovered CI] dotnet-new integration tests hang until Helix timeout on Linux

5 participants