@@ -317,7 +317,7 @@ def test_deploy_ssh_error(hq_env: HqEnv):
317317 with hq_env .mock .mock_program_with_code (
318318 "ssh" ,
319319 """
320- exit(42)
320+ exit(42)
321321 """ ,
322322 ):
323323 nodefile = prepare_localhost_nodefile ()
@@ -351,8 +351,8 @@ def test_deploy_ssh_wait_for_worker(hq_env: HqEnv):
351351 with hq_env .mock .mock_program_with_code (
352352 "ssh" ,
353353 """
354- import time
355- time.sleep(1)
354+ import time
355+ time.sleep(1)
356356 """ ,
357357 ):
358358 nodefile = prepare_localhost_nodefile ()
@@ -364,12 +364,12 @@ def test_deploy_ssh_multiple_workers(hq_env: HqEnv):
364364 with hq_env .mock .mock_program_with_code (
365365 "ssh" ,
366366 """
367- import os
367+ import os
368368
369- os.makedirs("workers", exist_ok=True)
370- with open(f"workers/{os.getpid()}", "w") as f:
371- f.write(str(os.getpid()))
372- """ ,
369+ os.makedirs("workers", exist_ok=True)
370+ with open(f"workers/{os.getpid()}", "w") as f:
371+ f.write(str(os.getpid()))
372+ """ ,
373373 ):
374374 nodefile = prepare_localhost_nodefile (count = 3 )
375375 hq_env .command (["worker" , "deploy-ssh" , nodefile ])
@@ -381,8 +381,8 @@ def test_deploy_ssh_show_output(hq_env: HqEnv):
381381 with hq_env .mock .mock_program_with_code (
382382 "ssh" ,
383383 """
384- print("FOOBAR")
385- """ ,
384+ print("FOOBAR")
385+ """ ,
386386 ):
387387 nodefile = prepare_localhost_nodefile (count = 3 )
388388 output = hq_env .command (["worker" , "deploy-ssh" , "--show-output" , nodefile ])
@@ -424,15 +424,15 @@ def test_worker_state_info(hq_env: HqEnv):
424424 wait_for_job_state (hq_env , 1 , "RUNNING" )
425425 table = hq_env .command (["worker" , "info" , "1" ], as_table = True )
426426 table .check_row_value ("State" , "RUNNING" )
427- assert "Job: 1; " in table .get_row_value ("Last task started" )
427+ assert "1@ " in table .get_row_value ("Last task started" )
428428 table .check_row_value ("Runtime Info" , "assigned tasks: 2; running tasks: 1" )
429429 hq_env .start_worker ()
430430 hq_env .command (["submit" , "--nodes=2" , "--" , "sleep" , "1" ])
431431 wait_for_job_state (hq_env , 2 , "RUNNING" )
432432 table = hq_env .command (["worker" , "info" , "1" ], as_table = True )
433433 a = table .get_row_value ("Runtime Info" )
434- assert "Job: 2; " in table .get_row_value ("Last task started" )
434+ assert "2@0 " in table .get_row_value ("Last task started" )
435435 table = hq_env .command (["worker" , "info" , "2" ], as_table = True )
436436 b = table .get_row_value ("Runtime Info" )
437- assert "Job: 2; " in table .get_row_value ("Last task started" )
437+ assert "2@0 " in table .get_row_value ("Last task started" )
438438 assert {a , b } == {"running multinode task; main node" , "running multinode task; secondary node" }
0 commit comments