Skip to content

Commit dd45f8b

Browse files
Merge pull request #2822 from RonnyPfannschmidt/nomore-py26
Nomore py26
2 parents 059455b + c486598 commit dd45f8b

File tree

6 files changed

+13
-40
lines changed

6 files changed

+13
-40
lines changed

.travis.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,10 +31,6 @@ env:
3131

3232
matrix:
3333
include:
34-
- env: TOXENV=py26
35-
python: '2.6'
36-
- env: TOXENV=py33
37-
python: '3.3'
3834
- env: TOXENV=pypy
3935
python: 'pypy-5.4'
4036
- env: TOXENV=py35

_pytest/compat.py

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
from __future__ import absolute_import, division, print_function
55
import sys
66
import inspect
7-
import types
87
import re
98
import functools
109
import codecs
@@ -120,16 +119,6 @@ def getfuncargnames(function, startindex=None, cls=None):
120119
return tuple(argnames[startindex:])
121120

122121

123-
if sys.version_info[:2] == (2, 6):
124-
def isclass(object):
125-
""" Return true if the object is a class. Overrides inspect.isclass for
126-
python 2.6 because it will return True for objects which always return
127-
something on __getattr__ calls (see #1035).
128-
Backport of https://hg.python.org/cpython/rev/35bf8f7a8edc
129-
"""
130-
return isinstance(object, (type, types.ClassType))
131-
132-
133122
if _PY3:
134123
imap = map
135124
izip = zip
@@ -230,10 +219,7 @@ def getimfunc(func):
230219
try:
231220
return func.__func__
232221
except AttributeError:
233-
try:
234-
return func.im_func
235-
except AttributeError:
236-
return func
222+
return func
237223

238224

239225
def safe_getattr(object, name, default):

appveyor.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,7 @@ environment:
1010
- TOXENV: "coveralls"
1111
# note: please use "tox --listenvs" to populate the build matrix below
1212
- TOXENV: "linting"
13-
- TOXENV: "py26"
1413
- TOXENV: "py27"
15-
- TOXENV: "py33"
1614
- TOXENV: "py34"
1715
- TOXENV: "py35"
1816
- TOXENV: "py36"

changelog/2812.removal

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
remove support for the eol python versions 2.6 and 3.3

setup.py

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
'Topic :: Utilities',
1717
] + [
1818
('Programming Language :: Python :: %s' % x)
19-
for x in '2 2.6 2.7 3 3.3 3.4 3.5 3.6'.split()
19+
for x in '2.7 3 3.4 3.5 3.6'.split()
2020
]
2121

2222
with open('README.rst') as fd:
@@ -50,12 +50,8 @@ def main():
5050
install_requires.append('pluggy>=0.4.0,<0.5')
5151
extras_require = {}
5252
if has_environment_marker_support():
53-
extras_require[':python_version=="2.6"'] = ['argparse', 'ordereddict']
5453
extras_require[':sys_platform=="win32"'] = ['colorama']
5554
else:
56-
if sys.version_info < (2, 7):
57-
install_requires.append('argparse')
58-
install_requires.append('ordereddict')
5955
if sys.platform == 'win32':
6056
install_requires.append('colorama')
6157

@@ -69,9 +65,11 @@ def main():
6965
url='http://pytest.org',
7066
license='MIT license',
7167
platforms=['unix', 'linux', 'osx', 'cygwin', 'win32'],
72-
author='Holger Krekel, Bruno Oliveira, Ronny Pfannschmidt, Floris Bruynooghe, Brianna Laugher, Florian Bruhin and others',
73-
entry_points={'console_scripts':
74-
['pytest=pytest:main', 'py.test=pytest:main']},
68+
author=(
69+
'Holger Krekel, Bruno Oliveira, Ronny Pfannschmidt, '
70+
'Floris Bruynooghe, Brianna Laugher, Florian Bruhin and others'),
71+
entry_points={'console_scripts': [
72+
'pytest=pytest:main', 'py.test=pytest:main']},
7573
classifiers=classifiers,
7674
keywords="test unittest",
7775
cmdclass={'test': PyTest},
@@ -87,10 +85,13 @@ def main():
8785

8886
class PyTest(Command):
8987
user_options = []
88+
9089
def initialize_options(self):
9190
pass
91+
9292
def finalize_options(self):
9393
pass
94+
9495
def run(self):
9596
import subprocess
9697
PPATH = [x for x in os.environ.get('PYTHONPATH', '').split(':') if x]

tox.ini

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,7 @@ distshare = {homedir}/.tox/distshare
44
# make sure to update environment list in travis.yml and appveyor.yml
55
envlist =
66
linting
7-
py26
87
py27
9-
py33
108
py34
119
py35
1210
py36
@@ -27,13 +25,6 @@ deps =
2725
mock
2826
requests
2927

30-
[testenv:py26]
31-
# pinning mock to last supported version for python 2.6
32-
deps =
33-
hypothesis<3.0
34-
nose
35-
mock<1.1
36-
3728
[testenv:py27-subprocess]
3829
changedir = .
3930
deps =
@@ -54,7 +45,7 @@ deps =
5445
pygments
5546
restructuredtext_lint
5647
commands =
57-
flake8 pytest.py _pytest testing
48+
flake8 pytest.py _pytest testing setup.py pytest.py
5849
{envpython} scripts/check-rst.py
5950

6051
[testenv:py27-xdist]
@@ -174,7 +165,7 @@ usedevelop = True
174165
deps =
175166
autopep8
176167
commands =
177-
autopep8 --in-place -r --max-line-length=120 --exclude=test_source_multiline_block.py _pytest testing
168+
autopep8 --in-place -r --max-line-length=120 --exclude=test_source_multiline_block.py _pytest testing setup.py pytest.py
178169

179170
[testenv:jython]
180171
changedir = testing

0 commit comments

Comments
 (0)