mirror of
git://github.com/kovidgoyal/calibre.git
synced 2025-12-16 01:55:57 +01:00
Re-use run_cli for running the build tests
This commit is contained in:
parent
0cc5371090
commit
c7365b9333
1 changed files with 2 additions and 8 deletions
|
|
@ -237,15 +237,9 @@ def find_tests():
|
|||
ans.addTests(find_tests())
|
||||
return ans
|
||||
|
||||
class TestRunner(unittest.main):
|
||||
|
||||
def createTests(self):
|
||||
self.test = find_tests()
|
||||
|
||||
def test():
|
||||
result = TestRunner(verbosity=2, buffer=True, catchbreak=True, failfast=False, argv=sys.argv[:1], exit=False).result
|
||||
if not result.wasSuccessful():
|
||||
raise SystemExit(1)
|
||||
from calibre.utils.run_tests import run_cli
|
||||
run_cli(find_tests())
|
||||
|
||||
if __name__ == '__main__':
|
||||
test()
|
||||
|
|
|
|||
Loading…
Reference in a new issue