-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathscripts.py
More file actions
35 lines (23 loc) · 769 Bytes
/
scripts.py
File metadata and controls
35 lines (23 loc) · 769 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import os
import subprocess
import sys
from pathlib import Path
def ex_obs():
subprocess.run(['tox', 'r', '-e', 'obs'])
def ex_sends():
path = Path.cwd() / 'examples' / 'sends' / '.'
subprocess.run([sys.executable, str(path)])
def ex_headamp():
path = Path.cwd() / 'examples' / 'headamp' / '.'
subprocess.run([sys.executable, str(path)])
def test_xair():
subprocess.run(['tox'], env=os.environ.copy() | {'TEST_MODULE': 'xair'})
def test_x32():
path = Path.cwd() / 'tools' / 'x32.exe'
proc = subprocess.Popen([str(path), '-i', 'x32.local'])
subprocess.run(['tox'], env=os.environ.copy() | {'TEST_MODULE': 'x32'})
proc.terminate()
def test_all():
steps = [test_xair, test_x32]
for step in steps:
step()