Commit Graph

2980 Commits

Author SHA1 Message Date
Roberto Aldera 9fa82598a9
Use NamedTuple for pytest_report_teststatus return value (#10972)
Closes #10872

---------

Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
2023-05-19 08:24:28 -03:00
Erik Hasse a2feb6bd00 add a warning about modifying the root logger during tests 2023-05-18 09:26:16 -05:00
Ville Skyttä 6041511fb4
Spelling and grammar fixes (#11014) 2023-05-18 10:10:44 -03:00
Bruno Oliveira 1636322995
Reference "Status of Python Versions" in backwards-compatibility policy
As suggested in #10981.
2023-05-16 20:24:06 -03:00
github-actions[bot] 612489e2bd
[automated] Update plugin list (#11001)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-05-15 08:26:41 -03:00
Bruno Oliveira faeb16146b Consider testpaths for initial conftests
The 'testpaths' option is meant to be identical to execute
pytest passing the 'testpaths' directories explicitly.

Fix #10987
2023-05-12 09:34:15 -03:00
Bruno Oliveira b241c0b479 Fix defaults for tmp_path_retention_count and tmp_path_retention_policy in docs 2023-05-12 09:34:15 -03:00
leeyueh f84fea0888
Update usage.rst (#10974)
Added a note for single quotation used in Windows.
2023-05-10 22:28:52 -03:00
github-actions[bot] a88ae8289c
[automated] Update plugin list (#10968)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-05-09 19:05:13 -03:00
pytest bot be774667c2 [automated] Update plugin list 2023-04-30 00:23:40 +00:00
Sergey Kim 725de3a0d3
add flake8-pytest-style mention to goodpractices (#10939) 2023-04-28 23:47:47 +03:00
Florian Bruhin a15f544962
doc: Fix 2024 training location (#10947) 2023-04-26 08:13:06 +02:00
Bryan Ricker 158f41fdf8
Fix documentation typo (#10942) 2023-04-25 10:49:16 +02:00
pytest bot 15156757b6 [automated] Update plugin list 2023-04-23 00:21:26 +00:00
Florian Bruhin 0860f4e916
Add 2024 pytest training (#10933) 2023-04-22 21:22:25 +02:00
pytest bot 28783e5d23 [automated] Update plugin list 2023-04-16 00:21:39 +00:00
Bruno Oliveira ece756fcb4 Merge pull request #10913 from pytest-dev/release-7.3.1
Prepare release 7.3.1

(cherry picked from commit a1f7a204df45a4fd07d5d62128f61198e5dd7f23)
2023-04-14 15:15:28 -03:00
Ran Benita 90412827c3 Revert "Correctly handle tracebackhide for chained exceptions (#10772)"
This reverts commit 431ec6d34e.

Fix #10903.
Reopen #1904.
2023-04-12 19:23:25 +03:00
Bruno Oliveira 6dcd652d4a
Amend changelog note for removal of attrs (#10888)
As discussed in https://github.com/pytest-dev/pytest/pull/10669#issuecomment-1501497729, we should
make the reasoning behind this change more clear, as well as thank the attrs maintainers for the
many years of cooperation and support.

Co-authored-by: Pierre Sassoulas <pierre.sassoulas@gmail.com>
2023-04-10 13:04:02 -03:00
pytest bot 22951bba67 [automated] Update plugin list 2023-04-09 00:22:30 +00:00
Ran Benita bf47357511 Merge pull request #10881 from pytest-dev/release-7.3.0
Prepare release 7.3.0

(cherry picked from commit cec5bfe0588adaa2ca36c72c724378982db6410a)
2023-04-09 00:50:37 +03:00
github-actions[bot] 31d0b51039
[automated] Update plugin list (#10857)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-04-04 13:17:43 -03:00
Stefanie Molin f1c7585184
Update fixture scope in package/directory fixture example. 2023-03-31 10:00:45 -07:00
github-actions[bot] a3b39069bc
[automated] Update plugin list (#10838)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-03-26 08:32:13 -03:00
github-actions[bot] 172c832cbd
[automated] Update plugin list (#10823)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-03-24 11:41:07 -03:00
Ronny Pfannschmidt 54864f0c9b bugfix: fix imports for simple example 2023-03-17 21:58:26 +01:00
Ronny Pfannschmidt ba969d2ae7 run regendoc 2023-03-17 21:58:26 +01:00
github-actions[bot] 7af1e4e4ed
[automated] Update plugin list (#10810)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-03-12 13:04:50 -03:00
Stefanie Molin 0ae04ae629
Include `pyproject.toml` in help section that lists out config files with ini-options (#10807) 2023-03-11 10:59:02 -03:00
Florian Bruhin 723035be7f
doc: Remove done training (#10805) 2023-03-10 20:47:03 +00:00
Paul Kehrer a869141b3d
New option to allow a progress report even when capture=no (#10755) 2023-03-07 17:49:37 -03:00
Bruno Oliveira 5e98aefc92
Merge pull request #10794 from pytest-dev/update-plugin-list/patch-d5dda84ef
[automated] Update plugin list
2023-03-06 08:16:06 -03:00
bluthej 5a61ec3d4a Fix example in the documentation (#10782) 2023-03-05 17:01:21 +01:00
pytest bot 1d48b3021d [automated] Update plugin list 2023-03-05 00:25:29 +00:00
Bruno Oliveira 517e02e59e Merge pull request #10792 from pytest-dev/release-7.2.2
Prepare release 7.2.2

(cherry picked from commit 3ce6030f0cc0e6fb18cbee1a4a8b1cec8c6d0b0c)
2023-03-03 16:14:11 -03:00
Billy 88c9e92258
Minor updates to fixtures docs (#10724)
Updated the c fixture to be a little more consistent with other fixtures in the corresponding image. for example both e and g both have edges connected with the fixtures that they explicitly depend on.
2023-02-28 12:42:33 -03:00
github-actions[bot] 13ea4780b8
[automated] Update plugin list (#10752)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-02-27 08:55:33 -03:00
Manuel Jacob da626e7186
Update import mode documentation to not refer to __import__() anymore. (#10747)
Nowadays, the prepend and append import modes use importlib.import_module() instead of __import__().

There was a phrase “which avoids having to use `__import__`”, in which I couldn’t just replace `__import__` by `importlib.import_module` because the latter is used (in insert_missing_modules()) also when using importlib mode. Therefore I removed the part from the sentence.
2023-02-18 18:55:46 -03:00
bitzge 051f8f1f0f
Add CI and BUILD_NUMBER env var in docs (#10749) 2023-02-18 18:52:14 -03:00
Florian Bruhin 464f29901f
Update open training (#10739) 2023-02-15 14:06:24 +00:00
Garvit Shubham aa72496d24
Fix entry-points declaration in the documentation example using Hatch
Closes #10721
2023-02-14 10:57:32 -03:00
github-actions[bot] 9048621002
[automated] Update plugin list (#10726)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-02-12 21:39:45 -03:00
pre-commit-ci[bot] 59e7d2bbc9
[pre-commit.ci] pre-commit autoupdate (#10712)
* [pre-commit.ci] pre-commit autoupdate

updates:
- [github.com/psf/black: 22.12.0 → 23.1.0](https://github.com/psf/black/compare/22.12.0...23.1.0)
- [github.com/PyCQA/autoflake: v2.0.0 → v2.0.1](https://github.com/PyCQA/autoflake/compare/v2.0.0...v2.0.1)

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

* Update .pre-commit-config.yaml

* [pre-commit.ci] auto fixes from pre-commit.com hooks

for more information, see https://pre-commit.ci

---------

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
2023-02-07 19:30:33 -03:00
Mahesh Vashishtha af99040123
Add a note about -W vs filterwarnings. (#10713)
Closes #10687

Signed-off-by: mvashishtha <mahesh@ponder.io>
2023-02-07 19:27:34 -03:00
github-actions[bot] 9c93c96b14
[automated] Update plugin list (#10707)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-02-07 07:59:57 -03:00
github-actions[bot] 4a46ee8bc9
[automated] Update plugin list (#10699)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2023-01-30 10:15:02 -03:00
vin01 86a1beba07
Clarify docs for `match` regarding escaping (#10695)
Add example using `re.escape` to escape arbitrary literal strings which might contain regular expression characters like `.` or `)`.

Closes #10595
2023-01-27 08:11:00 -03:00
pre-commit-ci[bot] 61cfaacec6
[pre-commit.ci] pre-commit autoupdate (#10671)
updates:
- [github.com/asottile/blacken-docs: v1.12.1 → 1.13.0](https://github.com/asottile/blacken-docs/compare/v1.12.1...1.13.0)
- [github.com/pre-commit/pygrep-hooks: v1.9.0 → v1.10.0](https://github.com/pre-commit/pygrep-hooks/compare/v1.9.0...v1.10.0)
2023-01-17 12:09:19 +02:00
Bruno Oliveira b2ac31cc9f Merge pull request #10659 from pytest-dev/release-7.2.1
Prepare release 7.2.1

(cherry picked from commit 94c05bc2a489a3d6eb5cb47991741f8a61bb4099)
2023-01-14 09:21:43 -03:00
Yusuke Kadowaki 10220d3f31 Change the default policy to all 2022-12-25 00:18:38 +09:00
Bruno Oliveira b90e7b84d0 Remove reference to explicit pytest tox support
This reference no longer exists in tox 4.0 docs.
2022-12-14 08:38:11 -03:00
Bruno Oliveira 19807ab79a Pin packaging while building docs
Packaging >=22 no longer supports 'latest' versions, which is the version that is assigned when building the docs.

https://github.com/pytest-dev/pytest/pull/10578#issuecomment-1348249045

Also first install pytest, then `docs/en/requirements.txt`:

Installing the requirements last will honor pins of libraries
shared between pytest and the docs build.
2022-12-14 08:38:11 -03:00
pytest bot 39b6bb551c [automated] Update plugin list 2022-12-04 00:20:05 +00:00
Marko Pacak 9fbd67dd4b
Class methods can now be discovered as tests (#10552)
Fix #10525
2022-12-02 15:53:04 +00:00
Bruno Oliveira 314e623304
Merge pull request #10549 from yusuke-kadowaki/more_doc_update
Documentation update for the tmp_path configurations
2022-12-01 12:23:43 -03:00
Yusuke Kadowaki 62e75c7d55 Documentation update for tmp_path configurations 2022-12-01 22:29:46 +09:00
github-actions[bot] fd30759d94
[automated] Update plugin list (#10536)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2022-11-29 09:14:38 +00:00
Yusuke Kadowaki f513d33d5a
Modify documentation to use `.stash` when storing test results. (#10535) 2022-11-27 22:09:56 +02:00
github-actions[bot] 7710e18b4c
[automated] Update plugin list (#10519)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2022-11-22 08:05:40 -03:00
Yusuke Kadowaki cca029d55e
Add configuration options to control how `tmp_path` directories are kept (#10442)
Close #8141
2022-11-15 09:11:39 -03:00
pytest bot 593178d909 [automated] Update plugin list 2022-11-13 00:22:21 +00:00
pytest bot a006dabf6e [automated] Update plugin list 2022-11-08 11:13:43 +00:00
Florian Bruhin 2f33ea87c8
Remove done trainings (#10471) 2022-11-04 18:38:09 +01:00
Florian Bruhin 646a46e5f4
Edit changelog for 7.2.0 (#10423)
Fix some typos, and consolidate two entries for the same feature into one.
2022-10-25 19:47:16 +02:00
Anthony Sottile bbec1ce67f
upgrade pygments-pytest for 7.2.x coloring 2022-10-25 10:52:53 -04:00
Ronny Pfannschmidt 5a040aef97
Merge pull request #10412 from pytest-dev/release-7.2.0 (#10419)
Prepare release 7.2.0

(cherry picked from commit ac4e3cced9fb1df60df271cce308f07713764857)
2022-10-25 13:12:55 +02:00
Itxaso Aizpurua 9e1804a6ee
Add --log-disable CLI option (#10371)
Fixes #7431
2022-10-23 18:23:34 -03:00
Tony Narlock 7fada7127e docs(output): Note --no-show-locals 2022-10-14 16:38:14 -05:00
Ofek Lev 86602ce6e0
Fix packaging example 2022-10-12 11:51:26 -04:00
Thomas Grainger 246ceb84bd
Update doc/en/deprecations.rst 2022-10-10 13:58:05 +01:00
Thomas Grainger 2fd160110c
Merge branch 'main' into warn-when-a-mark-is-applied-to-a-fixture 2022-10-10 13:55:24 +01:00
pre-commit-ci[bot] 0de2aa93f0 [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
2022-10-10 11:30:13 +00:00
Thomas Grainger d86df89a92
Update doc/en/deprecations.rst
Co-authored-by: Bruno Oliveira <nicoddemus@gmail.com>
2022-10-10 12:28:22 +01:00
Thomas Grainger 8a40fc5315
PytestReturnNotNoneWarning now subclasses PytestRemovedIn8Warning (#10196)
As discussed in https://github.com/pytest-dev/pytest/pull/9956#issuecomment-1132710934.

Also added PytestRemovedIn8Warning to the reference docs.
2022-10-09 20:10:45 -03:00
Vivaan Verma 196f01965e
Replace entrypoint example with `pyproject.toml` in docs (#10359)
Fixes #10344
2022-10-09 17:42:42 -03:00
Simon K 3bf2bc55b1
Add deprecations for tests written for `nose` (#9907)
Fixes #9886
2022-10-09 17:16:33 -03:00
Thomas Grainger 5c286d19d8
Update doc/en/deprecations.rst 2022-10-09 20:11:51 +01:00
Thomas Grainger faac197fcf
Merge branch 'main' into warn-when-a-mark-is-applied-to-a-fixture 2022-10-09 20:10:53 +01:00
Samuel Gaist a28d595b46
doc: add note to help modernize code bases to use pathlib
Fixes #10199
2022-10-08 10:18:08 +02:00
wodny 2bc036e50a
Mention pythonpath confval in Good Integration Practices (#10314)
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
2022-10-07 13:03:13 -03:00
Bruno Oliveira 79c2e92bb8
Merge pull request #10349 from nicoddemus/doc-setup-teardown-nose 2022-10-07 11:48:09 -03:00
Florian Bruhin 9be1e3fac8
doc: Add second day for enterPy training (#10348) 2022-10-07 16:13:05 +02:00
Bruno Oliveira 0c21d60349 Improve documentation for setup() and teardown() nose support
Fix #9549
2022-10-07 11:10:28 -03:00
Thierry Moisan 06007de7ba
Fix a few broken links in the documentation 2022-10-05 10:24:55 -04:00
Ronny Pfannschmidt 0fdacb6db5 deprecate hook configuration via marks/attributes
fixes #4562
2022-09-20 16:22:26 +02:00
Fredrik Berndtsson 246129089c doc: Fix 404 'identify flaky test' link (#10244) 2022-09-15 23:34:22 +02:00
Florian Bruhin 34765f6b2e
doc: Add link for enterPy training (#10299) 2022-09-15 17:07:02 +02:00
pytest bot f53b49c8c4 [automated] Update plugin list 2022-09-11 00:22:18 +00:00
skhomuti c326bd5669 Add allure-pytest to the popular plugins list 2022-09-08 22:12:44 +05:00
Florian Bruhin 1e0aa16908 Update open trainings 2022-09-07 14:48:49 +02:00
Bruno Oliveira 77e34526e8
Merge pull request #10225 from nicoddemus/sort-fixtures-docs 2022-09-06 08:33:27 -03:00
pytest bot 50f390f015 [automated] Update plugin list 2022-09-04 00:23:26 +00:00
Bruno Oliveira 7f4b63b143 Merge pull request #10259 from pytest-dev/release-7.1.3
Prepare release 7.1.3

(cherry picked from commit 3739e6cd4830cf707dff3fb5c5b93d7a2cec3663)
2022-09-02 08:24:18 -03:00
Philipp A 245a8c23dd
Revamp good practices (#10206)
* Recommend importlib import mode for new projects
* Recommend src layout more strongly
* Switch to hatchling as the packaging tool in the example (following PyPA)
* Add explanation about the different import modes
2022-09-01 07:55:41 -03:00
Bruno Oliveira a9bbfb87d6
Merge pull request #10252 from nicoddemus/fix-regendoc
Fix regendoc
2022-08-31 14:32:36 -03:00
Bruno Oliveira 1caa099e42 Fix regendoc
The finalizers example was wiping out code needed for the examples below.
2022-08-31 14:28:33 -03:00
github-actions[bot] 0fc3a977a9
[automated] Update plugin list (#10253)
Co-authored-by: pytest bot <pytestbot@users.noreply.github.com>
2022-08-29 17:49:38 -03:00
pytest bot 932264d8fd [automated] Update plugin list 2022-08-21 00:21:46 +00:00
Sviatoslav Sydorenko 71aa1388e0
Drop `wheel` from `pyproject.toml` example
It is unnecessary and has been deleted from the setuptools' docs too.
The setuptools' PEP 517 build backend implementation has been
auto-adding the `wheel` dependency since it's first been implemented.
2022-08-19 19:01:40 +02:00
Tatiana Ovary 3039391b83
Update documentation on how pytest.warns affects DeprecationWarning #9291 (#10141)
Co-authored-by: Dani Sancas <lord.sancas@gmail.com>

On-behalf-of: @clarityai-eng <tech@clarity.ai>

Signed-off-by: Tatiana Ovary <tatiana.ovary@clarity.ai>
2022-08-17 11:44:58 -03:00