Skip to content

Commit 45c9ab1

Browse files
authored
Increase pytest requirment to >=5.0.0 (#92)
1 parent 1a35f94 commit 45c9ab1

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

README.rst

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,11 @@ session using ```--pdb``` or similar.
218218
Changelog
219219
=========
220220

221+
2.1.0
222+
-----
223+
224+
- Increase pytest requirement to >=5.0.0. Thanks Dominic Davis-Foster.
225+
221226
2.0.0
222227
-----
223228

pytest_timeout.py

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@
1313
import threading
1414
import traceback
1515
from collections import namedtuple
16-
from distutils.version import LooseVersion
1716

1817
import py
1918
import pytest
@@ -394,12 +393,8 @@ def timeout_timer(item, timeout):
394393
try:
395394
capman = item.config.pluginmanager.getplugin("capturemanager")
396395
if capman:
397-
pytest_version = LooseVersion(pytest.__version__)
398-
if pytest_version >= LooseVersion("3.7.3"):
399-
capman.suspend_global_capture(item)
400-
stdout, stderr = capman.read_global_capture()
401-
else:
402-
stdout, stderr = capman.suspend_global_capture(item)
396+
capman.suspend_global_capture(item)
397+
stdout, stderr = capman.read_global_capture()
403398
else:
404399
stdout, stderr = None, None
405400
write_title("Timeout", sep="+")

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
license="MIT",
1717
py_modules=["pytest_timeout"],
1818
entry_points={"pytest11": ["timeout = pytest_timeout"]},
19-
install_requires=["pytest>=3.6.0"],
19+
install_requires=["pytest>=5.0.0"],
2020
classifiers=[
2121
"Development Status :: 5 - Production/Stable",
2222
"Environment :: Console",

0 commit comments

Comments
 (0)