16 lines
729 B
Python
16 lines
729 B
Python
"""Current-image resume preflight, not an activation grant or gameplay test."""
|
|
import subprocess
|
|
import tempfile
|
|
import unittest
|
|
from pathlib import Path
|
|
ROOT=Path(__file__).resolve().parents[2]
|
|
|
|
class CubeResume(unittest.TestCase):
|
|
def test_terminal_current_image_authority_and_failures(self):
|
|
with tempfile.TemporaryDirectory() as folder:
|
|
exe=Path(folder)/'resume'
|
|
subprocess.run(['c++','-std=c++17','-fsanitize=address,undefined','-fno-sanitize-recover=all','-I'+str(ROOT),str(ROOT/'tests/features/fixtures/cube_resume_probe.cpp'),'-lsqlite3','-o',str(exe)],check=True)
|
|
subprocess.run([str(exe),str(Path(folder)/'cube.db')],check=True)
|
|
|
|
if __name__=='__main__':unittest.main()
|