How to run the repo's own tests and how they work. Adding a requirement and its test is in Writing tests; how to run the TCK against an agent is in the top-level README.
The repo holds three uv projects, each with its own pytest suite:
- Product (
tests/, the root project): unit tests for the harness, report model and plugin, the registry meta-tests, and end-to-end CLI tests that runacp-tckagainst every fixture agent for both versions. Run it for any change undersrc/,tests/, or the rootpyproject.toml. - spec-tracker (
spec-tracker/tests): checks the spec maps against the spec docs. Run it when you touchspec-tracker/, a requirement's citation, or a spec update. Commands, including--spec-repo, are inspec-tracker/README.md. - cross-check (
cross-check/tests): tests the cross-check tooling (not the upstream agents). Run it when you touchcross-check/. Commands are incross-check/README.md.
The product suite:
uv run pytest
The root pyproject.toml sets addopts = ["-n", "auto"] (pytest-xdist, a dev dependency), so uv run pytest
spreads the end-to-end CLI tests, which mostly wait on agent subprocesses, across cores. Pass -n 0 for a
serial run, which you want when debugging with pdb or reading interleaved output.
The addopts apply only to the repo's own tests. The TCK's own conformance runs (acp-tck, and plain pytest on
src/tck/v{1,2}/conformance) never inherit them, or any other outer pytest config. acp-tck passes the
conformance pytest.ini explicitly with -c; do the same for plain pytest (see
Development). Relying on pytest's config discovery is not enough:
it resolves the config before the plugin registers its --tck-* options, so option values that are existing paths
(an agent command that is a single file, --tck-agent-cwd) count as path arguments, and a path inside the repo (or,
in an installed copy, inside the project around the virtual environment) pulls in that project's config. The
pytest.ini files also stop the upward walk as a second line of defense.
tests/common/test_cli_isolation.py pins this. The PYTEST_ADDOPTS environment variable still applies, but
acp-tck blocks xdist (-p no:xdist) because its report needs a single process, so -n in PYTEST_ADDOPTS makes
it fail with a usage error instead of reporting nothing.
uv run pytest tests --ignore tests/v1/cli --ignore tests/v2/cli
uv run pytest tests/v1/cli/session_replay tests/v2/cli/session_replay
uv run pytest tests/v1/cli -k conforming
- The first runs only the unit and registry tests, skipping the end-to-end CLI tests under
tests/v{1,2}/cli/. - The second runs one domain of the CLI tests in both versions (layout).
- The third runs the CLI tests whose name matches
-k, usually a fixture agent's name.
Some CLI tests scope the inner acp-tck run with its own -k to the modules that own the ids they assert on. A
scoped run leaves every unselected MANDATORY row NOT TESTED, so it prints NOT CONFORMANT; that is expected, and
the tests assert on the per-id statuses, not the verdict (see Writing tests).
- The registry tests (
tests/v{1,2}/test_registry.py) fail if a registered id has no test, if a test references an unregistered id, or if the pinned id set or per-tier id sets were not updated by hand. - The CLI tests under
tests/v{1,2}/cli/run each fixture agent throughacp-tckand assert its exact FAIL set; their hand-written tier sets (_expectations.py) must match the registry too.
Writing tests covers how to add the fixtures and assertions these check.
.github/workflows/ci.yml runs two independent parts side by side:
test(required): passes only when all of the jobs below passed.unit: the product suite without the CLI tests (--ignore tests/v1/cli --ignore tests/v2/cli).cli <domain>: one job per CLI test domain, runningtests/v1/cli/<domain>andtests/v2/cli/<domain>(parallel via addopts). Alist CLI test domainsjob reads the domains from the directories and fails if the two versions differ. On one runner the CLI tests no longer fit the 30-minute job limit.spec-tracker: the spec-tracker tests against a fetched spec checkout.
- The cross-check (informational,
continue-on-error: true): onecross-check <agent>job per upstream agent, each running the TCK against it on its own runner, then across-checkjob that runs the cross-check tests and checks the four reports against the expected baseline.
The workflow's token is read-only. Non-GitHub actions are pinned to commit SHAs, with the version in a
comment. Dependabot (.github/dependabot.yml) opens one weekly PR to bump them.
Each project's README says what its CI step checks.