--- id: pytest-ruff version: "0.5" license: unclear license_treatment: unclear maintenance: aging --- # pytest-ruff — pytest plugin to check ruff requirements. License: unclear · Maintenance: aging · Downloads: 188.7K/mo ## What it is and what it does pytest-ruff is a pytest plugin that embeds ruff linting and formatting checks into your test pipeline. Instead of running ruff separately from your test suite, you invoke it via pytest flags (--ruff and --ruff-format) and the plugin executes one ruff validation per file, failing the test run if any file violates ruff rules or has formatting issues. The plugin respects standard ruff configuration files (pyproject.toml or ruff.toml) in your project, so you configure it the same way you would standalone ruff. It depends only on pytest and ruff, both common tools, and supports Python 3.8 through 3.13. The project is in beta status and has not been updated for 421 days, though the repository remains unarchived and has seen recent activity. Use it for: - Run ruff checks alongside unit tests in a single pytest invocation to catch style and formatting issues early. - Enforce code quality gates in CI/CD by failing the build if ruff detects violations, without a separate linting step. - Validate both code logic and formatting in one test command, reducing the number of separate tools developers need to invoke locally. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. A pytest plugin that integrates ruff code linting and formatting checks into your test suite, running ruff validation as part of pytest. Yes, if you want to consolidate ruff linting into your pytest workflow and accept the aging maintenance status. The plugin has low install friction, no known vulnerabilities, and works with current Python versions. However, verify that it remains compatible with your versions of pytest and ruff, and clarify the license metadata before using it in a compliance-sensitive context. ## Install pip install pytest-ruff uv add pytest-ruff poetry add pytest-ruff ## Installing pytest-ruff Before you install: Low install friction with only pytest and ruff as runtime dependencies. Maintenance status is aging—last release was 421 days ago, though the repository remains active with a recent commit on 2025-07-27. License in practice: License treatment is unclear in the metadata, though the description states distribution under MIT terms; verify the actual license file in the repository before relying on it for compliance. Quickstart: pip install pytest-ruff # In your test run: pytest --ruff --ruff-format # The plugin runs one ruff check per file and fails if code violates ruff rules. Requires pytest and ruff to be installed; ruff configuration can be customized via pyproject.toml or ruff.toml in your project directory. Verify before relying: - Whether the unclear license metadata reflects an actual licensing ambiguity or a metadata-only gap that the MIT statement in the description resolves. - Current test coverage and whether the aging maintenance status indicates the plugin remains compatible with recent ruff and pytest releases. ## Package facts - License: not declared (unclear) - Python support: supports_current - Install friction: low - Maintenance: aging - Downloads: 188.7K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags pytest ruff integration, ruff linting in pytest, code quality checks pytest, ruff format validation, pytest code style plugin, pytest-plugin, code-quality, linting [View on SkillFed](https://skillfed.io/packages/pytest-ruff) · [View on PyPI](https://pypi.org/project/pytest-ruff/)