| name | run-rust-tests |
| description | Run Rust tests for the affected OpenFirma crates or a specific crate/test. |
Run Rust Tests
Run Rust tests after making changes to verify correctness.
Arguments
- No arguments: determine affected crates and run their tests
all: run all Rust tests in the workspace
<crate>: run tests for one crate
<crate> <test>: run one test in one crate
Arguments provided: $ARGUMENTS
Instructions
No arguments
- Inspect the modified files using the repository's active VCS as described in
AGENTS.md.
git status --short
git diff --name-only
jj status
jj diff --name-only
- Identify changed workspace crates from paths under
crates/<name>/.
- Run nextest for those crates:
cargo nextest run -p <crate1> -p <crate2>
- Run doctests for the same crates when they may be affected:
cargo test --doc -p <crate1> -p <crate2>
- If no affected crates can be determined, run all Rust tests.
all
just test
One crate
cargo nextest run -p <crate-name>
cargo test --doc -p <crate-name>
One crate, one test
cargo nextest run -p <crate-name> <test-name>
If the target is a doctest-specific failure, use:
cargo test --doc -p <crate-name>
Notes
cargo nextest does not run doctests in this repo.
- Prefer targeted crate runs while iterating, then
just test or just check at the end.