summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2017-10-27 10:01:10 -0400
committerGitHub <noreply@github.com>2017-10-27 10:01:10 -0400
commitfe39989ce5358c5e4311a61c359445668a17dd9b (patch)
treebda7d2112d8f1a94cfbd13fb3d33108bb79ceb94
parent2c970db6066919e1120dfadc259cf7f433290445 (diff)
parent59735f374dd0085e54eed110c4979a1bff2ed53e (diff)
downloadpytest-runner-fe39989ce5358c5e4311a61c359445668a17dd9b.tar.gz
Merge pull request #34 from pytest-dev/feature/drop-py263.0
Drop support for Python 2.6
-rw-r--r--CHANGES.rst5
-rw-r--r--setup.py7
-rw-r--r--tests/test_ptr.py16
3 files changed, 7 insertions, 21 deletions
diff --git a/CHANGES.rst b/CHANGES.rst
index 2cf9ed3..0e59e0a 100644
--- a/CHANGES.rst
+++ b/CHANGES.rst
@@ -1,3 +1,8 @@
+3.0
+~~~
+
+* Dropped support for Python 2.6 and 3.1.
+
2.12.2
~~~~~~
diff --git a/setup.py b/setup.py
index 8ef7332..b41096f 100644
--- a/setup.py
+++ b/setup.py
@@ -30,7 +30,7 @@ params = dict(
else []
),
py_modules=['ptr'],
- python_requires='>=2.6',
+ python_requires='>=2.7,!=3.0,!=3.1',
install_requires=[
],
extras_require={
@@ -40,10 +40,6 @@ params = dict(
'collective.checkdocs',
'pytest-virtualenv',
],
- 'testing:python_version=="2.6"': [
- # undeclared dependency of pytest-virtualenv
- 'importlib',
- ],
'docs': [
'sphinx',
'jaraco.packaging>=3.2',
@@ -57,7 +53,6 @@ params = dict(
"Development Status :: 5 - Production/Stable",
"Intended Audience :: Developers",
"License :: OSI Approved :: MIT License",
- "Programming Language :: Python :: 2.6",
"Programming Language :: Python :: 2.7",
"Programming Language :: Python :: 3",
"Framework :: Pytest",
diff --git a/tests/test_ptr.py b/tests/test_ptr.py
index 521c59a..fcbf0c5 100644
--- a/tests/test_ptr.py
+++ b/tests/test_ptr.py
@@ -1,6 +1,5 @@
from __future__ import unicode_literals
-import contextlib
import io
import os
import shutil
@@ -17,26 +16,13 @@ def DALS(s):
return textwrap.dedent(s).lstrip()
-def _tarfile_open_ex(*args, **kwargs):
- """
- Extend result as a context manager.
- """
- return contextlib.closing(tarfile.open(*args, **kwargs))
-
-
-if sys.version_info[:2] < (2, 7) or (3, 0) <= sys.version_info[:2] < (3, 2):
- tarfile_open = _tarfile_open_ex
-else:
- tarfile_open = tarfile.open
-
-
def make_sdist(dist_path, files):
"""
Create a simple sdist tarball at dist_path, containing the files
listed in ``files`` as ``(filename, content)`` tuples.
"""
- with tarfile_open(dist_path, 'w:gz') as dist:
+ with tarfile.open(dist_path, 'w:gz') as dist:
for filename, content in files:
file_bytes = io.BytesIO(content.encode('utf-8'))
file_info = tarfile.TarInfo(name=filename)