Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release 5.2.0 #5885

Merged
merged 2 commits into from
Sep 29, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 39 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,45 @@ with advance notice in the **Deprecations** section of releases.

.. towncrier release notes start

pytest 5.2.0 (2019-09-28)
=========================

Deprecations
------------

- `#1682 <https://github.com/pytest-dev/pytest/issues/1682>`_: Passing arguments to pytest.fixture() as positional arguments is deprecated - pass them
as a keyword argument instead.



Features
--------

- `#1682 <https://github.com/pytest-dev/pytest/issues/1682>`_: The ``scope`` parameter of ``@pytest.fixture`` can now be a callable that receives
the fixture name and the ``config`` object as keyword-only parameters.
See `the docs <https://docs.pytest.org/en/fixture.html#dynamic-scope>`__ for more information.


- `#5764 <https://github.com/pytest-dev/pytest/issues/5764>`_: New behavior of the ``--pastebin`` option: failures to connect to the pastebin server are reported, without failing the pytest run



Bug Fixes
---------

- `#5806 <https://github.com/pytest-dev/pytest/issues/5806>`_: Fix "lexer" being used when uploading to bpaste.net from ``--pastebin`` to "text".


- `#5884 <https://github.com/pytest-dev/pytest/issues/5884>`_: Fix ``--setup-only`` and ``--setup-show`` for custom pytest items.



Trivial/Internal Changes
------------------------

- `#5056 <https://github.com/pytest-dev/pytest/issues/5056>`_: The HelpFormatter uses ``py.io.get_terminal_width`` for better width detection.


pytest 5.1.3 (2019-09-18)
=========================

Expand Down
2 changes: 0 additions & 2 deletions changelog/1682.deprecation.rst

This file was deleted.

3 changes: 0 additions & 3 deletions changelog/1682.feature.rst

This file was deleted.

1 change: 0 additions & 1 deletion changelog/5056.trivial.rst

This file was deleted.

1 change: 0 additions & 1 deletion changelog/5764.feature.rst

This file was deleted.

1 change: 0 additions & 1 deletion changelog/5806.bugfix.rst

This file was deleted.

1 change: 0 additions & 1 deletion changelog/5884.bugfix.rst

This file was deleted.

1 change: 1 addition & 0 deletions doc/en/announce/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ Release announcements
:maxdepth: 2


release-5.2.0
release-5.1.3
release-5.1.2
release-5.1.1
Expand Down
36 changes: 36 additions & 0 deletions doc/en/announce/release-5.2.0.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
pytest-5.2.0
=======================================

The pytest team is proud to announce the 5.2.0 release!

pytest is a mature Python testing tool with more than a 2000 tests
against itself, passing on many different interpreters and platforms.

This release contains a number of bugs fixes and improvements, so users are encouraged
to take a look at the CHANGELOG:

https://docs.pytest.org/en/latest/changelog.html

For complete documentation, please visit:

https://docs.pytest.org/en/latest/

As usual, you can upgrade from pypi via:

pip install -U pytest

Thanks to all who contributed to this release, among them:

* Andrzej Klajnert
* Anthony Sottile
* Bruno Oliveira
* Daniel Hahler
* James Cooke
* Michael Goerz
* Ran Benita
* Tomáš Chvátal
* aklajnert


Happy testing,
The Pytest Development Team
4 changes: 2 additions & 2 deletions doc/en/example/parametrize.rst
Original file line number Diff line number Diff line change
Expand Up @@ -475,10 +475,10 @@ Running it results in some skips if we don't have all the python interpreters in
.. code-block:: pytest

. $ pytest -rs -q multipython.py
ssssssssssss...ssssssssssss [100%]
ssssssssssssssssssssssss... [100%]
========================= short test summary info ==========================
SKIPPED [12] $REGENDOC_TMPDIR/CWD/multipython.py:30: 'python3.5' not found
SKIPPED [12] $REGENDOC_TMPDIR/CWD/multipython.py:30: 'python3.7' not found
SKIPPED [12] $REGENDOC_TMPDIR/CWD/multipython.py:30: 'python3.6' not found
3 passed, 24 skipped in 0.12s

Indirect parametrization of optional implementations/imports
Expand Down
4 changes: 2 additions & 2 deletions doc/en/example/reportingdemo.rst
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,7 @@ Here is a nice run of several failures and how ``pytest`` presents things:
items = [1, 2, 3]
print("items is {!r}".format(items))
> a, b = items.pop()
E TypeError: 'int' object is not iterable
E TypeError: cannot unpack non-iterable int object

failure_demo.py:181: TypeError
--------------------------- Captured stdout call ---------------------------
Expand Down Expand Up @@ -516,7 +516,7 @@ Here is a nice run of several failures and how ``pytest`` presents things:
def test_z2_type_error(self):
items = 3
> a, b = items
E TypeError: 'int' object is not iterable
E TypeError: cannot unpack non-iterable int object

failure_demo.py:222: TypeError
______________________ TestMoreErrors.test_startswith ______________________
Expand Down
2 changes: 1 addition & 1 deletion doc/en/example/simple.rst
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ Now we can profile which test functions execute the slowest:

========================= slowest 3 test durations =========================
0.30s call test_some_are_slow.py::test_funcslow2
0.21s call test_some_are_slow.py::test_funcslow1
0.20s call test_some_are_slow.py::test_funcslow1
0.10s call test_some_are_slow.py::test_funcfast
============================ 3 passed in 0.12s =============================

Expand Down
2 changes: 1 addition & 1 deletion doc/en/getting-started.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Install ``pytest``
.. code-block:: bash

$ pytest --version
This is pytest version 5.x.y, imported from $PYTHON_PREFIX/lib/python3.6/site-packages/pytest.py
This is pytest version 5.x.y, imported from $PYTHON_PREFIX/lib/python3.7/site-packages/pytest.py

.. _`simpletest`:

Expand Down
6 changes: 3 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ commands =
[testenv:regen]
changedir = doc/en
skipsdist = True
basepython = python3.6
basepython = python3
deps =
sphinx
PyYAML
Expand All @@ -103,7 +103,7 @@ commands =

[testenv:release]
decription = do a release, required posarg of the version number
basepython = python3.6
basepython = python3
usedevelop = True
passenv = *
deps =
Expand All @@ -116,7 +116,7 @@ commands = python scripts/release.py {posargs}

[testenv:publish_gh_release_notes]
description = create GitHub release after deployment
basepython = python3.6
basepython = python3
usedevelop = True
passenv = GH_RELEASE_NOTES_TOKEN TRAVIS_TAG TRAVIS_REPO_SLUG
deps =
Expand Down