diff --git a/test/test.py b/test/test.py index 2fedef7..c67d237 100644 --- a/test/test.py +++ b/test/test.py @@ -107,25 +107,25 @@ def assert_message(msg: str, test_name: str, stdout: str, stderr: Optional[str] return retval -def build(nnxName: str, flow: Literal["make", "cmake"]) -> None: +def build(nnxName: NnxName, flow: Literal["make", "cmake"]) -> None: env = os.environ if flow == "make": Path("app/src/nnx_layer.c").touch() cmd = "make -C app all platform=gvsoc" - env["ACCELERATOR"] = nnxName + env["ACCELERATOR"] = str(nnxName) elif flow == "cmake": cmd = "cmake --build app/build" subprocess.run(cmd.split(), check=True, capture_output=True, text=True, env=env) -def run(nnxName: str, flow: Literal["make", "cmake"]) -> str: +def run(nnxName: NnxName, flow: Literal["make", "cmake"]) -> str: env = os.environ if flow == "make": cmd = "make -C app run platform=gvsoc" - env["ACCELERATOR"] = nnxName + env["ACCELERATOR"] = str(nnxName) elif flow == "cmake": build_dir = os.path.abspath(f"app/build_{nnxName}") bin = os.path.join(build_dir, "test-pulp-nnx")