Remove usage of TestCase.skip() method

It is deprecated since version 1.9.0 of testtools.
Instead of this deprecated method skipTest() is now used.

Change-Id: I7b6bbdbf43e7f428d5b3873a07fba7e6d629fa82
This commit is contained in:
Sławek Kapłoński
2018-03-21 22:14:53 +01:00
parent 2f39aa911c
commit 275d406511
3 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -236,8 +236,8 @@ def skip_if_ovs_older_than(ovs_version):
current_ovs_version = version.StrictVersion(
ovs.config['ovs_version'])
if current_ovs_version < version.StrictVersion(ovs_version):
test.skip("This test requires OVS version %s or higher." %
ovs_version)
test.skipTest("This test requires OVS version %s or higher." %
ovs_version)
return f(test)
return check_ovs_and_skip
return skip_if_bad_ovs
+1 -1
View File
@@ -107,7 +107,7 @@ class TestDhcpAgentNoHA(BaseDhcpAgentTest):
# testing matters.
# TODO(jlibosva) revisit when ip_lib supports nested namespaces
if self.environment.hosts[0].dhcp_agent.namespace is not None:
self.skip("ip_lib doesn't support nested namespaces")
self.skipTest("ip_lib doesn't support nested namespaces")
self.vm.block_until_dhcp_config_done()
+1 -1
View File
@@ -323,7 +323,7 @@ class OpportunisticDBTestMixin(object):
if not hasattr(self, 'db'):
msg = "backend '%s' unavailable" % self.DRIVER
if self.SKIP_ON_UNAVAILABLE_DB:
self.skip(msg)
self.skipTest(msg)
else:
self.fail(msg)