Commit d6b0747e authored by Bryton Lacquement's avatar Bryton Lacquement 🚪

kvm/test: use correct test assertions

parent c02e52e2
...@@ -164,8 +164,8 @@ class TestAccessDefault(MonitorAccessMixin, InstanceTestCase): ...@@ -164,8 +164,8 @@ class TestAccessDefault(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
self.assertFalse('url-additional' in connection_parameter_dict) self.assertNotIn('url-additional', connection_parameter_dict)
@skipUnlessKvm @skipUnlessKvm
...@@ -188,7 +188,7 @@ class TestAccessDefaultAdditional(MonitorAccessMixin, InstanceTestCase): ...@@ -188,7 +188,7 @@ class TestAccessDefaultAdditional(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
result = requests.get( result = requests.get(
connection_parameter_dict['url-additional'], verify=False) connection_parameter_dict['url-additional'], verify=False)
...@@ -196,7 +196,7 @@ class TestAccessDefaultAdditional(MonitorAccessMixin, InstanceTestCase): ...@@ -196,7 +196,7 @@ class TestAccessDefaultAdditional(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
@skipUnlessKvm @skipUnlessKvm
...@@ -226,8 +226,8 @@ class TestAccessKvmCluster(MonitorAccessMixin, InstanceTestCase): ...@@ -226,8 +226,8 @@ class TestAccessKvmCluster(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
self.assertFalse('kvm0-url-additional' in connection_parameter_dict) self.assertNotIn('kvm0-url-additional', connection_parameter_dict)
@skipUnlessKvm @skipUnlessKvm
...@@ -260,7 +260,7 @@ class TestAccessKvmClusterAdditional(MonitorAccessMixin, InstanceTestCase): ...@@ -260,7 +260,7 @@ class TestAccessKvmClusterAdditional(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
result = requests.get( result = requests.get(
connection_parameter_dict['kvm0-url-additional'], verify=False) connection_parameter_dict['kvm0-url-additional'], verify=False)
...@@ -268,7 +268,7 @@ class TestAccessKvmClusterAdditional(MonitorAccessMixin, InstanceTestCase): ...@@ -268,7 +268,7 @@ class TestAccessKvmClusterAdditional(MonitorAccessMixin, InstanceTestCase):
httplib.OK, httplib.OK,
result.status_code result.status_code
) )
self.assertTrue('<title>noVNC</title>' in result.text) self.assertIn('<title>noVNC</title>', result.text)
@skipUnlessKvm @skipUnlessKvm
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment