import sys,unittest,json
from pathlib import Path
sys.path[:0]=['/out/source','/out/source/tests']
suite=unittest.defaultTestLoader.loadTestsFromName('test_fight_r5')
result=unittest.TextTestRunner(verbosity=2).run(suite)
Path('/out/download/r5_tests.json').write_text(json.dumps(dict(passed=result.wasSuccessful(),tests=result.testsRun,failures=len(result.failures),errors=len(result.errors))))
raise SystemExit(not result.wasSuccessful())
