File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Expand file tree Collapse file tree 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change 5959 - name : Run tests
6060 run : |
6161 cd $WORKSPACE_DIR
62- python3 build/rocm/ci_build test $TEST_IMAGE
62+ python3 build/rocm/ci_build test $TEST_IMAGE --test-cmd "pytest tests/core_test.py"
6363
Original file line number Diff line number Diff line change @@ -202,7 +202,7 @@ def dist_docker(
202202 subprocess .check_call (cmd )
203203
204204
205- def test (image_name ):
205+ def test (image_name , test_cmd ):
206206 """Run unit tests like CI would inside a JAX image."""
207207
208208 gpu_args = [
@@ -236,7 +236,7 @@ def test(image_name):
236236 cmd .extend (mounts )
237237 cmd .extend (gpu_args )
238238
239- container_cmd = "cd /jax && ./build/rocm/build_rocm.sh && ./build/rocm/run_single_gpu.py -c && ./build/rocm/run_multi_gpu.sh"
239+ container_cmd = "cd /jax && " + test_cmd
240240 cmd .append (image_name )
241241 cmd .extend (
242242 [
@@ -299,6 +299,7 @@ def parse_args():
299299
300300 testp = subp .add_parser ("test" )
301301 testp .add_argument ("image_name" )
302+ testp .add_argument ("--test-cmd" , default = "./build/rocm/build_rocm.sh && ./build/rocm/run_single_gpu.py -c && ./build/rocm/run_multi_gpu.sh" )
302303
303304 ddp = subp .add_parser ("dist_docker" )
304305 ddp .add_argument ("--dockerfile" , default = "build/rocm/Dockerfile.ms" )
@@ -322,7 +323,7 @@ def main():
322323 )
323324
324325 elif args .action == "test" :
325- test (args .image_name )
326+ test (args .image_name , args . test_cmd )
326327
327328 elif args .action == "dist_docker" :
328329 dist_wheels (
You can’t perform that action at this time.
0 commit comments