Add Custom pytest Marker to Ease Development (#2628)

Co-authored-by: Bibo-Joshi <22366557+Bibo-Joshi@users.noreply.github.com>
This commit is contained in:
Poolitzer 2021-08-12 08:51:42 +02:00 committed by Hinrich Mahler
parent 8a7aeaf86f
commit babcc2a448
2 changed files with 3 additions and 0 deletions

View file

@ -85,6 +85,8 @@ Here's how to make a one-off code change.
- Please ensure that the code you write is well-tested. - Please ensure that the code you write is well-tested.
- In addition to that, we provide the `dev` marker for pytest. If you write one or multiple tests and want to run only those, you can decorate them via `@pytest.mark.dev` and then run it with minimal overhead with `pytest ./path/to/test_file.py -m dev`.
- Dont break backward compatibility. - Dont break backward compatibility.
- Add yourself to the AUTHORS.rst_ file in an alphabetical fashion. - Add yourself to the AUTHORS.rst_ file in an alphabetical fashion.

View file

@ -30,6 +30,7 @@ filterwarnings =
; Unfortunately due to https://github.com/pytest-dev/pytest/issues/8343 we can't have this here ; Unfortunately due to https://github.com/pytest-dev/pytest/issues/8343 we can't have this here
; and instead do a trick directly in tests/conftest.py ; and instead do a trick directly in tests/conftest.py
; ignore::telegram.utils.deprecate.TelegramDeprecationWarning ; ignore::telegram.utils.deprecate.TelegramDeprecationWarning
markers = dev: If you want to test a specific test, use this
[coverage:run] [coverage:run]
branch = True branch = True