Best Python code snippet using tempest_python
test_server_actions.py
Source:test_server_actions.py
...587 @testtools.skipUnless(CONF.compute_feature_enabled.shelve,588 'Shelve is not available.')589 @testtools.skipUnless(CONF.compute_feature_enabled.pause,590 'Pause is not available.')591 def test_shelve_paused_server(self):592 server = self.create_test_server(wait_until='ACTIVE')593 self.client.pause_server(server['id'])594 waiters.wait_for_server_status(self.client, server['id'], 'PAUSED')595 # Check if Shelve operation is successful on paused server.596 compute.shelve_server(self.client, server['id'],597 force_shelve_offload=True)598 @decorators.idempotent_id('af8eafd4-38a7-4a4b-bdbc-75145a580560')599 def test_stop_start_server(self):600 self.client.stop_server(self.server_id)601 waiters.wait_for_server_status(self.client, self.server_id, 'SHUTOFF')602 self.client.start_server(self.server_id)603 waiters.wait_for_server_status(self.client, self.server_id, 'ACTIVE')604 @decorators.idempotent_id('80a8094c-211e-440a-ab88-9e59d556c7ee')605 def test_lock_unlock_server(self):...
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.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!