ci: run only the integration suites a pull request can affect - #775
Open
Sarath1018 wants to merge 1 commit into
Open
Sarath1018 wants to merge 1 commit into
Sarath1018 wants to merge 1 commit into
Conversation
Sarath1018
force-pushed
the
ci/scope-integration-tests-to-changes
branch
from
September 24, 2026 10:13
1df05a8 to
2630b5f
Compare
Contributor
|
✅ No issues found. Checked for bugs and CLAUDE.md compliance. |
PR coverage runs used to execute every integration suite for every change, so a docs- or packages-only PR spent ~17 minutes per leg creating Data Fabric entities and Maestro instances it could not influence, and every platform hiccup in ~3,000 requests failed the PR. A new `scope` job classifies the files changed against the base branch (scripts/integration-scope.mjs). Suites are the folders under tests/integration/shared; a change under src/services/<name>, src/models/<name> or tests/integration/shared/<name> runs that suite, docs, samples, packages and unit tests run nothing, and anything else (core, utils, the harness, config, workflows, a domain with no suite folder) runs everything. The cross-cutting smoke, http and auth-errors suites run whenever any suite runs. The `integration` job receives the resulting vitest path filters and is skipped only when the resolver explicitly says nothing is affected; a missing output still runs. The `ci:full-integration` label forces a full run; weekly-coverage.yml keeps running everything. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Sarath1018
force-pushed
the
ci/scope-integration-tests-to-changes
branch
from
September 24, 2026 10:29
2630b5f to
4189c2b
Compare
Contributor
|
✅ No issues found. Checked for bugs and CLAUDE.md compliance. |
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.
Summary
This adds a
scopejob tocoverage.ymlthat decides which suites a PR needs from the files it changes (scripts/integration-scope.mjs, 127 lines, no dependencies). The rule is name-based: suites are the folders undertests/integration/shared/, and a domain's sources live under the same name insrc/services/andsrc/models/.src/services/<name>/**,src/models/<name>/**,tests/integration/shared/<name>/**(suite folder exists)tests/integration/shared/<name>docs/**,samples/**,packages/**,tests/unit/**,tests/utils/mocks/**, Markdown, lint/build configsrc/core,src/utils,src/services/base.ts,src/models/common, the test harness, config, workflows, a domain with no suite foldersmoke,httpandauth-errorsrun whenever any suite runs. Theintegrationjob is skipped only when the resolver explicitly reports nothing affected (run_integration=false); a missing output, a failed diff or an unrecognised path all run the full suite.sonarandsummaryhandle the skipped case;test-and-buildpasses because a skipped job does not fail the called workflow.Deliberately not modelled (kept simple on request): cross-domain source imports. Maestro's cases wrap the Action Center
TaskService, so anaction-center-only change runsaction-centerbut notmaestro;weekly-coverage.ymlstill runs everything againstmain. Adding a mapping later is a one-line table.Escape hatch: the
ci:full-integrationlabel forces a full run (labels are read from the event that started the run, so push a commit after labelling). Scheduled/manual runs (weekly-coverage.yml) are always full.Dry run against recent PRs
#720(coded-action-app docs/types) → nothing ·#709(sample) → nothing ·#745(maestro tests) → maestro only ·#736,#747,#734,#663(config / core / workflow changes) → everything.Notes
tests/unit/scripts/integration-scope.test.ts(behavioural cases + the suite-folder discovery).Test plan
npm run test:unit,npm run lintnode scripts/integration-scope.mjs --base origin/mainon this branch → full run (workflow + script changed)coverage / scopeon this PR resolvesscope=all; the integration legs run the full suite🤖 Generated with Claude Code