Skip to content

Commit 49d690d

Browse files
authored
Merge pull request #5014 from nicoddemus/release-4.4.0
Release 4.4.0
2 parents 2812c08 + 4621638 commit 49d690d

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

89 files changed

+2189
-588
lines changed

.travis.yml

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,13 @@ stages:
66
if: repo = pytest-dev/pytest AND tag IS NOT present
77
- name: deploy
88
if: repo = pytest-dev/pytest AND tag IS present
9-
python:
10-
- '3.7'
9+
python: '3.7'
10+
cache: false
11+
12+
env:
13+
global:
14+
- PYTEST_ADDOPTS=-vv
15+
1116
install:
1217
- python -m pip install --upgrade --pre tox
1318

@@ -57,7 +62,8 @@ jobs:
5762
# - pytester's LsofFdLeakChecker
5863
# - TestArgComplete (linux only)
5964
# - numpy
60-
- env: TOXENV=py37-lsof-numpy-xdist PYTEST_COVERAGE=1
65+
# Empty PYTEST_ADDOPTS to run this non-verbose.
66+
- env: TOXENV=py37-lsof-numpy-xdist PYTEST_COVERAGE=1 PYTEST_ADDOPTS=
6167

6268
# Specialized factors for py27.
6369
- env: TOXENV=py27-nobyte-numpy-xdist
@@ -147,4 +153,3 @@ notifications:
147153
skip_join: true
148154
email:
149155
150-
cache: false

AUTHORS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,7 @@ Steffen Allner
222222
Stephan Obermann
223223
Sven-Hendrik Haase
224224
Tadek Teleżyński
225+
Takafumi Arakaki
225226
Tarcisio Fischer
226227
Tareq Alayan
227228
Ted Xiao
@@ -241,6 +242,7 @@ Vidar T. Fauske
241242
Virgil Dupras
242243
Vitaly Lashmanov
243244
Vlad Dragos
245+
Volodymyr Piskun
244246
Wil Cooley
245247
William Lee
246248
Wim Glenn

CHANGELOG.rst

