pytest-mark-no-py3
This package provides a pytest plugin and a Bowler codemod to help migrate tests to Python 3.
Any tests marked with @pytest.mark.no_py3 will be expected to fail when
running on Python 3 and will fail the test if they pass unexpectedly.
Usage
Adding @pytest.mark.no_py3
-
Install this package in your test dependencies.
-
Run your tests on Python 3, savings the results with pytest's
--result-logoption, e.g.:tox -e py37 -- --result-log=test-results.txt
-
Install this package with the
bowlerextras in a Python 3 virtualenv:pip install pytest_mark_no_py3[bowler]
-
Apply the marker to all of the tests that failed on Python 3, running from the same directory that you ran the tests from:
python -m pytest_mark_no_py3.add --result-log=path/to/result-log.txt path/to/your/tests
If you're feeling confident, you can also use the
--no-interactiveoption to apply the codemod without prompting to accept changes.
Removing @pytest.mark.no_py3
-
Fix some code so that tests start passing on Python 3, violating the xfail.
-
Run your tests on Python 3, savings the results with pytest's
--result-logoption, e.g.:tox -e py37 -- --result-log=test-results.txt
Warning: The only failing tests should be the tests that you fixed and want the marker removed from!
-
Install this package with the
bowlerextras in a Python 3 virtualenv:pip install pytest_mark_no_py3[bowler]
-
Remove the marker from all of the tests that "failed" (i.e. were expected to fail but actually passed) on Python 3, running from the same directory that you ran the tests from:
python -m pytest_mark_no_py3.remove --result-log=path/to/result-log.txt path/to/your/tests
If you're feeling confident, you can also use the
--no-interactiveoption to apply the codemod without prompting to accept changes.
Running tests
Run tox.
Metadata
Release files for pytest-mark-no-py3 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pytest-mark-no-py3-0.1.0.tar.gz | 6.3 kB | Without provenance | Details for pytest-mark-no-py3-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pytest_mark_no_py3-0.1.0-py2.py3-none-any.whl | Python 2, Python 3 | none | any | Details for pytest_mark_no_py3-0.1.0-py2.py3-none-any.whl |
Total release size: 12.7 kB
Release files / pytest-mark-no-py3-0.1.0.tar.gz
| Download URL | pytest-mark-no-py3-0.1.0.tar.gz |
|---|---|
| Size | 6.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f32931c2316f5b8a1eda33c54f31e824da01ff3f733c3010e2b5e9190412402d
|
|
BLAKE2b-256 checksum How to use checksums |
c714a48c0a66ddd4abe441a0cd8f4768da21c3e309a5a2782b74873c33836580
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3
|
Release files / pytest_mark_no_py3-0.1.0-py2.py3-none-any.whl
| Download URL | pytest_mark_no_py3-0.1.0-py2.py3-none-any.whl |
|---|---|
| Size | 6.4 kB |
| Tags | Python 2 Python 3 |
|
SHA-256 checksum How to use checksums |
fd0a68bc478f04f99d9080d4459439389f11809f6f6a472647d161443b57e2fd
|
|
BLAKE2b-256 checksum How to use checksums |
016ce44dd96db1d45c7b6511b0a097d707259798df536bae223c842a54545644
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.3
|
Security for pytest-mark-no-py3 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.