Merge pull request #4019 from ThomasWaldmann/py37-1.1

Py37 (1.1 backport)
This commit is contained in:
TW 2018-08-09 08:38:00 +02:00 committed by GitHub
commit 105a23ac0e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 16 additions and 9 deletions

View File

@ -9,6 +9,10 @@ cache:
# note: use py 3.5.2, it has lzma support. 3.5(.0) on travis.org/trusty does not. # note: use py 3.5.2, it has lzma support. 3.5(.0) on travis.org/trusty does not.
matrix: matrix:
include: include:
- python: 3.4
os: linux
dist: trusty
env: TOXENV=flake8
- python: 3.4 - python: 3.4
os: linux os: linux
dist: trusty dist: trusty
@ -21,14 +25,10 @@ matrix:
os: linux os: linux
dist: trusty dist: trusty
env: TOXENV=py36 env: TOXENV=py36
- python: 3.4 - python: 3.7
os: linux os: linux
dist: trusty dist: xenial
env: TOXENV=flake8 env: TOXENV=py37
- python: "3.6-dev"
os: linux
dist: trusty
env: TOXENV=py36
- language: generic - language: generic
os: osx os: osx
osx_image: xcode8.3 osx_image: xcode8.3

View File

@ -830,6 +830,7 @@ setup(
'Programming Language :: Python :: 3.4', 'Programming Language :: Python :: 3.4',
'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.5',
'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
'Topic :: Security :: Cryptography', 'Topic :: Security :: Cryptography',
'Topic :: System :: Archiving :: Backup', 'Topic :: System :: Archiving :: Backup',
], ],

View File

@ -3673,6 +3673,12 @@ class TestCommonOptions:
@pytest.fixture @pytest.fixture
def subparsers(self, basic_parser): def subparsers(self, basic_parser):
if sys.version_info >= (3, 7):
# py37 pre-release defaults to unwanted required=True, in 3.7.0+ it was fixed to =False
return basic_parser.add_subparsers(title='required arguments', metavar='<command>', required=False)
else:
# py36 does not support required=... argument (but behaves like required=False).
# note: use below call for 3.6 and 3.7 when there are no alphas/betas/RCs of 3.7.0 around any more.
return basic_parser.add_subparsers(title='required arguments', metavar='<command>') return basic_parser.add_subparsers(title='required arguments', metavar='<command>')
@pytest.fixture @pytest.fixture

View File

@ -2,7 +2,7 @@
# fakeroot -u tox --recreate # fakeroot -u tox --recreate
[tox] [tox]
envlist = py{34,35,36},flake8 envlist = py{34,35,36,37},flake8
[testenv] [testenv]
deps = deps =