Skip to content

fix(impact): let declared inputs and alwaysRunTests select pytest and Maven tests - #272

Merged
adityankale190895 merged 2 commits into
DiffCI:mainfrom
FredApps:fix/declared-inputs-adapter-tests
Nov 18, 2026
Merged

adityankale190895 merged 2 commits into
DiffCI:mainfrom
FredApps:fix/declared-inputs-adapter-tests

Conversation

@FredApps

Copy link
Copy Markdown
Contributor

Fixes #271

knownTestPaths now considers every graph node that is a test file (isTestFile) or matches a profile test glob, instead of only nodes inside profile.tests. Declared inputs and alwaysRunTests then see pytest and Maven tests. A declaration that matches no test still falls back. collectRouteVisitTests uses the same list and can only gain tests.

Validation:

  • tests/repo/declared-inputs-adapter-tests.test.ts: pytest and Maven declared inputs and pytest alwaysRunTests fail on main and pass here. The stale-declaration fallback case passes on both.
  • npm run typecheck, npm test (1171 pass), npm run build, npm run audit:boundary.

… Maven tests

knownTestPaths only checked graph nodes while iterating profile.tests, the JavaScript test locations. pytest and Maven repositories have none, so the known-test list was empty. Every declared input then failed with "Declared input ... selects no tests; full validation required", and alwaysRunTests globs silently selected nothing. Every graph node the test-file matcher accepts is now a known test, whether or not the profile lists JavaScript test locations. A declaration that matches no test still falls back.

Signed-off-by: FredApps <[email protected]>

@FredApps FredApps left a comment

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Cross-review of 280e017.

Checked:

  • The fix matches #271. knownTestPaths no longer depends on profile.tests being non-empty. It checks every graph node with isTestFile or a test-location glob, which is the same set as before whenever profile.tests is non-empty. So declared inputs and alwaysRunTests now find pytest and Maven tests, and the cost is the same nodes × locations.
  • The new test fails with src/ reverted (3 of 4 fail) and passes with the fix. tests/repo/declared-inputs-adapter-tests.test.ts is listed in release-files.json. The commit is DCO-signed. The branch is level with main. CI is green.

Fixed: nothing.

Still open: none.

…ffCI#270

The manifest is an unordered set, and the PRs listed above add their entries at the same line. Moving this entry one line away lets them merge in either order without a conflict.

Signed-off-by: FredApps <[email protected]>
@FredApps
FredApps marked this pull request as ready for review November 18, 2026 01:07
@adityankale190895
adityankale190895 merged commit 30c9fcb into DiffCI:main Nov 18, 2026
13 checks passed
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.

Declared inputs and alwaysRunTests find no pytest or Maven tests

2 participants