Exemple #1
0
 def test_availability_at_first_attempt(self, sleep_mock, failed_mock):
     SSH.await_availability('')
     self.assertEqual(1, failed_mock.call_count)
     self.assertFalse(sleep_mock.called)
 def wait_ssh(self, vm, interval=10):
     self.wait_state(vm, 'Running', interval)
     SSH.await_availability(vm, interval)
Exemple #3
0
 def test_availability_at_second_attempt(self, sleep_mock, failed_mock):
     SSH.await_availability('')
     self.assertEqual(2, failed_mock.call_count)
     self.assertTrue(sleep_mock.called)