CI test selection

Run the tests that matter on every build.

One read-only API call and one pipeline step. Your pull-request builds run the High-priority automated tests from the current release plan, and fall back to the full suite the moment anything looks off.

# Pull requests: run Revicto's selection. Keep a nightly job that runs the full suite.
- name: Tests (Revicto selection)
  env:
    REVICTO_API_KEY: ${{ secrets.REVICTO_API_KEY }}
    RUN_SELECTED_TESTS: "xargs -a revicto-tests.txt -d '\n' pytest --junitxml=test-results/junit.xml"
    RUN_FULL_SUITE: "pytest --junitxml=test-results/junit.xml"
    REVICTO_JUNIT_REPORT: test-results/junit.xml
  run: |
    # Revicto test selection (fails open: anything unexpected runs the full suite).
    # Abridged: copy the complete step from Use in CI on any plan.
    status=$( curl -sS -o revicto-selection.json -w '%{http_code}' --max-time 10 \
      -H "Authorization: Bearer $REVICTO_API_KEY" "https://app.revicto.com/api/v1/ci/selection?plan=latest&tiers=high" ) \
      || run_full_suite "Revicto could not be reached."
    if [ "$( jq -r '.fallback.recommended' revicto-selection.json )" != "false" ]; then
      run_full_suite "$( jq -r '.fallback.message' revicto-selection.json )"
    fi
    jq -r '.tests[] | select(.automated_test != null) | .automated_test.name' \
      revicto-selection.json > revicto-tests.txt
    bash -c "$RUN_SELECTED_TESTS"   # then checks the JUnit report ran what was selected
build log
▸ Tests (Revicto selection)Revicto: running 58 selected tests from "Release-24.7".collected 58 items58 passed in 3m 12s ▸ Tests (Revicto selection) · nightly, plan 34 days oldRevicto: running the full suite. The latest plan is 34 days old; generate a plan for this release.collected 1,284 items
1
read-only API call
1
pipeline step
10s
timeout, then the full suite

Setup

Ten minutes to your first selected build.

No agents, no code instrumentation, no CLI to install. The step is plain bash with curl and jq, which GitHub-hosted and Microsoft-hosted Linux agents already have.

  1. 01

    Create a workspace API key

    In Settings → CI integration. Pick an expiry: never, 30, 90 or 365 days. The key is shown once, stored only as a keyed hash, and can be revoked anytime.

  2. 02

    Link tests to automation

    Azure DevOps “associated automation” is read for you. Anything else links in a click from the plan, and your team's link always wins.

  3. 03

    Paste one step

    Copy the step for GitHub Actions, Azure Pipelines or any CI with bash. Point RUN_SELECTED_TESTS at your runner: pytest, dotnet test, Jest, Maven and more.

Fail open, always

When in doubt, it runs everything.

A pipeline must never run zero tests because of Revicto. Each of these runs your full suite instead, and says why in the build log. Real failures in the selected run are your build's result; they're never hidden by a re-run.

  • No API key, no jq on the agent, or the step isn't fully configured → full suite
  • Revicto doesn't answer within 10 seconds, or the answer isn't readable → full suite
  • The plan is older than 30 days, or its production data was flagged low-confidence → full suite
  • None of the selected tests is linked to automation, or fewer than half are → full suite
  • The selection has no tests in the requested tiers, or more than 5,000 → full suite
  • The selected run wrote no JUnit report, or executed fewer than half the selected tests → full suite

No full-suite command configured? The step stops with a clear message rather than guess.

Guarantees

An advisor in your pipeline, never a gatekeeper.

Revicto never fails a build on its own, never approves a release, and never decides by itself what your pipeline does. The pipeline asks; Revicto answers.

Read-only, by construction

The selection API can't change a plan, an override, a result or a setting. It answers one question: which tests matter now.

Minimum data out

Test IDs, names, priorities and automation links. Never production usage, reasoning, bugs or customer data.

The plan your team approved

The selection is the plan's effective priorities, overrides included and flagged. No separate CI scoring, no surprises.

Deterministic

Same plan, same list, same order: High first, then by test case ID. Over 5,000 tests, the answer says so instead of truncating.

Keys built like infrastructure

Hashed at rest, shown once, expiring, revocable, up to 10 active per workspace, rate limited, and every create and revoke is in the audit log.

Defer isn't “never”

Keep a nightly or pre-release run of the full suite. Revicto makes pull requests fast; it doesn't make deferred tests disappear.

Know the risk.Govern every release.

  • 30-day free trial, no credit card
  • Read-only access
  • First plan in under a minute