Skip to main content

pytest-diff-selector

Quickstart

pip install pytest-diff-selector

cd [git-project-you-want-scanning]
selector HEAD^  # scan last commit
tests/test_something.py::test_01

selector HEAD   # scan unstaged/uncommited work
tests/test_something.py::test_01

asciicast

Why

When having a long integration tests you want your CI extra smarter and don't waste time on irrelevant tests

How

Figuring out which tests are affect by specific code changes It's scanning all the project python files and build a call graph using AST, and scans this graph to find paths that are part to the change (by line numbers from the diff) that leads to a test

Currently it's only a commandline tool, but it should become a full fledged pytest plugin

Release files for pytest-diff-selector 0.1.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pytest-diff-selector 0.1.3
File Size Uploaded
pytest-diff-selector-0.1.3.tar.gz 8.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pytest-diff-selector 0.1.3
File Interpreter ABI Platform
pytest_diff_selector-0.1.3-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 14.3 kB

Release files / pytest-diff-selector-0.1.3.tar.gz

Download URL pytest-diff-selector-0.1.3.tar.gz
Size 8.4 kB
Tags Source
SHA-256 checksum
How to use checksums
6bf25dd845c9cee07ff8329341d5115f27c5d0ce4d3a9b5cd341feb2713a12ee
BLAKE2b-256 checksum
How to use checksums
d30557d86ed52dac1f58ab504da7c4860a2b63674fc557591a9c6a82a347a396
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.1

Release files / pytest_diff_selector-0.1.3-py2.py3-none-any.whl

Download URL pytest_diff_selector-0.1.3-py2.py3-none-any.whl
Size 5.9 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
6d3807737106c060796fe7d2bfd9b1832f9e8871444043c7e3895bed9416cb66
BLAKE2b-256 checksum
How to use checksums
337a3178c43da5845c38914c6dbc114c1dbbf3b825138680445c1b19af81d627
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.8.0 pkginfo/1.8.2 readme-renderer/32.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.8 tqdm/4.62.3 importlib-metadata/4.11.1 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.10.1

Release history Release notifications | RSS feed

This release

0.1.3 This release

2 release files

0.1.2

2 release files

0.1.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page