pytest-pspec
A rspec format reporter for Python ptest
What it is and what it does
pytest-pspec is a pytest plugin that changes how test results are displayed in the terminal. Instead of the default pytest output, it renders tests in RSpec-style format—a BDD-oriented report that reads like plain English specifications. Each test appears as a bullet point with a checkmark or cross, and the description comes from your test method's docstring, making the output more narrative and business-friendly.
The plugin is lightweight, requiring only pytest and six as dependencies. You enable it by passing the `--pspec` flag to pytest or adding it to your pytest configuration file. It supports both plaintext and UTF-8 output formats, and works with unittest-style test classes. The aging maintenance status means it has not been actively developed since 2020, so compatibility with very recent pytest releases may be uncertain.
Use it for:
- Generate human-readable test reports for stakeholders or documentation that read like specifications rather than technical output.
- Write BDD-style tests in Python where test names and docstrings describe behavior in plain language, then display them in that same readable format.
- Replace pytest's default output format in CI/CD pipelines to produce cleaner, more narrative test summaries.
- Document test coverage and behavior through the test output itself, using docstrings as living specification.
Worth the install?
AI-flagged interpretation of the facts on this page — verify before relying
Formats pytest test output in RSpec-style (pspec) format, showing test descriptions and results in a human-readable BDD-like report.
Yes, if you want readable BDD-style test output and are working with pytest versions compatible with the 2020-06-02 release. The low install friction and permissive license make it a low-risk addition. However, be cautious if you rely on very recent pytest features or versions—the aging maintenance status means you may need to maintain a fork or switch reporters if incompatibilities arise.
Install
pytest-pspec on PyPI
pip
pip install pytest-pspecuv
uv add pytest-pspecpoetry
poetry add pytest-pspecInstalling pytest-pspec
Before you install
Low install friction; depends only on pytest and six. Maintenance is aging—last release was 2020-06-02 and no commits since 2026-01-29, so expect limited active support for newer pytest versions.
License in practice
MIT license (permissive); you can use, modify, and distribute freely with minimal restrictions.
Quickstart
pip install pytest-pspec
# In your test file:
class TestExample(unittest.TestCase):
"My test suite"
def test_should_work(self):
"it does something"
assert True
# Run with:
pytest --pspec your-tests/
Requires pytest to be installed; docstrings on test classes and methods are used to generate the pspec output, so tests without docstrings will show generic names.
Verify before relying
- Compatibility with pytest versions released after 2020-06-02 is unclear given the aging maintenance status.
- Whether the package works correctly with modern Python versions beyond those listed in classifiers (3.5 and earlier).
Package facts
| License | not declared (permissive) |
| Python support | not specified |
| Install friction | low — pure-Python wheel |
| Runtime dependencies | 2 — pytest, six |
| Maintenance | aging — 2,264 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 81,243/month — #14,241 on PyPI (30-day window, as of 2026-08-14) |
| Known vulnerabilities | none known (OSV.dev, checked 2026-08-14) |
Evidence: pytest_pspec-0.0.4-py2.py3-none-any.whl
Keywords: pytest, pspec, test, report, bdd, rspec
Tags
More Testing packages
Pluggy provides a plugin system that lets you…
permissive · top 100 on PyPI
pytestpytest is a testing framework that lets you…
permissive · top 100 on PyPI
virtualenvvirtualenv creates isolated Python environments…
permissive · top 100 on PyPI
coverageCoverage.py measures which lines of Python code…
permissive · top 1,000 on PyPI
pytest-asynciopytest-asyncio is a pytest plugin that enables…
permissive · top 1,000 on PyPI
pytest-json-ctrfA pytest plugin that generates test reports in…
permissive · top 1,000 on PyPI
pytest-custom-reportA pytest plugin that lets you customize the…
permissive · top 15,000 on PyPI
pytest-html-reporterGenerates static HTML test reports from pytest…
permissive · top 15,000 on PyPI
pytest-specpytest-spec is a pytest plugin that reformats…
copyleft · top 15,000 on PyPI
tdd-guard-pytestA pytest plugin that captures test results and…
permissive · top 15,000 on PyPI
pytest-pytestrailA pytest plugin that decorates test functions…
permissive · top 15,000 on PyPI
pytest-pep8A pytest plugin that integrates PEP8 style…
permissive · top 15,000 on PyPI
pytest-nunitA pytest plugin that generates NUnit3-format…
permissive · top 15,000 on PyPI
pytest-runnerEnables running pytest tests through setup.py…
permissive · top 1,000 on PyPI
allure-pytest-bddIntegrates Allure Report with Pytest-BDD to…
permissive · top 15,000 on PyPI
pytest-md-reportA pytest plugin that generates test outcome…
permissive · top 15,000 on PyPI