requirements/openstack_requirements/tests
Tony Breeds 8bc094cf9e Ignore empty requirements/constraints when building lower-constraints
Some constraints files[1] contain valid data but we want to ignore them
when generating a combined lower-constraints.txt, rather than erroring
out:

 [tony@thor requirements]$ time .tox/venv/bin/build-lower-constraints ../*/lower-constraints.txt > tjmaxx.txt
 Traceback (most recent call last):
   File ".tox/venv/bin/build-lower-constraints", line 10, in <module>
     sys.exit(main())
   File "/home/tony/projects/openstack/openstack/requirements/openstack_requirements/cmds/build_lower_constraints.py", line 71, in main
     merged = list(merge_constraints_sets(constraints_sets))
   File "/home/tony/projects/openstack/openstack/requirements/openstack_requirements/cmds/build_lower_constraints.py", line 53, in merge_constraints_sets
     val = max((c[0] for c in constraints), key=get_requirements_version)
   File "/home/tony/projects/openstack/openstack/requirements/openstack_requirements/cmds/build_lower_constraints.py", line 43, in get_requirements_version
     raise ValueError('could not find version for {}'.format(req))
 ValueError: could not find version for Requirement(package='', location='', specifiers='', markers='', comment='# flake8==2.5.5', extras=frozenset())

Let's just ignore comments in those files.

[1] http://git.openstack.org/cgit/openstack/zaqar/tree/lower-constraints.txt#n28

Change-Id: Ie347ab273a1b239d9d264704482d3202dc4e4c74
2018-07-05 09:48:55 +10:00
..
files remove pycrypto 2018-06-28 09:56:14 -05:00
__init__.py Move tests into openstack_requirements. 2015-06-08 22:07:01 +12:00
common.py do not sync the blacklist to projects 2017-06-15 16:26:53 -04:00
test_build_lower_constraints.py Ignore empty requirements/constraints when building lower-constraints 2018-07-05 09:48:55 +10:00
test_check.py remove optimization for values unchanged from the branch 2018-04-10 11:18:16 -04:00
test_check_constraints.py Create check_constraints command 2017-05-19 15:03:15 -05:00
test_constraints.py Move data validation out of the unit tests and strengthen 2015-08-03 20:45:37 +00:00
test_edit_constraint.py Deal with underscores in names in edit-constraints 2015-09-17 10:12:11 +12:00
test_generate.py Add the concept of a version map for constraints generation 2016-10-06 16:22:18 +11:00
test_project.py add validation rules for lower constraints 2018-03-29 12:58:57 -04:00
test_requirement.py remove lower bounds from global requirements 2018-04-11 10:06:39 -04:00
test_update.py remove pycrypto 2018-06-28 09:56:14 -05:00
test_update_pbr.py Move commands into cmds subdir. 2015-06-29 15:27:25 +12:00
test_update_suffix.py Move commands into cmds subdir. 2015-06-29 15:27:25 +12:00