Skip to content

Commit

Permalink
Make tests compatible with pytest >= 7.3.
Browse files Browse the repository at this point in the history
Add support for Python 3.11 on the go.
  • Loading branch information
Michael Howitz authored and icemac committed Apr 13, 2023
1 parent ed7e093 commit 1f80547
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 11 deletions.
4 changes: 3 additions & 1 deletion CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ Change log for gocept.pytestlayer
8.2 (unreleased)
================

- Nothing changed yet.
- Make tests compatible with pytest >= 7.3.

- Add support for Python 3.11.


8.1 (2022-09-05)
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ The gocept.pytestlayer distribution
Integration of zope.testrunner-style test layers into the `pytest`_
framework

This package is compatible with Python versions 3.7 - 3.10 including
This package is compatible with Python versions 3.7 - 3.11 including
PyPy3.

.. _`pytest` : http://pytest.org
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,11 +52,11 @@
Operating System :: OS Independent
Programming Language :: Python
Programming Language :: Python :: 3
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Programming Language :: Python :: 3.11
Programming Language :: Python :: Implementation
Programming Language :: Python :: Implementation :: CPython
Programming Language :: Python :: Implementation :: PyPy
Expand Down
10 changes: 2 additions & 8 deletions src/gocept/pytestlayer/tests/test_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,13 @@
(r'\.py::(test_suite)::/', r'.py <- \1: /'),
(r'\.py::(test)', r'.py:NN: \1'),
(r'\.py::(.*Test)::', r'.py:NN: \1.'),
# Compatibility with pytest <= 3.1.2; can be removed if no longer supported
('1 items', '1 item'),
# Compatibility with pytest >= 7.3 which adds this line:
(r'configfile: pytest.ini', ''),
# With pytest >= 3.3.0 progress is reported after a test result.
# matches [NNN%], [ NN%] and [ N%]
(r'PASSED \[\s*\d{1,3}%\]', 'PASSED'),
# needed to omit all other loaded plugins.
(r'plugins:.*(gocept.pytestlayer).*\n', 'plugins: gocept.pytestlayer\n'),
# can be removed when python 2.7 / pypy2 is no longer supported
(r"""\
========================== deprecated python version ===========================
You are using Python 2.7.\d{1,2}, which will no longer be supported in pytest 5.0
For more information, please read:
https://docs.pytest.org/en/latest/py27-py34-deprecation.html""", ''),
]


Expand Down
1 change: 1 addition & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ envlist =
py38,
py39,
py310,
py311,
pypy3,
coverage,
minversion = 2.4
Expand Down

0 comments on commit 1f80547

Please sign in to comment.