--- id: rtest version: "0.0.46" license: MIT license_treatment: permissive maintenance: active --- # rtest — Python test runner built in Rust License: permissive · Maintenance: active · Downloads: 263.4K/mo ## What it is and what it does rtest is a test runner that replaces pytest's import-heavy test collection with Rust-based static AST analysis, eliminating the need to import test modules to discover tests. This yields significant speedups: 5–25x on smaller projects, and 100–200x+ on large monorepos where import overhead dominates. It offers three execution modes: fast collection-only analysis, a native runner for simple test patterns, and pytest-compatible execution that preserves pytest's fixture and conftest.py support while benefiting from rtest's faster collection. The package is in active early development (v0.0.x) and supports Python 3.10 and later. It ships as compiled wheels across multiple platforms and Python versions. The native runner accepts @rtest.mark.cases and @rtest.mark.skip decorators, plus @pytest.mark.parametrize and @pytest.mark.skip for compatibility. Known limitations include incomplete fixtures support, inability to statically resolve truly dynamic parametrize expressions, and platform-specific path separator handling in test node IDs. Use it for: - Speed up test collection on large monorepos where import overhead is the bottleneck - Run tests in parallel with the native runner on projects using simple test patterns without fixtures - Replace pytest for projects that don't rely on fixtures or conftest.py - Accelerate CI/CD pipelines by reducing test discovery time on medium to large codebases - Benchmark and profile test collection performance across different test suites ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A Python test runner built in Rust that uses static AST analysis for fast test collection and supports parallel test execution, with optional pytest compatibility. Yes, if you have a medium to large test suite and can tolerate early-stage tooling. The speedups are substantial and well-documented. Install with caution if your tests depend heavily on pytest fixtures or conftest.py—the native runner doesn't support these yet, though pytest-compatible execution mode does. Not recommended for small projects where collection time is negligible, or for teams requiring production-grade stability. ## Install pip install rtest uv add rtest poetry add rtest ## Installing rtest Before you install: Medium install friction due to compiled wheels for multiple Python versions and platforms. Active maintenance with recent releases; project is in early development (v0.0.x) so expect breaking changes and evolving features. License in practice: MIT license is permissive; you can use, modify, and distribute this package freely with minimal restrictions. Quickstart: pip install rtest # Fast collection rtest --collect-only # Run with native runner rtest --runner native # Parallel execution rtest --runner native -n 4 Requires Python 3.10 or later. Native runner does not support pytest fixtures or conftest.py; use --runner pytest for fixture-dependent tests. Verify before relying: - Whether native runner fixtures support is complete or still in development - Compatibility with complex pytest plugins beyond basic parametrize/skip markers - Whether cross-module constant resolution for @rtest.mark.cases is fully implemented ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: medium - Maintenance: active - Downloads: 263.4K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags fast test runner python, pytest alternative, rust test collection, parallel test execution, ast-based test discovery, high-performance testing, pytest replacement, rust-compiled, performance-focused, early-stage [View on SkillFed](https://skillfed.io/packages/rtest) · [View on PyPI](https://pypi.org/project/rtest/)