mirror of
https://github.com/ansible-collections/community.general.git
synced 2026-05-08 06:12:51 +00:00
Add Python 3.7 to CI unit test matrix. (#34680)
* Add Python 3.7 to CI unit test matrix. * Fix `os.errno` reference to be `errno`. * Update test_aci unit test for Python 3.7.
This commit is contained in:
@@ -14,6 +14,7 @@ matrix:
|
|||||||
- env: T=units/2.7
|
- env: T=units/2.7
|
||||||
- env: T=units/3.5
|
- env: T=units/3.5
|
||||||
- env: T=units/3.6
|
- env: T=units/3.6
|
||||||
|
- env: T=units/3.7
|
||||||
|
|
||||||
- env: T=windows/1
|
- env: T=windows/1
|
||||||
- env: T=windows/2
|
- env: T=windows/2
|
||||||
|
|||||||
@@ -229,6 +229,8 @@ class AciRest(unittest.TestCase):
|
|||||||
error_text = to_native(u"Unable to parse output as XML, see 'raw' output. None (line 0)", errors='surrogate_or_strict')
|
error_text = to_native(u"Unable to parse output as XML, see 'raw' output. None (line 0)", errors='surrogate_or_strict')
|
||||||
elif PY2:
|
elif PY2:
|
||||||
error_text = "Unable to parse output as XML, see 'raw' output. Document is empty, line 1, column 1 (line 1)"
|
error_text = "Unable to parse output as XML, see 'raw' output. Document is empty, line 1, column 1 (line 1)"
|
||||||
|
elif sys.version_info >= (3, 7):
|
||||||
|
error_text = to_native(u"Unable to parse output as XML, see 'raw' output. None (line 0)", errors='surrogate_or_strict')
|
||||||
else:
|
else:
|
||||||
error_text = "Unable to parse output as XML, see 'raw' output. Document is empty, line 1, column 1 (<string>, line 1)"
|
error_text = "Unable to parse output as XML, see 'raw' output. Document is empty, line 1, column 1 (<string>, line 1)"
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,4 @@
|
|||||||
|
import errno
|
||||||
import os
|
import os
|
||||||
import time
|
import time
|
||||||
import mock
|
import mock
|
||||||
@@ -64,7 +65,7 @@ def placeboify(request, monkeypatch):
|
|||||||
# make sure the directory for placebo test recordings is available
|
# make sure the directory for placebo test recordings is available
|
||||||
os.makedirs(recordings_path)
|
os.makedirs(recordings_path)
|
||||||
except OSError as e:
|
except OSError as e:
|
||||||
if e.errno != os.errno.EEXIST:
|
if e.errno != errno.EEXIST:
|
||||||
raise
|
raise
|
||||||
|
|
||||||
pill = placebo.attach(session, data_path=recordings_path)
|
pill = placebo.attach(session, data_path=recordings_path)
|
||||||
|
|||||||
Reference in New Issue
Block a user