Exemple #1
0
 def test_command_fail_result(self):
     command = Command('command-1')
     assert_that(command.state(), is_(State.QUEUED))
     command.start()
     assert_that(command.state(), is_(State.STARTED))
     command.fail('failed')
     assert_that(command.state(), is_(State.FAIL))
     assert_that(command.result, is_('failed'))
Exemple #2
0
 def test_command_fail(self):
     command = Command('command-1')
     assert_that(command.state(), is_(State.QUEUED))
     command.fail()
     assert_that(command.state(), is_(State.FAIL))