virtual360-io/Selective Tests

Compute the Minitest tests affected by a diff using the selective_tests manifest committed at the project root. Outputs a newline-separated list of test files for the calling workflow to feed into its test runner.

View on GitHub

Trust Signals

Scorecard Score
not yet scored
Maintenance Recency
Stale
License
None
namedescriptionrequireddefault
base-refBranch to diff against. The action computes `git diff --name-only origin/<base-ref>...HEAD`.nodevelop
changed-filesOptional newline- or space-separated list of changed files. When set, the action skips the git diff and uses this list directly. Useful when the caller already has the diff (e.g. `tj-actions/changed-files`).no""
manifest-dirPath (relative to the repository root) to the manifest directory written by `TRACK_TEST_FILES=true bundle exec rails test`.no.selective_tests
bundler-cmdCommand used to invoke the CLI. Override when the gem is not installed via bundler (e.g. `selective-tests` if installed globally) or when the caller bundles with a non-default Gemfile.nobundle exec selective-tests
strictWhen `true`, the action fails if the diff contains any file not present in the manifest. When `false` (default), unknown files are reported on the job log but do not fail the step.nofalse
output-fileOptional path where the list of selected tests will be written, one per line. Useful for piping into a downstream `xargs` step.no""
namedescription
testsNewline-separated list of selected test files. Empty when no tests are affected, when the manifest is missing, or when the diff is empty.
test-countNumber of test files selected. `0` means no tests are affected and the caller may skip the test job entirely.
manifest-found`true` when `manifest-dir` contains either a consolidated `manifest.json` or at least one `run-*.ndjson`. `false` means the caller should fall back to running the full suite.
unknown-countNumber of files in the diff that are unknown to the manifest. They are conservatively skipped; bump this number is a signal that the manifest is stale.
diff-file-countNumber of files in the input diff (after git or `changed-files`).