fork download
  1. import unittest
  2.  
  3. class MyTest(unittest.TestCase):
  4. def test_good(self):
  5. pass
  6. def test_bad(self):
  7. self.assertTrue(False)
  8.  
  9. if __name__ == '__main__':
  10. unittest.main()
Runtime error #stdin #stdout #stderr 0.07s 12052KB
stdin
Standard input is empty
stdout
Standard output is empty
stderr
F.
======================================================================
FAIL: test_bad (__main__.MyTest)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "./prog.py", line 7, in test_bad
AssertionError: False is not true

----------------------------------------------------------------------
Ran 2 tests in 0.000s

FAILED (failures=1)