Remove usage of parameter enforce_type
Oslo.config deprecated parameter enforce_type and change its default value to True in Ifa552de0a994e40388cbc9f7dbaa55700ca276b0. Remove the usage of it to avoid DeprecationWarning: "Using the 'enforce_type' argument is deprecated in version '4.0' and will be removed in version '5.0': The argument enforce_type has changed its default value to True and then will be removed completely." Related--Bug: #1517839 Change-Id: I643e23f358e6a71f5361daa9cc2ef5ebdd44c792
This commit is contained in:
parent
66b8573bcc
commit
4eb280c930
@ -46,8 +46,7 @@ class SaharaClusterTestCase(test.ScenarioTestCase):
|
||||
"tenant_id": str(i),
|
||||
"credential": mock.MagicMock()})
|
||||
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark",
|
||||
enforce_type=True)
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark")
|
||||
|
||||
self.context.update({
|
||||
"config": {
|
||||
|
@ -30,10 +30,8 @@ class SaharaJobTestCase(test.ScenarioTestCase):
|
||||
super(SaharaJobTestCase, self).setUp()
|
||||
|
||||
self.context = test.get_test_context()
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark",
|
||||
enforce_type=True)
|
||||
CONF.set_override("sahara_job_check_interval", 0, "benchmark",
|
||||
enforce_type=True)
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark")
|
||||
CONF.set_override("sahara_job_check_interval", 0, "benchmark")
|
||||
|
||||
@mock.patch("%s.CreateLaunchJob._run_job_execution" % BASE)
|
||||
def test_create_launch_job_java(self, mock_run_job):
|
||||
|
@ -41,10 +41,8 @@ class SaharaScenarioTestCase(test.ScenarioTestCase):
|
||||
def setUp(self):
|
||||
super(SaharaScenarioTestCase, self).setUp()
|
||||
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark",
|
||||
enforce_type=True)
|
||||
CONF.set_override("sahara_job_check_interval", 0, "benchmark",
|
||||
enforce_type=True)
|
||||
CONF.set_override("sahara_cluster_check_interval", 0, "benchmark")
|
||||
CONF.set_override("sahara_job_check_interval", 0, "benchmark")
|
||||
|
||||
def test_list_node_group_templates(self):
|
||||
ngts = []
|
||||
|
Loading…
x
Reference in New Issue
Block a user