Skip to main content

Plugin for py.test to run relevant tests, based on naively checking if a test contains a reference to the symbol you supply

Project description

Plugin for pytest to run relevant tests by naively check if test functions contain a reference to the symbol supplied.

Limitations:
  • it only looks for top level test functions, so test classes won’t be discovered

  • very naive check, so indirect usages of a symbol won’t be found

This trade off has been made for speed. This method is extremely fast compared to the other common method which tries to be correct by running the full test suite under coverage and checking if the function was called directly or indirectly.

Installation

pip install pytest-test-this

Usage

pytest –test-this=foo

…where foo is the name of your function, class or variable.

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-test-this-0.2.0.tar.gz (3.9 kB view details)

Uploaded Source

Built Distribution

pytest_test_this-0.2.0-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file pytest-test-this-0.2.0.tar.gz.

File metadata

  • Download URL: pytest-test-this-0.2.0.tar.gz
  • Upload date:
  • Size: 3.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

File hashes

Hashes for pytest-test-this-0.2.0.tar.gz
Algorithm Hash digest
SHA256 68b01a43c0ff57164ebbc31303cf2815dc558e560d764a1da70a5a6c22d2a893
MD5 7d803af506d556e9515136651293b523
BLAKE2b-256 4f66076a619657e9a1e4ef495b0947aee590d3fb20d30ad64e7d0efbb058c526

See more details on using hashes here.

File details

Details for the file pytest_test_this-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: pytest_test_this-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 4.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.14.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.2.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.3

File hashes

Hashes for pytest_test_this-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 47b2fe26891ccaa513b363329d543aed3fa56ee3ddbd64d69178aafe1da81579
MD5 8b30860a3d87ebe2b35b46c820ab40c2
BLAKE2b-256 49c0d65c9050ebbe45b9e527df56172ac18c6f428d01d5c8ad60395e46f3321e

See more details on using hashes here.

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