The testing script is getting too big and not very well organized. In this commit a new module `integration_tests` is introduced that contains parts of the original testing script split into multiple files. The content should be the same, the only difference is that now you can run the tests by invoking `python3 -m test`.
14 lines
394 B
Python
14 lines
394 B
Python
from .config import *
|
|
|
|
|
|
def evaluate_test(test, name=None):
|
|
try:
|
|
test()
|
|
print(f"{RESET}{BOLD}{name or test.__name__}: Success{RESET}")
|
|
except AssertionError as e:
|
|
print(f"{RESET}{BOLD}{name or test.__name__}: {RESET}{RED}Fail{RESET}")
|
|
print(e)
|
|
|
|
|
|
def rel_path(fname: str) -> str:
|
|
return os.path.join(os.path.dirname(os.path.dirname(__file__)), fname)
|