Test: make enforce_type=True in CONF.set_override and fix error
Each config option has limitation for type and value. We make enforce_type=True to check whether we pass wrong type. Also fixes a type error issue in test_db_manager.py. Change-Id: I6e111e21588525d32b05eeba75b06583d4e605ed Related-Bug: #1517839
This commit is contained in:
committed by
Taylor Peoples
parent
4662f248b3
commit
473cee8ad3
@@ -195,7 +195,8 @@ class TestListAuditTemplate(api_base.FunctionalTest):
|
||||
self.assertIn(next_marker, response['next'])
|
||||
|
||||
def test_collection_links_default_limit(self):
|
||||
cfg.CONF.set_override('max_limit', 3, 'api')
|
||||
cfg.CONF.set_override('max_limit', 3, 'api',
|
||||
enforce_type=True)
|
||||
for id_ in range(5):
|
||||
obj_utils.create_test_audit_template(
|
||||
self.context, id=id_, uuid=utils.generate_uuid(),
|
||||
|
||||
Reference in New Issue
Block a user