26 lines
572 B
Python
Raw Normal View History

2024-12-05 07:18:01 +00:00
import shlex
2024-12-05 07:27:37 +00:00
import subprocess
2024-12-05 07:18:01 +00:00
import time
processes = [
2024-12-05 07:27:37 +00:00
subprocess.Popen(
shlex.split(
"./.venv/bin/mololog.serve --host=127.0.0.1 --port=3999 --db=':memory:' --test=3"
)
),
subprocess.Popen(
shlex.split("./.venv/bin/mololog.test --url=http://localhost:3999")
),
2024-12-05 07:18:01 +00:00
]
for process in processes:
while True:
process.poll()
2024-12-05 07:27:37 +00:00
if process.returncode is not None:
2024-12-05 07:18:01 +00:00
if process.returncode != 0:
exit(process.returncode)
break
time.sleep(1)
print("Test sucess!")