Skip to content

Commit

Permalink
remove check for python versions less than 3.5
Browse files Browse the repository at this point in the history
  • Loading branch information
dtkav committed Dec 12, 2019
1 parent d0efe57 commit 1b04d30
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 19 deletions.
15 changes: 7 additions & 8 deletions connexion/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,13 @@ def _required_lib(exec_info, *args, **kwargs):
App = FlaskApp
Api = FlaskApi

if sys.version_info >= (3, 5, 3): # pragma: no cover
try:
from .apis.aiohttp_api import AioHttpApi
from .apps.aiohttp_app import AioHttpApp
except ImportError: # pragma: no cover
_aiohttp_not_installed_error = not_installed_error()
AioHttpApi = _aiohttp_not_installed_error
AioHttpApp = _aiohttp_not_installed_error
try:
from .apis.aiohttp_api import AioHttpApi
from .apps.aiohttp_app import AioHttpApp
except ImportError: # pragma: no cover
_aiohttp_not_installed_error = not_installed_error()
AioHttpApi = _aiohttp_not_installed_error
AioHttpApp = _aiohttp_not_installed_error

# This version is replaced during release process.
__version__ = '2018.0.dev1'
15 changes: 4 additions & 11 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,9 @@ def read_version(package):
swagger_ui_require
]

if sys.version_info >= (3, 5, 3):
tests_require.extend(aiohttp_require)
tests_require.append('pytest-aiohttp')
tests_require.append('aiohttp-remotes')
tests_require.extend(aiohttp_require)
tests_require.append('pytest-aiohttp')
tests_require.append('aiohttp-remotes')


class PyTest(TestCommand):
Expand All @@ -61,13 +60,7 @@ def initialize_options(self):
TestCommand.initialize_options(self)
self.cov = None
self.pytest_args = ['--cov', 'connexion', '--cov-report', 'term-missing', '-v']

if sys.version_info < (3, 5, 3):
self.pytest_args.append('--cov-config=py2-coveragerc')
self.pytest_args.append('--ignore=tests/aiohttp')
else:
self.pytest_args.append('--cov-config=py3-coveragerc')

self.pytest_args.append('--cov-config=py3-coveragerc')
self.cov_html = False

def finalize_options(self):
Expand Down

0 comments on commit 1b04d30

Please sign in to comment.