2023-07-10 15:55:10 +00:00
|
|
|
import os
|
2023-08-04 18:27:03 +00:00
|
|
|
import typing
|
2023-08-10 11:43:17 +00:00
|
|
|
from datetime import datetime
|
2023-08-04 18:27:03 +00:00
|
|
|
|
2023-07-10 15:55:10 +00:00
|
|
|
from scripts.utils.system_path import SystemPath
|
|
|
|
|
|
|
|
ROOT: SystemPath = SystemPath(__file__).resolve().parent.parent
|
|
|
|
|
2023-08-04 18:27:03 +00:00
|
|
|
# Runtime initialisation
|
|
|
|
TEST: typing.Optional[SystemPath] = None
|
|
|
|
TEST_VP: typing.Optional[SystemPath] = None
|
|
|
|
TEST_ARTIFACTS: typing.Optional[SystemPath] = None
|
|
|
|
|
2023-07-10 15:55:10 +00:00
|
|
|
# Test Directories
|
|
|
|
RUN_ID = os.getenv('RUN_DIR', f'run_{datetime.now():%d%m%Y_%H%M%S}')
|
|
|
|
TEMP: SystemPath = ROOT / 'tmp'
|
|
|
|
RESULTS: SystemPath = TEMP / 'results'
|
|
|
|
RUN: SystemPath = RESULTS / RUN_ID
|
2023-08-04 18:27:03 +00:00
|
|
|
VP: SystemPath = ROOT / 'ext' / 'vp'
|
|
|
|
TEST_FILES: SystemPath = ROOT / 'ext' / 'test_files'
|
2023-12-21 10:21:57 +00:00
|
|
|
TEST_IMAGES: SystemPath = ROOT / 'ext' / 'test_images'
|
2023-08-10 11:43:17 +00:00
|
|
|
TEST_USER_DATA: SystemPath = ROOT / 'ext' / 'user_data'
|
2023-07-10 15:55:10 +00:00
|
|
|
|
|
|
|
# Driver Directories
|
2023-11-30 12:51:36 +00:00
|
|
|
SQUISH_DIR_RAW = os.getenv('SQUISH_DIR')
|
|
|
|
assert SQUISH_DIR_RAW is not None
|
|
|
|
SQUISH_DIR = SystemPath(SQUISH_DIR_RAW)
|
2023-08-04 18:27:03 +00:00
|
|
|
|
|
|
|
# Status Application
|
|
|
|
STATUS_DATA: SystemPath = RUN / 'status'
|
2023-11-17 14:27:51 +00:00
|
|
|
|
|
|
|
# Sets log level, can be one of: "ERROR", "WARN", "INFO", "DEBUG", "TRACE". "INFO"
|
|
|
|
LOG_LEVEL = 'DEBUG'
|
|
|
|
|