Next-generation test runner for Rust with parallel execution, advanced filtering, and CI integration. Use when running tests, configuring test execution, setting up CI pipelines, or optimizing test performance. Trigger terms: nextest, test runner, parallel tests, test filtering, test performance, flaky tests, CI testing.
View on GitHublaurigates/claude-plugins
rust-plugin
January 24, 2026
Select agents to install to:
npx add-skill https://github.com/laurigates/claude-plugins/blob/main/rust-plugin/skills/cargo-nextest/SKILL.md -a claude-code --skill cargo-nextestInstallation paths:
.claude/skills/cargo-nextest/# cargo-nextest - Next-Generation Test Runner
cargo-nextest is a faster, more reliable test runner for Rust that executes each test in its own process for better isolation and parallel performance.
## Installation
```bash
# Install cargo-nextest
cargo install cargo-nextest --locked
# Verify installation
cargo nextest --version
```
## Basic Usage
```bash
# Run all tests with nextest
cargo nextest run
# Run specific test
cargo nextest run test_name
# Run tests in specific package
cargo nextest run -p package_name
# Run with verbose output
cargo nextest run --verbose
# Run ignored tests
cargo nextest run -- --ignored
# Run all tests including ignored
cargo nextest run -- --include-ignored
```
## Configuration File
Create `.config/nextest.toml` in your project root:
```toml
[profile.default]
# Number of retries for flaky tests
retries = 0
# Test threads (default: number of logical CPUs)
test-threads = 8
# Fail fast - stop on first failure
fail-fast = false
# Show output for passing tests
success-output = "never" # never, immediate, final, immediate-final
# Show output for failing tests
failure-output = "immediate" # never, immediate, final, immediate-final
[profile.ci]
# CI-specific configuration
retries = 2
fail-fast = true
success-output = "never"
failure-output = "immediate-final"
# Slow test timeout
slow-timeout = { period = "60s", terminate-after = 2 }
[profile.ci.junit]
# JUnit XML output for CI
path = "target/nextest/ci/junit.xml"
```
## Test Filtering with Expression Language
```bash
# Run tests matching pattern
cargo nextest run -E 'test(auth)'
# Run tests in specific binary
cargo nextest run -E 'binary(my_app)'
# Run tests in specific package
cargo nextest run -E 'package(my_crate)'
# Complex expressions with operators
cargo nextest run -E 'test(auth) and not test(slow)'
# Run all integration tests
cargo nextest run -E 'kind(test)'
# Run only unit tests in library
cargo nextest run -E 'kind(lib) and test(/)'
```
### Expression Op