Skip to main content

Static import analysis for thrifty testing.

Project description

pytest-dirty

Static import analysis for thrifty testing.

Overview

With pytest>=8.2 and git, one can easily find what Python files have been changed and what test files to run.

# 1. List files changed in a pull request.
git diff --name-only main..<pr-branch> > changed.txt
# 2. Run `pytest-dirty` to know what chaned files of package `<package>` affect
tests in `tests` directory must be run.
pytest-dirty -s <package> -t tests changed.txt > affected.txt
# 3. Run tests with pytest.
pytest -s -vv @affected.txt

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest_dirty-0.0.0.tar.gz (10.2 kB view hashes)

Uploaded Source

Built Distribution

pytest_dirty-0.0.0-py3-none-any.whl (9.8 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page