tempest: test: test_create_duplicate_security_group_rule_fails failed while checking negative scenario

Bug #1710031 reported by shajuvk
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Juniper Openstack
Status tracked in Trunk
R3.2
Fix Committed
Medium
Sachin Bansal
R4.0
Fix Committed
Medium
Sachin Bansal
Trunk
Fix Committed
Medium
Sachin Bansal

Bug Description

test: test_create_duplicate_security_group_rule_fails

Duplicate security group creation should throw conflict error but Api not responding with an error.

194 import pdb; pdb.set_trace()
195 # Try creating the same security group rule, it should fail
196 -> self.assertRaises(
197 lib_exc.Conflict,
198 self.security_group_rules_client.create_security_group_rule,
199 security_group_id=body['security_group']['id'],
200 protocol='tcp', direction='ingress', ethertype=self.ethertype,
201 port_range_min=min_port, port_range_max=max_port)
(Pdb) n
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(197)test_create_duplicate_security_group_rule_fails()
-> lib_exc.Conflict,
(Pdb)
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(198)test_create_duplicate_security_group_rule_fails()
-> self.security_group_rules_client.create_security_group_rule,
(Pdb)
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(199)test_create_duplicate_security_group_rule_fails()
-> security_group_id=body['security_group']['id'],
(Pdb)
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(200)test_create_duplicate_security_group_rule_fails()
-> protocol='tcp', direction='ingress', ethertype=self.ethertype,
(Pdb)
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(201)test_create_duplicate_security_group_rule_fails()
-> port_range_min=min_port, port_range_max=max_port)
(Pdb)
MismatchError: MismatchError()
> /tmp/tempest-testcase/tempest/tempest/api/network/test_security_groups_negative.py(201)test_create_duplicate_security_group_rule_fails()
-> port_range_min=min_port, port_range_max=max_port)

shajuvk (shajuvk)
information type: Proprietary → Public
tags: added: config redhat tempest
Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] master

Review in progress for https://review.opencontrail.org/34460
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R4.0

Review in progress for https://review.opencontrail.org/34469
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/34460
Committed: http://github.com/Juniper/contrail-controller/commit/753243178dc0aa15c8cd1e9621301606f3e05fed
Submitter: Zuul (<email address hidden>)
Branch: master

commit 753243178dc0aa15c8cd1e9621301606f3e05fed
Author: Sachin Bansal <email address hidden>
Date: Thu Aug 10 16:38:05 2017 -0700

Ignore create and modified time when comparing rules

We recently added create and last modified timestamp to security
group rules. This broke our comparison to detect duplicate rules.
We should ignore these keys when checking for duplicate rules.

Change-Id: I9fcabf439bebd6507bf56ac3144240d46ee2f8ef
Closes-Bug: 1710031

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote :

Reviewed: https://review.opencontrail.org/34469
Committed: http://github.com/Juniper/contrail-controller/commit/329447ce870d34fa1ed0fdf16639dd8cca7bdb4a
Submitter: Zuul (<email address hidden>)
Branch: R4.0

commit 329447ce870d34fa1ed0fdf16639dd8cca7bdb4a
Author: Sachin Bansal <email address hidden>
Date: Thu Aug 10 16:38:05 2017 -0700

Ignore create and modified time when comparing rules

We recently added create and last modified timestamp to security
group rules. This broke our comparison to detect duplicate rules.
We should ignore these keys when checking for duplicate rules.

Change-Id: I9fcabf439bebd6507bf56ac3144240d46ee2f8ef
Closes-Bug: 1710031

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : [Review update] R3.2

Review in progress for https://review.opencontrail.org/35185
Submitter: Sachin Bansal (<email address hidden>)

Revision history for this message
OpenContrail Admin (ci-admin-f) wrote : A change has been merged

Reviewed: https://review.opencontrail.org/35185
Committed: http://github.com/Juniper/contrail-controller/commit/94dcf9d4c0a7abbdb26d4e9d8372ad5308848499
Submitter: Zuul (<email address hidden>)
Branch: R3.2

commit 94dcf9d4c0a7abbdb26d4e9d8372ad5308848499
Author: Sachin Bansal <email address hidden>
Date: Thu Aug 10 16:38:05 2017 -0700

Ignore create and modified time when comparing rules

We recently added create and last modified timestamp to security
group rules. This broke our comparison to detect duplicate rules.
We should ignore these keys when checking for duplicate rules.

Change-Id: I9fcabf439bebd6507bf56ac3144240d46ee2f8ef
Closes-Bug: 1710031
(cherry picked from commit 329447ce870d34fa1ed0fdf16639dd8cca7bdb4a)

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.