Skip to content
Snippets Groups Projects
Commit b8fb1208 authored by Christopher J. Morrone's avatar Christopher J. Morrone
Browse files

Adapt even more tests to srun's removed --batch option.

parent 49ed1858
No related branches found
No related tags found
No related merge requests found
......@@ -50,16 +50,16 @@ make_bash_script $file_in "
#
# Submit a job so we have something to work with
#
set srun_pid [spawn $srun --batch --output=/dev/null --error=/dev/null -t2 $file_in]
set sbatch_pid [spawn $sbatch --output=/dev/null --error=/dev/null -t2 $file_in]
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
timeout {
send_user "\nFAILURE: srun not responding\n"
if {$job_id == 0} {
slow_kill $srun_pid
slow_kill $sbatch_pid
} else {
cancel_job $job_id
}
......
......@@ -95,15 +95,15 @@ make_bash_script $file_in "
# Usage: test12.2.prog <exit_code> <sleep_secs> <mem_kb>
#
set timeout [expr $max_job_delay + $sleep_time]
set srun_pid [spawn $srun --batch --output=$file_out --error=$file_err -t2 $file_in]
set sbatch_pid [spawn $sbatch --output=$file_out --error=$file_err -t2 $file_in]
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
timeout {
send_user "\nFAILURE: srun not responding\n"
slow_kill $srun_pid
slow_kill $sbatch_pid
exit 1
}
eof {
......
......@@ -92,8 +92,8 @@ set timeout $max_job_delay
set job_id 0
set matches 0
set srun_pid [spawn $srun --allocate -N1 --verbose -t2]
expect -re "jobid ($number).*"
set srun_pid [spawn $salloc -N1 --verbose -t2 bash]
expect -re "Granted job allocation ($number)"
set job_id $expect_out(1,string)
# start initial job step to claim some switch windows
......
......@@ -69,18 +69,18 @@ make_bash_script $file_in "
"
#
# Spawn a srun batch job that uses stdout/err and confirm their contents
# Spawn an sbatch job that uses stdout/err and confirm their contents
#
set timeout $max_job_delay
set srun_pid [spawn $srun -N1-1 --batch --output=$file_out --error=$file_err -t1 $file_in]
set sbatch_pid [spawn $sbatch -N1 --output=$file_out --error=$file_err -t1 $file_in]
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
timeout {
send_user "\nFAILURE: srun not responding\n"
slow_kill $srun_pid
slow_kill $sbatch_pid
set exit_code 1
}
eof {
......
......@@ -61,18 +61,18 @@ make_bash_script $file_in "
"
#
# Spawn a srun batch job that uses stdout/err and confirm their contents
# Spawn an sbatch job that uses stdout/err and confirm their contents
#
set timeout $max_job_delay
set srun_pid [spawn $srun -N1-1 --batch --output=$file_out --error=$file_err -t1 $file_in]
set sbatch_pid [spawn $sbatch -N1 --output=$file_out --error=$file_err -t1 $file_in]
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
timeout {
send_user "\nFAILURE: srun not responding\n"
slow_kill $srun_pid
slow_kill $sbatch_pid
set exit_code 1
}
eof {
......
......@@ -74,18 +74,18 @@ make_bash_script $file_in "
"
#
# Spawn a srun batch job that uses stdout/err and confirm their contents
# Spawn an sbatch job that uses stdout/err and confirm their contents
#
set timeout $max_job_delay
set srun_pid [spawn $srun -N1 --batch --output=$file_out --error=$file_err -t1 $file_in]
set sbatch_pid [spawn $sbatch -N1 --output=$file_out --error=$file_err -t1 $file_in]
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
timeout {
send_user "\nFAILURE: srun not responding\n"
slow_kill $srun_pid
slow_kill $sbatch_pid
set exit_code 1
}
eof {
......
......@@ -47,7 +47,7 @@ exec $bin_rm -f $file_in
make_bash_script $file_in "$bin_hostname"
#
# Spawn a srun batch job that uses stdout/err and confirm their contents
# Spawn a batch job that uses stdout/err and confirm their contents
#
set timeout $max_job_delay
if { [test_bluegene] } {
......@@ -60,7 +60,7 @@ if { [test_bluegene] } {
}
}
set srun_pid [spawn $srun -N$node_cnt -A -v -t1]
set srun_pid [spawn $salloc -N$node_cnt -v -t1 bash]
expect {
-re "jobid ($number):" {
set job_id_1 $expect_out(1,string)
......
......@@ -67,9 +67,9 @@ exec $strigger --clear --quiet --user=$uid
make_bash_script $file_in "sleep 60"
set job_id 0
spawn $srun --batch --output=/dev/null -t2 $file_in
spawn $sbatch --output=/dev/null -t2 $file_in
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
......
......@@ -74,9 +74,9 @@ make_bash_script $file_in_down "sleep 1"
make_bash_script $file_in_reconfig "sleep 1"
set job_id 0
spawn $srun --batch --output=/dev/null -t1 $file_in
spawn $sbatch --output=/dev/null -t1 $file_in
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
......
......@@ -68,9 +68,9 @@ make_bash_script $file_in "sleep 6"
make_bash_script $file_in_idle "echo \$1 >$cwd/$file_out"
set job_id 0
spawn $srun --batch --output=/dev/null -t1 $file_in
spawn $sbatch --output=/dev/null -t1 $file_in
expect {
-re "jobid ($number) submitted" {
-re "Submitted batch job ($number)" {
set job_id $expect_out(1,string)
exp_continue
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment