-
Notifications
You must be signed in to change notification settings - Fork 770
Add auto-unquarantine tests agent and workflow #13775
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
🚀 Dogfood this PR with:
curl -fsSL https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.sh | bash -s -- 13775Or
iex "& { $(irm https://raw.githubusercontent.com/dotnet/aspire/main/eng/scripts/get-aspire-cli-pr.ps1) } 13775" |
| @@ -0,0 +1,483 @@ | |||
| name: Auto-Unquarantine Tests | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@copilot This workflow should essentially just invoke the auto-quarantine-tests agent. And all the real work should be done by the agent.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done. The workflow now simply creates an issue with the agent instructions and assigns it to copilot-swe-agent. All the actual work (fetching issues, parsing reports, unquarantining tests, building, and creating PRs) is now handled by the agent.
The workflow is reduced from 483 lines to 104 lines and now just:
- Reads the agent instructions from
.github/agents/auto-unquarantine-tests.md - Creates an issue with those instructions and configuration parameters
- Assigns the issue to
copilot-swe-agent
Commit: d74e22d
Adds a GitHub Copilot agent that parses the quarantined tests dashboard issue to identify stable tests and invokes the test-disabler agent in batches to unquarantine them. Includes a workflow that runs weekly or on-demand with configurable thresholds. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
d74e22d to
1708a27
Compare
|
@copilot review the changes |
Description
Implements automated weekly unquarantining of stable tests based on CI quarantine reports. Tests with zero failures across all platforms (linux, macos, windows) and sufficient run coverage (≥90 runs per OS) are automatically unquarantined via batch PR.
Agent Definition (
.github/agents/auto-unquarantine-tests.md)[QuarantinedTest]attributesWorkflow Implementation (
.github/workflows/auto-unquarantine-tests.yml)copilot-swe-agent.github/agents/auto-unquarantine-tests.mdcopilot-swe-agentmin_runs_threshold(default: 90) passed to agent via issue bodyExample Usage
Manual trigger with custom threshold:
Quarantine report format expected:
Checklist
Original prompt
Add Auto-Unquarantine Tests Agent and Workflow
Summary
Add a new Copilot agent and GitHub workflow to automatically unquarantine stable tests that have had zero failures in recent CI runs.
Files to Create
1.
.github/agents/auto-unquarantine-tests.mdCreate the agent description file with the following content:
2. Parse Issue Bodies for Quarantine Reports
For each issue, look for the quarantine report section in the issue body. The report format is:
Parsing rules:
(X/Y)where X is failures and Y is total runsMIN_RUNS_THRESHOLD(default: 90)Alternative "No failures" format:
If an OS shows
No failures ✅without a specific count, treat it as 0 failures but verify the run count from the summary table.3. Extract Test Method Names
From stable issues, extract the fully-qualified test method name from:
Common title patterns:
Failing test: Namespace.Class.MethodFlaky test: Namespace.Class.Method[Failing test]: MethodIf only the method name is available, search for the fully-qualified name:
Then examine the file to get the full namespace and class name.
4. Unquarantine Tests Using QuarantineTools
For each stable test, run QuarantineTools to remove the
[QuarantinedTest]attribute:Process all tests before building:
5. Build and Verify
After all QuarantineTools invocations, build the affected test projects:
If build fails:
6. Create Commit and Pull Request
Commit message format:
PR Title:
PR Description: