mirror of
https://github.com/ansible-collections/community.general.git
synced 2025-10-24 13:04:00 -07:00
[PR #9496/43d5d6e2 backport][stable-10] remove code handling unsupported Python versions (#9502)
remove code handling unsupported Python versions (#9496)
* remove code handling unsupported Python versions
* drop unused import
* remove no longer needed ignore lines
(cherry picked from commit 43d5d6e2ce)
Co-authored-by: Alexei Znamensky <103110+russoz@users.noreply.github.com>
This commit is contained in:
parent
9afc096cd2
commit
f99508b307
6 changed files with 1 additions and 99 deletions
|
|
@ -10,16 +10,7 @@ __metaclass__ = type
|
|||
Compat module for Python2.7's unittest module
|
||||
'''
|
||||
|
||||
import sys
|
||||
|
||||
# Allow wildcard import because we really do want to import all of
|
||||
# unittests's symbols into this compat shim
|
||||
# pylint: disable=wildcard-import,unused-wildcard-import
|
||||
if sys.version_info < (2, 7):
|
||||
try:
|
||||
# Need unittest2 on python2.6
|
||||
from unittest2 import * # noqa: F401, pylint: disable=unused-import
|
||||
except ImportError:
|
||||
print('You need unittest2 installed on python2.6.x to run tests')
|
||||
else:
|
||||
from unittest import * # noqa: F401, pylint: disable=unused-import
|
||||
from unittest import * # noqa: F401, pylint: disable=unused-import
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue