File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -16,4 +16,5 @@ def suite():
1616 return suite
1717
1818if __name__ == '__main__' :
19- unittest .TextTestRunner (verbosity = 2 ).run (suite ())
19+ res = unittest .TextTestRunner (verbosity = 2 ).run (suite ())
20+ sys .exit (not res .wasSuccessful ())
Original file line number Diff line number Diff line change @@ -16,4 +16,5 @@ def suite():
1616 return suite
1717
1818if __name__ == '__main__' :
19- unittest .TextTestRunner (verbosity = 2 ).run (suite ())
19+ res = unittest .TextTestRunner (verbosity = 2 ).run (suite ())
20+ sys .exit (not res .wasSuccessful ())
Original file line number Diff line number Diff line change @@ -88,7 +88,7 @@ def learn(self):
8888 self .stream .writeln ("" )
8989 self .stream .writeln (self .say_something_zenlike ())
9090
91- if self .failures : return
91+ if self .failures : sys . exit ( - 1 )
9292 self .stream .writeln (
9393 "\n {0}**************************************************" \
9494 .format (Fore .RESET ))
You can’t perform that action at this time.
0 commit comments