anchors test
Run the test suites declared in anchors.yaml and ingest the reports.
Runs what the PROJECT declared in `tests:` and ingests what the run left behind.
anchors test every declared layer: only its files STALE and below the minimum, and the never measured (each suite's run_changed: receives them) anchors test --all every file, through run: — the whole run anchors test --include-fresh also the fresh files below the minimum anchors test --include-passing also the stale files at the minimum or above anchors test --budget 60s fastest first, until the time is spent anchors test unit unit only anchors test unit integration more than one, in the file's order anchors test -w backend filters by workspace (monorepo) anchors test --changed a.ts INCREMENTAL: only the impact path of what changed anchors test --then check on passing, charges the gates with the signal still fresh
Two modes, the same as check's: FULL (without --changed) runs the "run:"; INCREMENTALruns the "run_changed:", which receives in {{files}} the files of the impact path -the SAME cut that "check --changed" uses, so the two do not disagree about whatyour commit moves.
Anchors does not know how to run a test — the stack is the project's. It executes the declared `run:`and binds the `junit:`/`lcov:` to the map, which is the step that usually gets forgotten.anchors test [layers...] [flags]| Flag | Padrão | O que faz |
|---|---|---|
--all |
run every file of the suites through run:, whatever their state — the whole run, as before the state selection |
|
--budget |
0s |
run the files FASTEST FIRST, in batches through run_changed:, until this much time is spent (e.g. 60s, 10m); the rest is left for a later run. The order comes from the times recorded by earlier runs; files never timed go last |
--changed |
INCREMENTAL mode: changed file(s) — runs the run_changed: over the union of the impact paths, the same slice as check --changed |
|
--include-fresh |
also run files measured at the current version that are below the minimum (by default only STALE files below the minimum run) | |
--include-passing |
also run stale files at the minimum or above (by default only files BELOW the minimum run); with –include-fresh, fresh passing files too | |
--root |
. |
project root |
--scope |
filters by the declared SCOPE (isolated, full) — only on mutation. Without this, runs whichever are declared |
|
--skip-unmeasured |
leave out the files never measured (by default they run) | |
--target |
target that replaces {{target}} in the declared run: (e.g. the file to mutate) |
|
--then |
on PASSING, chains Anchors commands: check, coverage (separate by comma). Opt-in — without this, it runs and stops |
|
-w, --workspace |
filters by the declared WORKSPACE (backend, mobile…) — repeatable or comma-separated. Combines with the layers: anchors test unit -w backend |
O mapa e seus sinais — família
Seção intitulada “O mapa e seus sinais — família”Comandos da mesma família — o que distingue cada um:
| Comando | O que faz |
|---|---|
anchors map |
Operate the dependency map (anchors.graph.yaml) |
anchors ingest |
Ingest test signals (JUnit/lcov) the project generated and bind them to the map |
anchors test |
Run the test suites declared in anchors.yaml and ingest the reports |
anchors mutation |
Run the mutation suites declared in anchors.yaml and ingest the reports |
anchors keep-evidence |
Declare that a change proves nothing new, keeping the files’ evidence fresh |
anchors stamp |
Write the missing @contract stamps on test doubles (never rewrites an existing one) |
anchors recode |
Rename an identity code and propagate it across the project |
anchors renumber |
Renumber the revisions this branch added when the base already took their number |
anchors generated-paths |
The paths of DERIVED files — whoever conflicts in them rebuilds |
anchors merge-progress |
Progress merge driver: unites both sides, [x] beats [ ] |