Code cleanup in advance of flake8.
Change-Id: Ia2b463fdf3092aa72147eeda41faad4733fddd46
This commit is contained in:
parent
c305a45892
commit
1a0b7b0a64
@ -61,5 +61,5 @@ class BaremetalExtensionTest(utils.TestCase):
|
||||
cs.assert_called('POST', '/os-baremetal-nodes/1/action')
|
||||
|
||||
def test_node_list_interfaces(self):
|
||||
il = cs.baremetal.list_interfaces(1)
|
||||
cs.baremetal.list_interfaces(1)
|
||||
cs.assert_called('GET', '/os-baremetal-nodes/1')
|
||||
|
@ -36,7 +36,7 @@ class TenantNetworkExtensionTests(utils.TestCase):
|
||||
self.assertTrue(len(nets) > 0)
|
||||
|
||||
def test_get_tenant_network(self):
|
||||
net = cs.tenant_networks.get(1)
|
||||
cs.tenant_networks.get(1)
|
||||
cs.assert_called('GET', '/os-tenant-networks/1')
|
||||
|
||||
def test_create_tenant_networks(self):
|
||||
|
@ -20,7 +20,7 @@ def assert_has_keys(dict, required=[], optional=[]):
|
||||
for k in required:
|
||||
assert_in(k, keys, "required key %s missing from %s" % (k, dict))
|
||||
allowed_keys = set(required) | set(optional)
|
||||
extra_keys = set(keys).difference(set(required + optional))
|
||||
extra_keys = set(keys).difference(allowed_keys)
|
||||
if extra_keys:
|
||||
fail("found unexpected keys: %s" % list(extra_keys))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user