Commit Graph

1888 Commits

Author SHA1 Message Date
Anthony Sottile cc78444c30 Merge remote-tracking branch 'origin/master' into mm 2019-11-15 15:26:57 -08:00
Anthony Sottile c9a96cdee8 Preparing release version 5.2.4 2019-11-15 13:26:56 -08:00
Bruno Oliveira d2ea9e2db5 Remove report_log in favor of pytest-reportlog
Fix #6180
2019-11-14 19:47:26 -03:00
Bruno Oliveira e856638ba0
Preparing release version 5.2.3 (#6190)
Preparing release version 5.2.3
2019-11-14 18:17:28 -03:00
Michael Shields bd68c2a3dc
Update advice about _called_from_test.
Instead of giving an example of using sys and then, at the end,
advising not to use sys, just give a correct example. This is
especially helpful since mypy 0.740 has started (correctly) complaining
about sys._called_from_pytest not being present.
2019-11-14 19:44:27 +00:00
Bruno Oliveira 5e8c47faad Preparing release version 5.2.3 2019-11-14 11:12:06 -03:00
Bruno Oliveira 2a67637acc Issue a warning to prepare change of 'junit_family' default value
Fix #6179
2019-11-13 19:55:13 -03:00
Daniel Hahler b06f33f474 terminal: report ``session.shouldfail`` reason (``-x``)
Via https://github.com/blueyed/pytest/pull/108.
2019-11-13 16:18:41 +01:00
Brett Cannon 0b40749c98
Delineate syntactically that the 'match' argument to 'raises' is keyword-only 2019-11-12 12:32:05 -08:00
Daniel Hahler 04f27d4eb4 unittest: do not use TestCase.debug() with `--pdb`
Fixes https://github.com/pytest-dev/pytest/issues/5991
Fixes https://github.com/pytest-dev/pytest/issues/3823

Ref: https://github.com/pytest-dev/pytest-django/issues/772
Ref: https://github.com/pytest-dev/pytest/pull/1890
Ref: https://github.com/pytest-dev/pytest-django/pull/782

- inject wrapped testMethod

- adjust test_trial_error

- add test for `--trace` with unittests
2019-11-10 00:21:51 +01:00
Steffen Schroeder ceeb7bd085 Fixed broken links 2019-11-06 20:54:41 +01:00
Steffen Schroeder 1cecdf6619 Added checklinks to tox and release.py 2019-11-06 20:54:41 +01:00
Bruno Oliveira 74f4ec5986
Making it possible to access the pluginmanager in the pytest_ad… (#6106)
Making it possible to access the pluginmanager in the pytest_addoptio…
2019-11-06 15:18:59 -03:00
Daniel Hahler e7320c6b54
Merge pull request #5926 from AtakamaLLC/optional-multiline
Add log-auto-indent option to control multiline formatting
2019-11-06 00:35:24 +01:00
Joshua Storck f400804206 Removing pluginmanager as parameter in definition of pytest_addoption hook 2019-10-30 16:25:50 -04:00
Joshua Storck 7a96d94fd4 Making it possible to access the pluginmanager in the pytest_addoption hook 2019-10-30 14:18:13 -04:00
Bruno Oliveira b99661b9d7 Introduce --report-log option
Fix #4488
2019-10-30 09:43:33 -03:00
Michael Krebs 1f5b454355 Add log-auto-indent option to control multiline formatting 2019-10-25 11:31:33 -04:00
Bruno Oliveira b27ba97721 Preparing release version 5.2.2 2019-10-24 19:24:04 -04:00
Bruno Oliveira 2bee7d7c3e Update Tidelift docs with latest campaign
Tidelift has launched a new marketing campaign as outlined here:

* https://forum.tidelift.com/t/task-enhancement-marketing-the-tidelift-subscription-to-your-users/321

This PR splits the previous "sponsor" information into two, Open Collective
and Tidelift (as they have very different target audiences).

Also took the opportunity to reorder some items at the end of
the contents page in a manner that I believe make more sense.
2019-10-24 14:58:58 -03:00
Albert Tugushev 18786992bb Update doc to use contextlib2.nullcontext
nullcontext has been backported in contextlib2==0.6.0
2019-10-19 15:09:37 +07:00
Andrzej Klajnert f2dd9cc63e Remove redundant mention from 5.2.0 release notes. 2019-10-17 13:17:34 +02:00
Bruno Oliveira 0383d43645 Add missing version added/changed markers to docs
Notice some features since 5.0 were not being properly
marked in which version they have been added/changed.
2019-10-15 19:45:58 -03:00
Nattaphoom Chaipreecha 83ba5eb58a Add pudb to project examples 2019-10-12 08:10:04 +07:00
Nattaphoom Chaipreecha d07c5ba4ae Update pdb++ link (moved to GitHub) 2019-10-12 08:09:49 +07:00
Bruno Oliveira 57141dc708
Add link to technical aspects issue to the py27-py34 docs 2019-10-11 08:50:38 -03:00
Oliver Bestwalter 71ad5b0fbb
remove cancelled training sidebar 2019-10-10 12:11:16 +02:00
Bruno Oliveira 12cc729f6b Preparing release version 5.2.1 2019-10-06 08:00:49 -04:00
Anthony Sottile 33c3ec66b7
Merge pull request #5898 from kevinjfoley/doc-typo-fix
Fix doc typo
2019-10-01 12:58:54 -07:00
Kevin J. Foley b490f5f979 Fix doc typo 2019-10-01 10:17:26 -04:00
tadashigaki acfd0fd9d6 Update doc: pytest section in setup.cfg 2019-10-01 02:44:07 +09:00
Bruno Oliveira 068ef90b92 Preparing release version 5.2.0 2019-09-28 21:18:37 -04:00
Bruno Oliveira d3d9f9f668 Merge remote-tracking branch 'upstream/master' into mm 2019-09-23 12:09:01 -03:00
Bruno Oliveira 1b4ad7774b
Fix logging doc: change x.level to x.levelno (#5866)
Fix logging doc: change x.level to x.levelno
2019-09-21 11:28:40 -03:00
Daniel Hahler 409cc2946a Merge master into features 2019-09-21 16:22:48 +02:00
Bruno Oliveira 3114be9181
Revert "Show banner/full page for the Digital Climate Strike (#… (#5867)
Revert "Show banner/full page for the Digital Climate Strike (#5861)"
2019-09-21 11:09:34 -03:00
Bruno Oliveira e4103cb02c
Release version 5.1.3 (#5859)
Release version 5.1.3
2019-09-21 10:56:16 -03:00
Bruno Oliveira 217605c217 Revert "Show banner/full page for the Digital Climate Strike (#5861)"
This reverts commit c8cf748c49, reversing
changes made to 702acdba46.
2019-09-21 10:38:10 -03:00
James Cooke 2fcf21a6c7 Fix logging doc: change x.level to x.levelno 2019-09-20 18:38:47 +01:00
Bruno Oliveira 249b53e623 Show banner/full page for the Ditigal Climate Strike
As discussed in the mailing list, pytest will join the
digital strike for the climate on Sep 20th. This will show
a closable banner on the docs until the date, and when the date
comes the banner will become a (closable) full page.

I will also pin an issue saying that the developers won't be
available on Sep 20th.
2019-09-19 08:26:25 -03:00
Bruno Oliveira 1a9f4a51cb Preparing release version 5.1.3 2019-09-18 10:11:59 -03:00
Bruno Oliveira 892bdd59dc Normalize all summary durations, including quiet ones 2019-09-18 10:10:25 -03:00
Bruno Oliveira 6918d07560 Merge remote-tracking branch 'upstream/features' into aklajnert/1682-dynamic-scope 2019-09-18 07:44:18 -03:00
Anthony Sottile 8f2f51be6d Clarify docs by showing tox.ini considered before setup.cfg 2019-09-11 14:07:06 -07:00
Gene Wood f0d538329c
Update doc regarding pytest.raises
Remove reference to the `message` argument in the docs as it was deprecated in #4539
2019-09-09 12:14:09 -07:00
Gene Wood bc163605ab
Fix anchor link from Good Practices to Pythonpath doc 2019-09-04 09:18:10 -07:00
aklajnert 10bf6aac76 Implemented the dynamic scope feature. 2019-08-31 18:12:24 +02:00
Bruno Oliveira e56544cb58 Preparing release version 5.1.2 2019-08-30 12:43:47 -03:00
Bruno Oliveira f9cc704b1a Replace session duration to a fix value in regendoc 2019-08-30 12:42:14 -03:00
linchiwei123 01b9774e3b update doc 2019-08-25 23:50:41 +08:00
Anthony Sottile b135f5af8d Preparing release version 5.1.1 2019-08-20 11:30:36 -07:00
Florian Bruhin c049fd85ab Remove cancelled training 2019-08-19 22:07:53 +02:00
Hugo van Kemenade a287aea00e
Docs: update tense
pytest 4.6.0 was released in June 2019

https://pypi.org/project/pytest/#history
2019-08-18 13:34:59 +03:00
Bruno Oliveira eaf7ce9a99 Preparing release version 5.1.0 2019-08-15 20:00:09 -04:00
Bruno Oliveira 409d61b972 Merge remote-tracking branch 'upstream/master' into release-5.1.0 2019-08-15 19:46:46 -04:00
mei-li f4a84a8dfd reword a parametrize example sentence 2019-08-15 18:12:18 +02:00
Bruno Oliveira 1049a38cee Fix wording as suggested in review of #5741 2019-08-15 10:05:42 -03:00
Bruno Oliveira d7f082519a Merge remote-tracking branch 'upstream/master' into mm
Conflicts:
	src/_pytest/outcomes.py
2019-08-15 10:03:52 -03:00
boris 3eb4973065 remove %s formatting from docs 2019-08-12 00:09:53 -06:00
Tim Hoffmann b095e0de47 Improve docs of pytest.importorskip 2019-08-09 21:35:03 +02:00
Bruno Oliveira 2f065a555f Merge remote-tracking branch 'upstream/master' into release-5.1.0 2019-08-09 12:36:19 -03:00
boris 7560a7b808 trivial doc change 2019-08-07 21:49:30 -06:00
boris 78de9d4677 replace implicit code tag with colon .replace("::\n\n.. code-block", ":\n\n.. code-block") 2019-08-06 16:20:06 -07:00
boris 23a0b532db Revert "remove implicit code tags .replace("::\n\n.. code-block", "\n\n.. code-block")"
This reverts commit 9fce0bdd88.
2019-08-06 16:18:06 -07:00
boris 9fce0bdd88 remove implicit code tags .replace("::\n\n.. code-block", "\n\n.. code-block") 2019-08-06 15:46:57 -07:00
boris 5f95dce956 ran blacken-docs 2019-08-06 13:34:58 -07:00
boris 75d0b899bb ran pyupgrade-docs again 2019-08-06 13:33:21 -07:00
boris 7f90e74e02 label code blocks 2019-08-06 13:25:54 -07:00
boris cf7761f91f ran pyupgrade-docs 2019-08-06 12:40:27 -07:00
Bruno Oliveira f43b54aaeb Add CHANGELOG for 4.6.5 (#5696) 2019-08-05 15:09:31 -03:00
Daniel Hahler aa06e6c8f3 Merge master into features 2019-08-05 19:12:32 +02:00
Anthony Sottile 1a66a503b6
Merge pull request #5690 from nicoddemus/custom-exit-code-docs
Mention pytest-custom_exit_code in the docs
2019-08-04 19:10:36 -07:00
Yash Todi 0d5ed57b40
Added info to access exitcodes directly 2019-08-04 22:35:51 +05:30
Bruno Oliveira 8db6642515 Mention pytest-custom_exit_code in the docs
Related to #5689
2019-08-03 10:15:56 -03:00
Daniel Hahler b5b710b3ae Merge master into features
Several conflicts, mostly due to 2c402f4bd.

Conflicts:
	.pre-commit-config.yaml
	src/_pytest/outcomes.py
	src/_pytest/python_api.py
	tox.ini
2019-08-02 16:52:51 +02:00
Semen Zhydenko 2ca47cb3f5 programatically -> programmatically 2019-08-01 15:11:26 +02:00
Florian Bruhin cb15e7c700
Merge pull request #5674 from helloocc/master
Doc fix: remove redundant parentheses.
2019-07-30 10:46:29 +02:00
Xixi Zhao 2959fb3198
Doc fix: remove redundant parentheses. 2019-07-30 16:18:22 +08:00
Bruno Oliveira 50c7b5d2b5
fix setenv prepend docs (#5658)
fix setenv prepend docs
2019-07-24 20:11:05 -03:00
Thomas Grainger 3bdcd6b4f3
Update doc/en/monkeypatch.rst 2019-07-24 20:49:31 +01:00
Bruno Oliveira d89c88478d
Merge pull request #5657 from helloocc/master
Doc fix: delete useless.
2019-07-24 15:22:58 -03:00
Thomas Grainger 635916052c
fix setenv prepend docs 2019-07-24 17:23:48 +01:00
helloocc 28343bdcbd Merge remote-tracking branch 'upstream/master' 2019-07-24 23:35:22 +08:00
Thomas Grainger ebfe8eabf5
Update doc/en/monkeypatch.rst 2019-07-24 14:27:51 +01:00
Thomas Grainger 829cc5a242
fix docs about syspath_prepend
eg it does not modify $PATH
2019-07-24 14:27:05 +01:00
Bruno Oliveira f163b37f6a Run regen 2019-07-23 10:00:35 -04:00
Bruno Oliveira 1873dc6a8a Fix fixture example in docs 2019-07-23 09:48:22 -04:00
Xixi Zhao 6e687c4354
Doc fix: m1 isn't a dependency of f1.
According to the file in `example/fixtures/test_fixtures_order.py`, m1 isn't a dependency of f1.
2019-07-23 15:09:32 +08:00
Xixi Zhao 66cfc66d63
Update index.rst 2019-07-22 16:01:56 +08:00
Oliver Bestwalter c0231ae780
Add info about open training in Leipzig 2019-07-18 21:06:53 +02:00
Bruno Oliveira 157515f3c5
Fix/Remove broken links (#5613)
Fix/Remove broken links
2019-07-17 13:52:05 -03:00
Bruno Oliveira 183750fa86
CSS changes to the API reference (#5609)
CSS changes to the API reference
2019-07-17 06:24:31 -03:00
Steffen Schroeder 1e34734f8f Fixed link to Python Classifiers 2019-07-16 21:56:04 +02:00
Steffen Schroeder 7c2e843358 Fixed link to correct anchor of Python's -w postion 2019-07-16 21:56:04 +02:00
Steffen Schroeder 79414164c2 Fixed broken links in adopt.rst 2019-07-16 21:56:03 +02:00
Steffen Schroeder 0cca7f831a Fixed broken links and non-existing anchors in release announcements 2019-07-16 21:56:03 +02:00
Steffen Schroeder 1f4ae789b8 Change link to "Where do Google's flaky tests come from?"
Although it's available, linkchecker complained about it.
It was changed to the permanent redirect.
2019-07-16 21:56:03 +02:00
Steffen Schroeder 3f46315a9d Remove link to non-existing anchor 2019-07-16 21:56:03 +02:00
Steffen Schroeder e03b8b9e95 Update/Fix links to using projects 2019-07-16 21:56:03 +02:00
Steffen Schroeder eb7f950e20 Fixed broken link to virtualenv 2019-07-16 21:56:03 +02:00
Thomas Grainger 7440cece59
Merge pull request #5589 from graingert/fixture-yield-exit-stack
de-emphasize request.addfinalizer Fixes #5587
2019-07-16 18:33:59 +01:00
Florian Bruhin d9eab12ee0 Remove Europython training 2019-07-16 15:03:54 +02:00
Tim Hoffmann bb7608c56f Change section titles in docs 2019-07-15 16:25:33 +02:00
Tim Hoffmann 3ad315bcee Improve CSS layout of API reference 2019-07-15 16:15:59 +02:00
Thomas Grainger a96710dd8a
demonstrate ExitStack assuming connect returns a context manager 2019-07-15 14:05:19 +01:00
Tim Hoffmann 01606315aa More CSS fine-tuning 2019-07-15 13:40:30 +02:00
Tim Hoffmann da5add1294 Improve CSS layout 2019-07-14 18:58:07 +02:00
Wojtek Erbetowski d23fbab188 Add autouse fixture order information (#3404).
A case with a fixture use both as an autouse and explititly
was raised. This case sounds too narrow to add to documentation
(and could be misleading for people learning pytest with explicitely
using an autouse fixture). At the same time there was no documentation
on the autouse vs regular fixture order, therefore this commit adds
such an information. Code sample grew and it was extracted to the file.
2019-07-13 11:43:47 +02:00
Bruno Oliveira 666acc9b7a
doctest: Add +NUMBER option to ignore irrelevant floating-point… (#5576)
doctest: Add +NUMBER option to ignore irrelevant floating-point differences
2019-07-11 07:25:37 -03:00
David Röthlisberger a740ef2036 docs: Document doctest +NUMBER limitation with strings
Also added an "xfail" testcase for the same.
2019-07-11 10:06:57 +01:00
Thomas Grainger c224c4f1d6
de-emphasize request.addfinalizer 2019-07-10 14:52:40 +01:00
Bruno Oliveira 31738155b5
Remove deprecated features (#5529)
Remove deprecated features
2019-07-09 19:04:06 -03:00
Bruno Oliveira 628ff4d619
Improve docs sidebar layout (#5568)
Improve docs sidebar layout
2019-07-08 19:24:48 -03:00
Bruno Oliveira 9b78a216a2 Remove unused import 2019-07-08 19:08:09 -03:00
David Röthlisberger 2a23fdab9f docs: Tidy up doctest options section
* Move the parts about "how to configure it" (pytest.ini vs. inline
  comment) together.
* Move `--doctest-continue-on-failure` into its own sub-heading, as it
  isn't related to the doctest optionflags.
2019-07-08 17:07:58 +01:00
David Röthlisberger aaa7e837cc doctest: Add +NUMBER option to ignore irrelevant floating-point differences
When enabled, floating-point numbers only need to match as far as the
precision you have written in the expected doctest output. This avoids
false positives caused by limited floating-point precision, like this:

    Expected:
        0.233
    Got:
        0.23300000000000001

This is inspired by Sébastien Boisgérault's [numtest] but the
implementation is a bit different:

* This implementation edits the literals that are in the "got"
  string (the actual output from the expression being tested), and then
  proceeds to compare the strings literally. This is similar to pytest's
  existing ALLOW_UNICODE and ALLOW_BYTES implementation.

* This implementation only compares floats against floats, not ints
  against floats. That is, the following doctest will fail with pytest
  whereas it would pass with numtest:

      >>> math.py  # doctest: +NUMBER
      3

  This behaviour should be less surprising (less false negatives) when
  you enable NUMBER globally in pytest.ini.

Advantages of this implementation compared to numtest:

* Doesn't require `import numtest` at the top level of the file.
* Works with pytest (if you try to use pytest & numtest together, pytest
  raises "TypeError: unbound method check_output() must be called with
  NumTestOutputChecker instance as first argument (got
  LiteralsOutputChecker instance instead)").
* Works with Python 3.

[numtest]: https://github.com/boisgera/numtest
2019-07-08 17:07:58 +01:00
Tim Hoffmann 71c8ca7d3d Improve sidebar layout 2019-07-07 20:32:09 +02:00
Tim Hoffmann 56a0dd7658 Update doc footer/copyright 2019-07-07 20:23:56 +02:00
Bruno Oliveira bb29f31d22 Preparing release version 5.0.1 2019-07-04 20:01:16 -04:00
Bruno Oliveira b08ae4449b
Add docs about Tidelift and OpenCollective (#5527)
Add docs about Tidelift and OpenCollective
2019-07-04 07:38:17 -03:00
Anthony Sottile 776a632170
Merge pull request #5540 from bazcrown/yml2yaml
Substituted 'yml' to '.yaml' in relevant files
2019-07-03 18:47:26 -04:00
Thomas Grainger 2b9522e9da
remove documentation about setuptools integration Refs #5534
integrating with `python setup.py test` is not good practice!
2019-07-03 16:42:53 +01:00
Florian Bruhin 9677099acf Add upcoming trainings 2019-07-03 14:50:32 +02:00
Michael Moore 1b0e8d73d5 Substituted 'yml' to '.yaml' in relevant files 2019-07-02 23:49:06 -07:00
Andreu Vallbona Plazas fa9791127a
Added talk about pytest in PyBCN June 2019
Added talk about pytest in PyBCN June 2019
2019-07-02 23:18:52 +02:00
Bruno Oliveira 2d9b432613 Add docs about Tidelift and OpenCollective
Give an overview of how we as an organization will use the donated money,
as well as show this information more prominently in the docs.
2019-06-30 14:13:30 -03:00
Bruno Oliveira c470ade0a5 Remove 'RemovedInPytest4Warning' 2019-06-30 13:31:39 -03:00
Bruno Oliveira 7e58defc15 Remove 'pytest.config' 2019-06-30 13:18:07 -03:00
Bruno Oliveira 13f7f27fd2 Remove 'message' parameter from pytest.raises 2019-06-30 13:18:06 -03:00
Bruno Oliveira 279733a30b Remove support for 'code as string' from pytest.raises and pytest.warns 2019-06-30 11:40:24 -03:00
Bruno Oliveira d4a76a0b99
doc(plugin_hooks): Improve documentation for writing plugin hoo… (#5517)
doc(plugin_hooks): Improve documentation for writing plugin hooks.
2019-06-29 09:39:49 -03:00
Bruno Oliveira 789a3662ce Fix linting 2019-06-29 09:11:09 -03:00
Niklas Meinzer 93a68cdfb4 doc(plugin_hooks): Improve documentation for writing plugin hooks. 2019-06-29 14:02:53 +02:00
Anthony Sottile 844d660d5c Merge pull request #5520 from asottile/release-4.6.4
Preparing release version 4.6.4
2019-06-28 19:09:10 -07:00
Anthony Sottile 58bfc7736f Use shutil.which to avoid distutils+imp warning 2019-06-28 14:44:49 -07:00
Anthony Sottile 55d2fe076f Use importlib instead of imp in demo 2019-06-28 14:40:10 -07:00
Anthony Sottile 5e39eb91bb Correct Zac-HD's name in changelogs 2019-06-28 14:40:10 -07:00
Anthony Sottile fd2f320485 Preparing release version 5.0.0 2019-06-28 14:39:53 -07:00
Bruno Oliveira 37fb50a3ed
Features assertion pass hook (#3479)
Features assertion pass hook
2019-06-26 21:14:19 -03:00
Bruno Oliveira 3afee36ebb Improve docs and reference 2019-06-26 19:15:00 -03:00
Zac Hatfield-Dodds ed85c83154 Deprecate funcargnames alias 2019-06-26 08:53:17 +10:00
Bruno Oliveira 3f5b078462
Merge pull request #5441 from nicoddemus/faulthandler-5440
Integrate pytest-faulthandler into the core
2019-06-24 20:01:15 -03:00
Bruno Oliveira 3ce31b6370 Change pytest-faulthandler for simplification
* The --no-faulthandler option is not necessary given that we can use
  `-p no:faulthandler`.

* The `--faulthandler-timeout` command-line option has become an ini
  option, for the reasons described in
  https://github.com/pytest-dev/pytest-faulthandler/issues/34 and
  users can still set it from the command-line.

Fix pytest-dev/pytest-faulthandler#34
2019-06-22 19:22:43 -03:00
Bruno Oliveira a37b902afe Integrate pytest-faulthandler into the core
* Add pytest-faulthandler files unchanged
* Adapt imports and tests
* Add code to skip registration of the external `pytest_faulthandler`
  to avoid conflicts

Fix #5440
2019-06-21 21:02:24 -03:00
curiousjazz77 12b76b6261
Update cache.rst 2019-06-21 15:48:59 -07:00
Ronny Pfannschmidt 0627d92df2 fix typos in the resolution of #5125 2019-06-17 20:35:23 +02:00
Ronny Pfannschmidt 1cfea5f1b3 add ExitCode reference in usage 2019-06-15 21:41:55 +02:00
Ronny Pfannschmidt 103d6146b0 document exitcode members 2019-06-15 17:18:21 +02:00
patriksevallius 701d0351a6
Add missing 'e' to test_mod(e). 2019-06-13 06:01:30 +02:00
Anthony Sottile ede8b87560
Merge pull request #5438 from nicoddemus/result-log-deprecation
Postpone removal of --result-log to pytest 6.0
2019-06-12 10:45:02 -07:00
Bruno Oliveira 52780f39ce Postpone removal of --result-log to pytest 6.0
As we did not provide an alternative yet, it is better to postpone
the actual removal until we have provided a suitable and stable
alternative.

Related to #4488
2019-06-12 08:26:11 -03:00
Anthony Sottile 18c2ff6625 Merge pull request #5435 from asottile/release-4.6.3
Preparing release version 4.6.3
2019-06-11 09:59:05 -07:00
Ralph Giles 918268774b
Add `slow` marker in run/skip option example.
The example implementation of a `--runslow` option results in
a `PytestUnknownMarkWarning`. Include registering the custom
mark in the example, based on the documentation in markers.rst.
2019-06-06 10:15:43 -07:00
Anthony Sottile be2be040f9 Clean up u' prefixes and py2 bytes conversions 2019-06-04 17:50:34 -07:00
Bruno Oliveira 2a3d643bdf
Documentation: expansion of Monkeypatch to include mocked classes and dictionaries (#5315)
Documentation: expansion of Monkeypatch to include mocked classes and dictionaries
2019-06-03 19:30:29 -03:00
Anthony Sottile 9657166a22 Merge pull request #5379 from asottile/release-4.6.2
Preparing release version 4.6.2
2019-06-03 12:19:42 -07:00
Pulkit Goyal 1d6bbab2b0 Add a new Exceptions section in documentation and document UsageError 2019-06-03 14:23:56 -03:00
Anthony Sottile 4df529e5b9 Clean up __future__ and coding: in tests 2019-06-03 12:08:02 -03:00
Anthony Sottile a91fe1fedd pre-commit run pyupgrade --all-files 2019-06-03 12:08:02 -03:00
Anthony Sottile 5034399d7a pre-commit run fix-encoding-pragma --all-files 2019-06-03 12:08:01 -03:00
Bruno Oliveira 28ac469eaa
Merge pull request #5367 from apollovy/master
Fix typo about interpreters count in doc/en/example/parametrize.html
2019-06-02 20:43:53 -03:00
Bruno Oliveira 5999782768 Use python 3 interpreters in example 2019-06-02 19:20:00 -03:00
Bruno Oliveira 6e68532bb3
Merge pull request #5362 from asottile/release-4.6.1 (#5365)
Merge pull request #5362 from asottile/release-4.6.1
2019-06-02 19:17:29 -03:00
Yuri Apollov 5c016d1021 Fix typo about interpreters count in doc/en/example/parametrize.html 2019-06-02 23:57:22 +03:00
Anthony Sottile 642ef6dc1b Merge pull request #5362 from asottile/release-4.6.1
Preparing release version 4.6.1
2019-06-02 11:47:26 -07:00
Bruno Oliveira 4d49ba6529 Drop Python 2.7 and 3.4 support
* Update setup.py requires and classifiers
* Drop Python 2.7 and 3.4 from CI
* Update docs dropping 2.7 and 3.4 support
* Fix mock imports and remove tests related to pypi's mock module
* Add py27 and 34 support docs to the sidebar
* Remove usage of six from tmpdir
* Remove six.PY* code blocks
* Remove sys.version_info related code
* Cleanup compat
* Remove obsolete safe_str
* Remove obsolete __unicode__ methods
* Remove compat.PY35 and compat.PY36: not really needed anymore
* Remove unused UNICODE_TYPES
* Remove Jython specific code
* Remove some Python 2 references from docs

Related to #5275
2019-06-02 14:39:11 -03:00
Hugo e2ac4b782a
Fix link anchor 2019-06-01 23:27:20 +03:00
Anthony Sottile e7cd00ac92 Preparing release version 4.6.0 2019-05-31 23:12:57 -07:00
Bruno Oliveira f9cafd1c94 Add missing junitxml ini options to the reference docs 2019-05-29 21:13:16 -03:00
Evan Kepner 2dfbed11b4
fix path expansion example 2019-05-27 23:23:18 -04:00
Evan Kepner 24c95c78e7
add updated monkeypatch examples 2019-05-27 20:55:15 -04:00
Bruno Oliveira e38561037d Update docs about py27 and py34 support plans
As discussed in #5275
2019-05-27 19:28:27 -03:00
Bruno Oliveira 66f20b6f5e
Fix invalid Python file encoding "utf8" (#5252)
Fix invalid Python file encoding "utf8"
2019-05-23 20:24:23 -03:00
Anthony Sottile 45c894b73f
Merge pull request #5297 from nicoddemus/tidelift-contents
Add link to tidelift to the main docs
2019-05-21 08:18:07 -07:00
Bruno Oliveira d391274f39 Add link to tidelift to the main docs
As commented in:

https://github.com/pytest-dev/pytest/pull/5240#issuecomment-494175451
2019-05-21 11:12:07 -03:00
oleg-yegorov c5fa1d1c3e
Update fixture.rst
add a missing import
2019-05-21 09:40:31 +03:00
Nikita Krokosh 858010e214 Fixed double `be` word on monkeypatch docs page. 2019-05-16 18:22:41 +10:00
Bruno Oliveira e44a2ef653 Apply suggestions from code review
Co-Authored-By: Daniel Hahler <github@thequod.de>
2019-05-15 20:45:22 -03:00
Bruno Oliveira c6e3ff3ce5 Mention "-m" in the main mark docs 2019-05-15 20:45:22 -03:00
Bruno Oliveira a31098a74e Move section about mark revamp and iteration to historical notes
This has been in place for a long time now, since 3.6.
2019-05-15 20:45:22 -03:00
Bruno Oliveira 7e8044f9b8 Revamp the mark section in the docs
Add an introductory section about how to register marks,
including doing so programatically (#5255).
2019-05-15 20:45:22 -03:00
Anthony Sottile dc75b6af47 Use fix-encoding-pragma pre-commit hook 2019-05-14 15:56:31 -07:00
Bruno Oliveira e668aaf885 Fix indentation and use code-block directives
The code-block directives are required by our blacken-docs hook
2019-05-14 18:59:27 -03:00
Evan Kepner ecd072ea94
add env example to monkeypatch docs 2019-05-12 09:52:22 -04:00
Bruno Oliveira 63fe547d9f Preparing release version 4.5.0 2019-05-11 16:35:32 +00:00
Bruno Oliveira 465b2d998a
Further "unknown marks warning" improvements (#5178)
Further "unknown marks warning" improvements
2019-05-11 13:28:10 -03:00
Bruno Oliveira 73bbff2b74 Introduce record_testsuite_property fixture
This exposes the functionality introduced in fa6acdc as a session-scoped fixture.

Plugins that want to remain compatible with the `xunit2`
standard should use this fixture instead of `record_property`.

Fix #5202
2019-05-10 19:44:27 -03:00
Bruno Oliveira 0594dba5ce Remove unused markers and enable --strict-markers 2019-05-09 19:36:39 -03:00
Bruno Oliveira 685ca96c71 Change ``--strict`` to ``--strict-markers``, preserving the old one
Fix #5023
2019-05-09 19:36:38 -03:00
Bruno Oliveira ccf6c3cb46 Merge remote-tracking branch 'upstream/master' into merge-master-into-features 2019-05-09 19:22:40 -03:00
Bruno Oliveira 5d7686951c Run regendoc 2019-05-08 21:50:08 +00:00
Bruno Oliveira 80c5f6e609 Ignore PytestUnknownMark warnings when regen docs
A lot of our examples use custom markers to make a point and showcase
features, which generates a lot of warnings
2019-05-08 21:46:26 +00:00
Bruno Oliveira 3ac43314ee Preparing release version 4.4.2 2019-05-08 12:46:14 -03:00
Anthony Sottile d1a48ad68f Use exec directly 2019-05-06 23:07:39 -07:00
Bruno Oliveira 784e1e3b7e Add links to pytest.raises `message` workaround
Related to #3974
2019-05-06 12:35:27 -03:00
Bruno Oliveira 9f66102869 Merge remote-tracking branch 'upstream/master' into merge-master-into-features 2019-05-04 10:47:57 -03:00
Don Kirkby 254b195f50
Fix a typo 2019-05-03 22:30:20 -07:00
Bruno Oliveira af40473c9a Add quick note about accessing config through session or item objects
Fix #5030
2019-05-01 11:46:35 -03:00
Bruno Oliveira 204004c8b8
Review doctest docs (#5183)
Review doctest docs
2019-04-29 08:02:59 -03:00
Bruno Oliveira 772a4a5cf3
Remove all version references to obsolete pytest versions (#5184)
Remove all version references to obsolete pytest versions
2019-04-29 08:02:32 -03:00