diff options
author | Zuul <zuul@review.opendev.org> | 2020-05-25 13:20:17 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2020-05-25 13:20:17 +0000 |
commit | ad1eb1be0ac038fbf64ab42138ab6f1662a699e0 (patch) | |
tree | 8e9751ce47594cd1b56ab3aea9baa3a3edfd03b3 | |
parent | 4801a918229b8b2b5b043abcbad6fb47484aef04 (diff) | |
parent | 824241680182da3650499256b071ad0cdb87a1c8 (diff) | |
download | oslo-config-ad1eb1be0ac038fbf64ab42138ab6f1662a699e0.tar.gz |
Merge "Raise hacking minimum to 3.0.1"
-rw-r--r-- | lower-constraints.txt | 1 | ||||
-rw-r--r-- | oslo_config/generator.py | 6 | ||||
-rw-r--r-- | oslo_config/tests/test_generator.py | 12 | ||||
-rw-r--r-- | test-requirements.txt | 3 |
4 files changed, 10 insertions, 12 deletions
diff --git a/lower-constraints.txt b/lower-constraints.txt index 91eafb6..aca80eb 100644 --- a/lower-constraints.txt +++ b/lower-constraints.txt @@ -11,7 +11,6 @@ fixtures==3.0.0 flake8==2.5.5 gitdb==0.6.4 GitPython==1.0.1 -hacking==2.0.0 imagesize==0.7.1 iso8601==0.1.11 Jinja2==2.10 diff --git a/oslo_config/generator.py b/oslo_config/generator.py index 1f509ef..8e8dcfe 100644 --- a/oslo_config/generator.py +++ b/oslo_config/generator.py @@ -356,12 +356,12 @@ class _OptFormatter(object): """ self.output_file.write(s) - def writelines(self, l): + def writelines(self, lines): """Write an arbitrary sequence of strings to the output file. - :param l: a list of arbitrary strings + :param lines: a list of arbitrary strings """ - self.output_file.writelines(l) + self.output_file.writelines(lines) def _cleanup_opts(read_opts): diff --git a/oslo_config/tests/test_generator.py b/oslo_config/tests/test_generator.py index 9ddb56f..7cb354e 100644 --- a/oslo_config/tests/test_generator.py +++ b/oslo_config/tests/test_generator.py @@ -437,7 +437,7 @@ class GeneratorTestCase(base.BaseTestCase): ''')), ('choices_opt', dict(opts=[('test', [(None, [opts['choices_opt']])])], - expected='''[DEFAULT] + expected="""[DEFAULT] # # From test @@ -451,7 +451,7 @@ class GeneratorTestCase(base.BaseTestCase): # b - <No description provided> # c - <No description provided> #choices_opt = a -''')), +""")), ('deprecated opt without deprecated group', dict(opts=[('test', [(groups['foo'], @@ -852,13 +852,13 @@ class GeneratorTestCase(base.BaseTestCase): # string with bad default (string value) #string_type_with_bad_default = 4096 ''')), - ('str_opt_str_group', + ('str_opt_str_group', dict(opts=[('test', [('foo', [opts['str_opt']]), (groups['foo'], [opts['int_opt']])]), ('foo', [('foo', - [opts['bool_opt']])])], + [opts['bool_opt']])])], expected='''[DEFAULT] @@ -888,7 +888,7 @@ class GeneratorTestCase(base.BaseTestCase): # Maximum value: 20 #int_opt = 10 ''')), - ('opt_str_opt_group', + ('opt_str_opt_group', dict(opts=[('test', [(groups['foo'], [opts['int_opt']]), ('foo', @@ -924,7 +924,7 @@ class GeneratorTestCase(base.BaseTestCase): # a string (string value) #str_opt = foo bar ''')), - ('opt_with_DeprecatedOpt', + ('opt_with_DeprecatedOpt', dict(opts=[('test', [(None, [opts['opt_with_DeprecatedOpt']])])], expected='''[DEFAULT] diff --git a/test-requirements.txt b/test-requirements.txt index c6386f9..985a9da 100644 --- a/test-requirements.txt +++ b/test-requirements.txt @@ -2,8 +2,7 @@ # of appearance. Changing the order has an impact on the overall integration # process, which may cause wedges in the gate later. -flake8>=3.6.0,<3.8.0 # MIT -hacking>=2.0.0,<2.1.0 # Apache-2.0 +hacking>=3.0.1,<3.1.0 # Apache-2.0 fixtures>=3.0.0 # Apache-2.0/BSD testscenarios>=0.4 # Apache-2.0/BSD |