--- id: pytest-json-ctrf version: "0.5.3" license: unclear license_treatment: permissive maintenance: active --- # pytest-json-ctrf — Pytest plugin to generate json report in CTRF (Common Test Report Format) License: permissive · Maintenance: active · Popularity: top 1,000 on PyPI ## Install pip install pytest-json-ctrf uv add pytest-json-ctrf poetry add pytest-json-ctrf ## Description # CTRF for pytest Pytest implementation of Common Test Report Format (CTRF) for test results. Test report will be generated in JSON format. Test report can be used to prettify the report in GitHub Actions with [github-actions-ctrf](https://github.com/ctrf-io/github-actions-ctrf). Do not worry if report in GitHub does not appear immediately. It takes some time to process the report. ## Features - Generates JSON report - Tested to work correctly with and without [pytest-xdist](https://pypi.org/project/pytest-xdist/) - Tested to get browser name from [pytest-playwright](https://pypi.org/project/pytest-playwright/) - Parametrized tests are supported and reported as 1 test with multiple retries ## Installation ```bash pip install pytest-json-ctrf ``` ## Usage generate report.json file in the root directory of the project. File path is mandatory ```bash pytest --ctrf report.json ``` Environment Variables may be used to specify the required Environment Object fields when using the CTRF [slack-test-reporter][ctrf-slack-test-reporter-url]. ```bash CTRF_BUILD_NAME="Pytest JSON CTRF Report" CTRF_BUILD_NUMBER="000" CTRF_BUILD_URL="https://ctrf.io]" ``` ## JSON example More... ## AI interpretation — verify before relying A pytest plugin that generates test reports in Common Test Report Format (CTRF) as JSON, compatible with pytest-xdist for parallel testing and pytest-playwright for browser detection. Verdict: A lightweight, actively maintained pytest plugin for standardized test reporting. No known vulnerabilities, permissive MIT license, and low install friction make it suitable for CI/CD pipelines seeking CTRF-compliant JSON reports. [View on SkillFed](https://skillfed.io/packages/pytest-json-ctrf) · [View on PyPI](https://pypi.org/project/pytest-json-ctrf/)