Workaround for unittests
Probably with the latest virtualenv [1] (which bundles setuptools), the unit tests started to fail with this error: File "/home/zuul/src/opendev.org/openstack/requirements/.tox/py310/lib/python3.10/site-packages/pkg_resources/_vendor/packaging/requirements.py", line 37, in __init__ raise InvalidRequirement(str(e)) from e pkg_resources.extern.packaging.requirements.InvalidRequirement: Expected end or semicolon (after version specifier) lesscpy>=0.9h It seems that the parser have become more strict and now it does not accept other than 0.9a, 0.9b (alpha, beta) releases when parsing constraints. This patch updates the global requirements test file to not break the parser. Also the test_match_without_python3_markers test caused the same error (with: withmarker>=1.5') and needed an update. [1] virtualenv (20.19.0) released at Tue, 07 Feb 2023 20:16:53 GMT Change-Id: Ia2ba3f38a83216abc430ed754bb7d8cbe8c564d3
This commit is contained in:
parent
0b5f5d0273
commit
28248c2d01
@ -22,7 +22,7 @@ Jinja2
|
||||
jsonrpclib
|
||||
jsonschema!=1.4.0,<2,>=1.0.0
|
||||
kazoo>=0.9,<=1.1
|
||||
lesscpy>=0.9h
|
||||
lesscpy>=0.10
|
||||
kombu>=2.4.8
|
||||
lockfile>=0.8
|
||||
lxml>=2.3
|
||||
@ -59,7 +59,7 @@ python-neutronclient>=2.2.3,<3
|
||||
python-novaclient>=2.12.0
|
||||
python-swiftclient>=1.2
|
||||
python-troveclient
|
||||
pytz>=2010h
|
||||
pytz>=2011b
|
||||
pyudev
|
||||
PyYAML>=3.1.0
|
||||
qpid-python
|
||||
|
@ -66,7 +66,7 @@ class TestIsReqInGlobalReqs(testtools.TestCase):
|
||||
specify e.g. a "python_version>'3" marker for packages.
|
||||
"""
|
||||
req = requirement.parse(textwrap.dedent("""
|
||||
withmarker>=1.5'
|
||||
withmarker>=1.5
|
||||
"""))['withmarker'][0][0]
|
||||
self.assertTrue(
|
||||
check._is_requirement_in_global_reqs(
|
||||
|
Loading…
Reference in New Issue
Block a user