File size: 637 Bytes
2983a9c
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
#!/usr/bin/env python3
"""Validate every source environment and optionally the complete exported release.
Usage: python3 tools/validate.py [--exported] [--docker]
"""
import subprocess,sys
from pathlib import Path
ROOT=Path(__file__).resolve().parents[1]
def run(*args): subprocess.run([sys.executable]+list(args),cwd=str(ROOT),check=True)
for path in sorted((ROOT/'envs').glob('*/env.toml')): run('tools/selftest.py',path.parent.name,'60')
for path in sorted((ROOT/'tests').glob('test_*.py')): run(str(path))
if '--exported' in sys.argv: run('tools/check_tasks.py')
if '--docker' in sys.argv: run('tools/check_tasks.py','--docker','4')