Пример #1
0
 def test_failed_custom(self):
     tout = KeywordTimeout('1s', 'Custom message', VariableMock())
     tout.starttime = time.time() - 2
     assert_equals(tout.get_message(), 'Custom message')
Пример #2
0
 def test_active(self):
     tout = KeywordTimeout('42s', variables=VariableMock())
     tout.start()
     msg = tout.get_message()
     assert_true(msg.startswith('Keyword timeout 42 seconds active.'), msg)
     assert_true(msg.endswith('seconds left.'), msg)
Пример #3
0
 def test_active(self):
     tout = KeywordTimeout('42s', variables=VariableMock())
     tout.start()
     msg = tout.get_message()
     assert_true(msg.startswith('Keyword timeout 42 seconds active.'), msg)
     assert_true(msg.endswith('seconds left.'), msg)
Пример #4
0
 def test_failed_custom(self):
     tout = KeywordTimeout('1s', 'Custom message', VariableMock())
     tout.starttime = time.time() - 2
     assert_equal(tout.get_message(), 'Custom message')
 def test_failed_custom(self):
     tout = KeywordTimeout("1s", "Custom message", VariableMock())
     tout.starttime = time.time() - 2
     assert_equal(tout.get_message(), "Custom message")