Lines changed: 158 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,164 @@ with advance notice in the **Deprecations** section of releases.
1818
1919
.. towncrier release notes start
2020
21+
pytest 4.4.0 (2019-03-29)
22+
=========================
23+
24+
Features
25+
--------
26+
27+
- `#2224 <https://github.com/pytest-dev/pytest/issues/2224>`_: ``async`` test functions are skipped and a warning is emitted when a suitable
28+
async plugin is not installed (such as ``pytest-asyncio`` or ``pytest-trio``).
29+
30+
Previously ``async`` functions would not execute at all but still be marked as "passed".
31+
32+
33+
- `#2482 <https://github.com/pytest-dev/pytest/issues/2482>`_: Include new ``disable_test_id_escaping_and_forfeit_all_rights_to_community_support`` option to disable ascii-escaping in parametrized values. This may cause a series of problems and as the name makes clear, use at your own risk.
34+
35+
36+
- `#4718 <https://github.com/pytest-dev/pytest/issues/4718>`_: The ``-p`` option can now be used to early-load plugins also by entry-point name, instead of just
37+
by module name.
38+
39+
This makes it possible to early load external plugins like ``pytest-cov`` in the command-line::
40+
41+
pytest -p pytest_cov
42+
43+
44+
- `#4855 <https://github.com/pytest-dev/pytest/issues/4855>`_: The ``--pdbcls`` option handles classes via module attributes now (e.g.
45+
``pdb:pdb.Pdb`` with `pdb++`_), and its validation was improved.
46+
47+
.. _pdb++: https://pypi.org/project/pdbpp/
48+
49+
50+
- `#4875 <https://github.com/pytest-dev/pytest/issues/4875>`_: The `testpaths <https://docs.pytest.org/en/latest/reference.html#confval-testpaths>`__ configuration option is now displayed next
51+
to the ``rootdir`` and ``inifile`` lines in the pytest header if the option is in effect, i.e., directories or file names were
52+
not explicitly passed in the command line.
53+
54+
Also, ``inifile`` is only displayed if there's a configuration file, instead of an empty ``inifile:`` string.
55+
56+
57+
- `#4911 <https://github.com/pytest-dev/pytest/issues/4911>`_: Doctests can be skipped now dynamically using ``pytest.skip()``.
58+
59+
60+
- `#4920 <https://github.com/pytest-dev/pytest/issues/4920>`_: Internal refactorings have been made in order to make the implementation of the
61+
`pytest-subtests <https://github.com/pytest-dev/pytest-subtests>`__ plugin
62+
possible, which adds unittest sub-test support and a new ``subtests`` fixture as discussed in
63+
`#1367 <https://github.com/pytest-dev/pytest/issues/1367>`__.
64+
65+
For details on the internal refactorings, please see the details on the related PR.
66+
67+
68+
- `#4931 <https://github.com/pytest-dev/pytest/issues/4931>`_: pytester's ``LineMatcher`` asserts that the passed lines are a sequence.
69+
70+
71+
- `#4936 <https://github.com/pytest-dev/pytest/issues/4936>`_: Handle ``-p plug`` after ``-p no:plug``.
72+
73+
This can be used to override a blocked plugin (e.g. in "addopts") from the
74+
command line etc.
75+
76+
77+
- `#4951 <https://github.com/pytest-dev/pytest/issues/4951>`_: Output capturing is handled correctly when only capturing via fixtures (capsys, capfs) with ``pdb.set_trace()``.
78+
79+
80+
- `#4956 <https://github.com/pytest-dev/pytest/issues/4956>`_: ``pytester`` sets ``$HOME`` and ``$USERPROFILE`` to the temporary directory during test runs.
81+
82+
This ensures to not load configuration files from the real user's home directory.
83+
84+
85+
- `#4980 <https://github.com/pytest-dev/pytest/issues/4980>`_: Namespace packages are handled better with ``monkeypatch.syspath_prepend`` and ``testdir.syspathinsert`` (via ``pkg_resources.fixup_namespace_packages``).
86+
87+
88+
- `#4993 <https://github.com/pytest-dev/pytest/issues/4993>`_: The stepwise plugin reports status information now.
89+
90+
91+
- `#5008 <https://github.com/pytest-dev/pytest/issues/5008>`_: If a ``setup.cfg`` file contains ``[tool:pytest]`` and also the no longer supported ``[pytest]`` section, pytest will use ``[tool:pytest]`` ignoring ``[pytest]``. Previously it would unconditionally error out.
92+
93+
This makes it simpler for plugins to support old pytest versions.
94+
95+
96+
97+
Bug Fixes
98+
---------
99+
100+
- `#1895 <https://github.com/pytest-dev/pytest/issues/1895>`_: Fix bug where fixtures requested dynamically via ``request.getfixturevalue()`` might be teardown
101+
before the requesting fixture.
102+
103+
104+
- `#4851 <https://github.com/pytest-dev/pytest/issues/4851>`_: pytester unsets ``PYTEST_ADDOPTS`` now to not use outer options with ``testdir.runpytest()``.
105+
106+
107+
- `#4903 <https://github.com/pytest-dev/pytest/issues/4903>`_: Use the correct modified time for years after 2038 in rewritten ``.pyc`` files.
108+
109+
110+
- `#4928 <https://github.com/pytest-dev/pytest/issues/4928>`_: Fix line offsets with ``ScopeMismatch`` errors.
111+
112+
113+
- `#4957 <https://github.com/pytest-dev/pytest/issues/4957>`_: ``-p no:plugin`` is handled correctly for default (internal) plugins now, e.g. with ``-p no:capture``.
114+
115+
Previously they were loaded (imported) always, making e.g. the ``capfd`` fixture available.
116+
117+
118+
- `#4968 <https://github.com/pytest-dev/pytest/issues/4968>`_: The pdb ``quit`` command is handled properly when used after the ``debug`` command with `pdb++`_.
119+
120+
.. _pdb++: https://pypi.org/project/pdbpp/
121+
122+
123+
- `#4975 <https://github.com/pytest-dev/pytest/issues/4975>`_: Fix the interpretation of ``-qq`` option where it was being considered as ``-v`` instead.
124+
125+
126+
- `#4978 <https://github.com/pytest-dev/pytest/issues/4978>`_: ``outcomes.Exit`` is not swallowed in ``assertrepr_compare`` anymore.
127+
128+
129+
- `#4988 <https://github.com/pytest-dev/pytest/issues/4988>`_: Close logging's file handler explicitly when the session finishes.
130+
131+
132+
- `#5003 <https://github.com/pytest-dev/pytest/issues/5003>`_: Fix line offset with mark collection error (off by one).
133+
134+
135+
136+
Improved Documentation
137+
----------------------
138+
139+
- `#4974 <https://github.com/pytest-dev/pytest/issues/4974>`_: Update docs for ``pytest_cmdline_parse`` hook to note availability liminations
140+
141+
142+
143+
Trivial/Internal Changes
144+
------------------------
145+
146+
- `#4718 <https://github.com/pytest-dev/pytest/issues/4718>`_: ``pluggy>=0.9`` is now required.
147+
148+
149+
- `#4815 <https://github.com/pytest-dev/pytest/issues/4815>`_: ``funcsigs>=1.0`` is now required for Python 2.7.
150+
151+
152+
- `#4829 <https://github.com/pytest-dev/pytest/issues/4829>`_: Some left-over internal code related to ``yield`` tests has been removed.
153+
154+
155+
- `#4890 <https://github.com/pytest-dev/pytest/issues/4890>`_: Remove internally unused ``anypython`` fixture from the pytester plugin.
156+
157+
158+
- `#4912 <https://github.com/pytest-dev/pytest/issues/4912>`_: Remove deprecated Sphinx directive, ``add_description_unit()``,
159+
pin sphinx-removed-in to >= 0.2.0 to support Sphinx 2.0.
160+
161+
162+
- `#4913 <https://github.com/pytest-dev/pytest/issues/4913>`_: Fix pytest tests invocation with custom ``PYTHONPATH``.
163+
164+
165+
- `#4965 <https://github.com/pytest-dev/pytest/issues/4965>`_: New ``pytest_report_to_serializable`` and ``pytest_report_from_serializable`` **experimental** hooks.
166+
167+
These hooks will be used by ``pytest-xdist``, ``pytest-subtests``, and the replacement for
168+
resultlog to serialize and customize reports.
169+
170+
They are experimental, meaning that their details might change or even be removed
171+
completely in future patch releases without warning.
172+
173+
Feedback is welcome from plugin authors and users alike.
174+
175+
176+
- `#4987 <https://github.com/pytest-dev/pytest/issues/4987>`_: ``Collector.repr_failure`` respects the ``--tb`` option, but only defaults to ``short`` now (with ``auto``).
177+
178+
21179
pytest 4.3.1 (2019-03-11)
22180
=========================
23181

azure-pipelines.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ trigger:
33
- features
44

55
variables:
6-
PYTEST_ADDOPTS: "--junitxml=build/test-results/$(tox.env).xml"
6+
PYTEST_ADDOPTS: "--junitxml=build/test-results/$(tox.env).xml -vv"
77
python.needs_vc: False
88
python.exe: "python"
99
COVERAGE_FILE: "$(Build.Repository.LocalPath)/.coverage"

changelog/4903.bugfix.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

changelog/4912.trivial.rst

Lines changed: 0 additions & 2 deletions
This file was deleted.

changelog/4913.trivial.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

changelog/4928.bugfix.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

changelog/4974.doc.rst

Lines changed: 0 additions & 1 deletion
This file was deleted.

doc/en/announce/index.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Release announcements
66
:maxdepth: 2
77

88

9+
release-4.4.0
910
release-4.3.1
1011
release-4.3.0
1112
release-4.2.1

0 commit comments

Comments
 (0)