Skip secgroup rules invalid id tests until bug 1182384 is fixed
There are some existing reviews which try to deal with bug 1182384:
nova: https://review.openstack.org/#/c/35285/
tempest: https://review.openstack.org/#/c/29899/
There is also a mailing list discussion about this (see the link in the
bug report).
Until there is consensus on how to fix this, skip the compute tests if
neutron is available.
Change-Id: I3f0d21c23661f556354c321476ba559d4925dccd
diff --git a/tempest/api/compute/security_groups/test_security_group_rules.py b/tempest/api/compute/security_groups/test_security_group_rules.py
index 6a32b64..19adfa6 100644
--- a/tempest/api/compute/security_groups/test_security_group_rules.py
+++ b/tempest/api/compute/security_groups/test_security_group_rules.py
@@ -15,8 +15,11 @@
# License for the specific language governing permissions and limitations
# under the License.
+import testtools
+
from tempest.api.compute import base
from tempest.common.utils.data_utils import rand_name
+from tempest import config
from tempest import exceptions
from tempest.test import attr
@@ -91,6 +94,8 @@
self.addCleanup(self.client.delete_security_group_rule, rule['id'])
self.assertEqual(200, resp.status)
+ @testtools.skipIf(config.TempestConfig().service_available.neutron,
+ "Skipped until the Bug #1182384 is resolved")
@attr(type=['negative', 'gate'])
def test_security_group_rules_create_with_invalid_id(self):
# Negative test: Creation of Security Group rule should FAIL
@@ -181,6 +186,8 @@
self.client.create_security_group_rule,
secgroup_id, ip_protocol, from_port, to_port)
+ @testtools.skipIf(config.TempestConfig().service_available.neutron,
+ "Skipped until the Bug #1182384 is resolved")
@attr(type=['negative', 'gate'])
def test_security_group_rules_delete_with_invalid_id(self):
# Negative test: Deletion of Security Group rule should be FAIL