"""Run the public offline suite without creating bytecode in the release tree.""" import os import sys import unittest from pathlib import Path def main(): os.environ["PYTHONDONTWRITEBYTECODE"] = "1" sys.dont_write_bytecode = True root = Path(__file__).resolve().parents[1] suite = unittest.defaultTestLoader.discover(str(root / "tests"), pattern="test_*.py") result = unittest.TextTestRunner(verbosity=2).run(suite) return 0 if result.wasSuccessful() else 1 if __name__ == "__main__": sys.exit(main())