Skip to content

Commit 4a70bc6

Browse files
fixed select tests
1 parent 3e03f1a commit 4a70bc6

1 file changed

Lines changed: 5 additions & 18 deletions

File tree

ner_environment/build_system/build_system.py

Lines changed: 5 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -70,25 +70,12 @@ def test(clean: bool = typer.Option(False, "--clean", help="Clean the build dire
7070
command = ["docker", "compose", "run", "--rm", "ner-gcc-arm", "sh", "-c", f"cd Drivers/Embedded-Base/testing/ && make clean"]
7171
run_command(command, stream_output=True)
7272
return
73-
74-
if not files:
75-
command = ["docker", "compose", "run", "--rm", "ner-gcc-arm", "sh", "-c", "cd Drivers/Embedded-Base/testing/ && make"]
76-
run_command(command, stream_output=True)
77-
return
73+
74+
file_args = " ".join(files) if files else ""
75+
command = ["docker", "compose", "run", "--rm", "ner-gcc-arm", "sh", "-c", f"cd Drivers/Embedded-Base/testing/ && make TEST_FILES='{file_args}'"]
76+
run_command(command, stream_output=True)
7877

79-
procs = []
80-
for file in files:
81-
cmd = [
82-
"docker", "compose", "run", "--rm", "ner-gcc-arm", "sh", "-c",
83-
f"cd Drivers/Embedded-Base/testing/ && flock /tmp/test_runner.lock -c 'make TEST_FILE={file}'"
84-
]
85-
# Use Popen for parallel execution
86-
proc = subprocess.Popen(cmd)
87-
procs.append(proc)
88-
89-
# Wait for all to finish
90-
for proc in procs:
91-
proc.wait()
78+
9279

9380
# ==============================================================================
9481
# Clang command

0 commit comments

Comments
 (0)