How to use test_create_security_group_rule_with_bad_protocol method in tempest

Best Python code snippet using tempest_python

test_security_groups_negative.py

Source:test_security_groups_negative.py Github

copy

Full Screen

...37 self.client.delete_security_group,38 non_exist_id39 )40 @attr(type=['negative', 'gate'])41 def test_create_security_group_rule_with_bad_protocol(self):42 group_create_body, _ = self._create_security_group()43 #Create rule with bad protocol name44 pname = 'bad_protocol_name'45 self.assertRaises(exceptions.BadRequest,46 self.client.create_security_group_rule,47 group_create_body['security_group']['id'],48 protocol=pname)49 @attr(type=['negative', 'gate'])50 def test_create_security_group_rule_with_invalid_ports(self):51 group_create_body, _ = self._create_security_group()52 #Create rule with invalid ports53 states = [(-16, 80, 'Invalid value for port -16'),54 (80, 79, 'port_range_min must be <= port_range_max'),55 (80, 65536, 'Invalid value for port 65536'),...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run tempest automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful