Skip to content
Snippets Groups Projects
Commit c1a040bf authored by Moe Jette's avatar Moe Jette
Browse files

change termination of all send messages from "\n" to "\r"

parent fa50ab40
No related branches found
No related tags found
No related merge requests found
Showing
with 86 additions and 86 deletions
...@@ -58,7 +58,7 @@ expect { ...@@ -58,7 +58,7 @@ expect {
} }
-re "\[Rr\]emove .*\?" { -re "\[Rr\]emove .*\?" {
set matches 1 set matches 1
send "y\n" send "y\r"
exp_continue exp_continue
} }
timeout { timeout {
......
...@@ -49,7 +49,7 @@ set srun_pid [spawn $srun --input=$task_id -N1 -n10 -O -v --wait=2 -t1 $bin_bash ...@@ -49,7 +49,7 @@ set srun_pid [spawn $srun --input=$task_id -N1 -n10 -O -v --wait=2 -t1 $bin_bash
expect { expect {
-re "launching ($number).0 on host" { -re "launching ($number).0 on host" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$bin_env\n" send "$bin_env\r"
exp_continue exp_continue
} }
-re "SLURM_PROCID=($number)" { -re "SLURM_PROCID=($number)" {
...@@ -60,7 +60,7 @@ expect { ...@@ -60,7 +60,7 @@ expect {
send_user "\nFAILURE: wrong task_id responded\n" send_user "\nFAILURE: wrong task_id responded\n"
set exit_code 1 set exit_code 1
} }
send "exit\n" send "exit\r"
exp_continue exp_continue
} }
-re "error: First task exited" { -re "error: First task exited" {
......
...@@ -103,7 +103,7 @@ exec $bin_rm -f $file_in ...@@ -103,7 +103,7 @@ exec $bin_rm -f $file_in
# #
set host_0 "" set host_0 ""
set host_1 "" set host_1 ""
send "srun -l $bin_printenv SLURMD_NODENAME\n" send "srun -l $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_inx $expect_out(1,string) set host_inx $expect_out(1,string)
...@@ -152,7 +152,7 @@ if {$exit_code != 0} { ...@@ -152,7 +152,7 @@ if {$exit_code != 0} {
# Exclude specific node # Exclude specific node
# #
set matches 0 set matches 0
send "srun -l -N1 -n1 --exclude=$host_0 $bin_printenv SLURMD_NODENAME\n" send "srun -l -N1 -n1 --exclude=$host_0 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
if {[string compare $expect_out(1,string) $host_1] == 0} { if {[string compare $expect_out(1,string) $host_1] == 0} {
...@@ -189,7 +189,7 @@ if {$matches == 0} { ...@@ -189,7 +189,7 @@ if {$matches == 0} {
# Exclude specific node # Exclude specific node
# #
set matches 0 set matches 0
send "srun -l -N1 -n1 --exclude=$host_1 $bin_printenv SLURMD_NODENAME\n" send "srun -l -N1 -n1 --exclude=$host_1 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
if {[string compare $expect_out(1,string) $host_0] == 0} { if {[string compare $expect_out(1,string) $host_0] == 0} {
...@@ -226,13 +226,13 @@ if {$matches == 0} { ...@@ -226,13 +226,13 @@ if {$matches == 0} {
# Include specific node # Include specific node
# #
set matches 0 set matches 0
send "srun -l -N1 -n1 --nodelist=$host_0 $bin_printenv SLURMD_NODENAME\n" send "srun -l -N1 -n1 --nodelist=$host_0 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "Requested node configuration is not available" { -re "Requested node configuration is not available" {
send_user "\nWARNING: Appears you are using " send_user "\nWARNING: Appears you are using "
send_user "multiple slurmd testing.\n" send_user "multiple slurmd testing.\n"
send_user "This test won't work in that fashion.\n" send_user "This test won't work in that fashion.\n"
send "exit\n" send "exit\r"
exit 0 exit 0
} }
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
...@@ -270,7 +270,7 @@ if {$matches == 0} { ...@@ -270,7 +270,7 @@ if {$matches == 0} {
# Include specific node # Include specific node
# #
set matches 0 set matches 0
send "srun -l -N1 -n1 --nodelist=$host_1 $bin_printenv SLURMD_NODENAME\n" send "srun -l -N1 -n1 --nodelist=$host_1 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
if {[string compare $expect_out(1,string) $host_1] == 0} { if {[string compare $expect_out(1,string) $host_1] == 0} {
...@@ -310,7 +310,7 @@ if {$matches == 0} { ...@@ -310,7 +310,7 @@ if {$matches == 0} {
# #
set matches 0 set matches 0
send "srun -l -N1 -n1 --nodelist=$host_0 " send "srun -l -N1 -n1 --nodelist=$host_0 "
send " --exclude=$host_0 $bin_printenv SLURMD_NODENAME\n" send " --exclude=$host_0 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
send_user "\nFAILURE: wrong node responded\n" send_user "\nFAILURE: wrong node responded\n"
...@@ -344,7 +344,7 @@ if {$matches == 0} { ...@@ -344,7 +344,7 @@ if {$matches == 0} {
# Error test: Exceed node count # Error test: Exceed node count
# #
set matches 0 set matches 0
send "srun -l -N3 -n3 -O $bin_printenv SLURMD_NODENAME\n" send "srun -l -N3 -n3 -O $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
send_user "\nFAILURE: wrong node responded\n" send_user "\nFAILURE: wrong node responded\n"
...@@ -379,7 +379,7 @@ if {$matches == 0} { ...@@ -379,7 +379,7 @@ if {$matches == 0} {
# #
set test_0 "" set test_0 ""
set test_1 "" set test_1 ""
send "srun -l -N1-1 -n2 -O $bin_printenv SLURMD_NODENAME\n" send "srun -l -N1-1 -n2 -O $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_inx $expect_out(1,string) set host_inx $expect_out(1,string)
...@@ -417,7 +417,7 @@ if {[string compare $test_0 $test_1] != 0} { ...@@ -417,7 +417,7 @@ if {[string compare $test_0 $test_1] != 0} {
# Error test: Exceed task count, first get the processor count then exceed it # Error test: Exceed task count, first get the processor count then exceed it
# #
set processors 1 set processors 1
send "srun -l -c1 $bin_printenv SLURMD_NODENAME\n" send "srun -l -c1 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
incr processors incr processors
...@@ -441,7 +441,7 @@ expect { ...@@ -441,7 +441,7 @@ expect {
} }
} }
set matches 0 set matches 0
send "srun -l -n $processors $bin_printenv SLURMD_NODENAME\n" send "srun -l -n $processors $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "0: ($alpha_numeric_under)" { -re "0: ($alpha_numeric_under)" {
send_user "\nFAILURE: wrong node responded\n" send_user "\nFAILURE: wrong node responded\n"
...@@ -475,7 +475,7 @@ if {$matches == 0} { ...@@ -475,7 +475,7 @@ if {$matches == 0} {
# #
# Post-processing # Post-processing
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error.*Exit 1" { -re "error.*Exit 1" {
send_user "This error is expected, no worries\n" send_user "This error is expected, no worries\n"
......
...@@ -103,7 +103,7 @@ set host_0 "" ...@@ -103,7 +103,7 @@ set host_0 ""
set host_1 "" set host_1 ""
set host_2 "" set host_2 ""
set host_3 "" set host_3 ""
send "$srun -l $bin_printenv SLURMD_NODENAME\n" send "$srun -l $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_num $expect_out(1,string) set host_num $expect_out(1,string)
...@@ -168,7 +168,7 @@ if {$exit_code != 0} { ...@@ -168,7 +168,7 @@ if {$exit_code != 0} {
# #
set matches 0 set matches 0
send "$srun -l -N2 -n2 --relative=0 $bin_printenv SLURMD_NODENAME\n" send "$srun -l -N2 -n2 --relative=0 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_num $expect_out(1,string) set host_num $expect_out(1,string)
...@@ -220,7 +220,7 @@ if {$matches < 2} { ...@@ -220,7 +220,7 @@ if {$matches < 2} {
# Get two nodes relative (starting at) node 2 # Get two nodes relative (starting at) node 2
# #
set matches 0 set matches 0
send "$srun -l -N2 -n2 --relative=2 $bin_printenv SLURMD_NODENAME\n" send "$srun -l -N2 -n2 --relative=2 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_num $expect_out(1,string) set host_num $expect_out(1,string)
...@@ -273,7 +273,7 @@ if {$matches < 2} { ...@@ -273,7 +273,7 @@ if {$matches < 2} {
# Since there is only one node left, we check for a error message # Since there is only one node left, we check for a error message
# #
set error 0 set error 0
send "$srun -l -N2 -n2 -O --relative=3 $bin_printenv SLURMD_NODENAME\n" send "$srun -l -N2 -n2 -O --relative=3 $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "error:" { -re "error:" {
send_user "This error is expected, no worries\n" send_user "This error is expected, no worries\n"
...@@ -311,7 +311,7 @@ if {$error == 0} { ...@@ -311,7 +311,7 @@ if {$error == 0} {
# #
# Post-processing # Post-processing
# #
send "exit\n" send "exit\r"
expect { expect {
timeout { timeout {
send_user "\nFAILURE: srun not responding\n" send_user "\nFAILURE: srun not responding\n"
......
...@@ -79,7 +79,7 @@ set salloc_pid [spawn $salloc -N1 --exclusive --verbose -t2 $bin_bash] ...@@ -79,7 +79,7 @@ set salloc_pid [spawn $salloc -N1 --exclusive --verbose -t2 $bin_bash]
expect -re $prompt expect -re $prompt
set mask 0 set mask 0
set task_cnt 0 set task_cnt 0
send "$srun -c1 $file_prog\n" send "$srun -c1 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_cnt incr task_cnt
...@@ -105,7 +105,7 @@ expect { ...@@ -105,7 +105,7 @@ expect {
# #
set expected_mask [ expr ((1 << $task_cnt) - 1) ] set expected_mask [ expr ((1 << $task_cnt) - 1) ]
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=rank $file_prog\n" send "$srun -c1 --cpu_bind=rank $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -132,7 +132,7 @@ if {$task_mask != $expected_mask} { ...@@ -132,7 +132,7 @@ if {$task_mask != $expected_mask} {
# Run a job step with verbosity and all tasks on CPU 0 # Run a job step with verbosity and all tasks on CPU 0
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=verbose,map_cpu:0 $file_prog\n" send "$srun -c1 --cpu_bind=verbose,map_cpu:0 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -155,7 +155,7 @@ if {$task_mask != $task_cnt} { ...@@ -155,7 +155,7 @@ if {$task_mask != $task_cnt} {
set exit_code 1 set exit_code 1
} }
set verbose_cnt 0 set verbose_cnt 0
send "$srun -c1 --cpu_bind=verbose,map_cpu:0 $file_prog\n" send "$srun -c1 --cpu_bind=verbose,map_cpu:0 $file_prog\r"
expect { expect {
-re "cpu_bind=MAP|cpu_bind_cores=MAP|cpu_bind_sockets=MAP|cpu_bind_threads=MAP" { -re "cpu_bind=MAP|cpu_bind_cores=MAP|cpu_bind_sockets=MAP|cpu_bind_threads=MAP" {
incr verbose_cnt incr verbose_cnt
...@@ -185,7 +185,7 @@ set cpu_cnt 0 ...@@ -185,7 +185,7 @@ set cpu_cnt 0
while {$cpu_cnt < $task_cnt} { while {$cpu_cnt < $task_cnt} {
set mask_sum 0 set mask_sum 0
set mask [ expr 1 << $cpu_cnt ] set mask [ expr 1 << $cpu_cnt ]
send "$srun -c1 --cpu_bind=map_cpu:$cpu_cnt $file_prog\n" send "$srun -c1 --cpu_bind=map_cpu:$cpu_cnt $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr mask_sum $expect_out(2,string) incr mask_sum $expect_out(2,string)
...@@ -219,7 +219,7 @@ while {$cpu_cnt < $task_cnt} { ...@@ -219,7 +219,7 @@ while {$cpu_cnt < $task_cnt} {
set mask_sum 0 set mask_sum 0
set mask [ expr 1 << $cpu_cnt ] set mask [ expr 1 << $cpu_cnt ]
set mstr [ dec2hex $mask] set mstr [ dec2hex $mask]
send "$srun -c1 --cpu_bind=mask_cpu:$mstr $file_prog\n" send "$srun -c1 --cpu_bind=mask_cpu:$mstr $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr mask_sum $expect_out(2,string) incr mask_sum $expect_out(2,string)
...@@ -295,7 +295,7 @@ send_user "alt_mask: $alt_mask\n" ...@@ -295,7 +295,7 @@ send_user "alt_mask: $alt_mask\n"
# Run all tasks bound to a different CPU by specifying a forward map # Run all tasks bound to a different CPU by specifying a forward map
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=map_cpu:$fwd_map $file_prog\n" send "$srun -c1 --cpu_bind=map_cpu:$fwd_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -323,7 +323,7 @@ if {$task_mask != $full_mask} { ...@@ -323,7 +323,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU by specifying a reverse map # Run all tasks bound to a different CPU by specifying a reverse map
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=map_cpu:$rev_map $file_prog\n" send "$srun -c1 --cpu_bind=map_cpu:$rev_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -351,7 +351,7 @@ if {$task_mask != $full_mask} { ...@@ -351,7 +351,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU by specifying an alternating map # Run all tasks bound to a different CPU by specifying an alternating map
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=map_cpu:$alt_map $file_prog\n" send "$srun -c1 --cpu_bind=map_cpu:$alt_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -379,7 +379,7 @@ if {$task_mask != $full_mask} { ...@@ -379,7 +379,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU by specifying a forward mask # Run all tasks bound to a different CPU by specifying a forward mask
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=mask_cpu:$fwd_mask $file_prog\n" send "$srun -c1 --cpu_bind=mask_cpu:$fwd_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -407,7 +407,7 @@ if {$task_mask != $full_mask} { ...@@ -407,7 +407,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU by specifying a reverse mask # Run all tasks bound to a different CPU by specifying a reverse mask
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=mask_cpu:$rev_mask $file_prog\n" send "$srun -c1 --cpu_bind=mask_cpu:$rev_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -435,7 +435,7 @@ if {$task_mask != $full_mask} { ...@@ -435,7 +435,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU by specifying an alternating mask # Run all tasks bound to a different CPU by specifying an alternating mask
# #
set task_mask 0 set task_mask 0
send "$srun -c1 --cpu_bind=mask_cpu:$alt_mask $file_prog\n" send "$srun -c1 --cpu_bind=mask_cpu:$alt_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -462,7 +462,7 @@ if {$task_mask != $full_mask} { ...@@ -462,7 +462,7 @@ if {$task_mask != $full_mask} {
# #
# Terminate the job, free the allocation # Terminate the job, free the allocation
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
send_user "\nFAILURE: some error occurred\n" send_user "\nFAILURE: some error occurred\n"
......
...@@ -98,7 +98,7 @@ set salloc_pid [spawn $salloc -N1 --exclusive --verbose -t2 $bin_bash] ...@@ -98,7 +98,7 @@ set salloc_pid [spawn $salloc -N1 --exclusive --verbose -t2 $bin_bash]
expect -re $prompt expect -re $prompt
set full_mask -1 set full_mask -1
set timeout $max_job_delay set timeout $max_job_delay
send "$srun -c1 $file_prog\n" send "$srun -c1 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
set full_mask $expect_out(3,string) set full_mask $expect_out(3,string)
...@@ -147,7 +147,7 @@ if {$full_mask == 1} { ...@@ -147,7 +147,7 @@ if {$full_mask == 1} {
# #
set cpu_mask 0 set cpu_mask 0
set mem_mask 0 set mem_mask 0
send "$srun -n $task_cnt --mem_bind=rank $file_prog\n" send "$srun -n $task_cnt --mem_bind=rank $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr cpu_mask $expect_out(2,string) incr cpu_mask $expect_out(2,string)
...@@ -176,7 +176,7 @@ if {$mem_mask != $full_mask} { ...@@ -176,7 +176,7 @@ if {$mem_mask != $full_mask} {
# #
set task_mask 0 set task_mask 0
set verbose_cnt 0 set verbose_cnt 0
send "$srun -n $task_cnt --mem_bind=verbose,map_mem:0 $file_prog\n" send "$srun -n $task_cnt --mem_bind=verbose,map_mem:0 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -199,7 +199,7 @@ if {$task_mask != $task_cnt} { ...@@ -199,7 +199,7 @@ if {$task_mask != $task_cnt} {
set exit_code 1 set exit_code 1
} }
set verbose_cnt 0 set verbose_cnt 0
send "$srun -n $task_cnt --mem_bind=verbose,map_mem:0 $file_prog\n" send "$srun -n $task_cnt --mem_bind=verbose,map_mem:0 $file_prog\r"
expect { expect {
-re "mem_bind=MAP" { -re "mem_bind=MAP" {
incr verbose_cnt incr verbose_cnt
...@@ -225,7 +225,7 @@ if {$verbose_cnt != $task_cnt} { ...@@ -225,7 +225,7 @@ if {$verbose_cnt != $task_cnt} {
# #
# Run all tasks all bound to the same CPU's memory (local CPU) # Run all tasks all bound to the same CPU's memory (local CPU)
# #
send "$srun -n $task_cnt --cpu_bind=rank --mem_bind=local $file_prog\n" send "$srun -n $task_cnt --cpu_bind=rank --mem_bind=local $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
if {$expect_out(2,string) != $expect_out(3,string)} { if {$expect_out(2,string) != $expect_out(3,string)} {
...@@ -255,7 +255,7 @@ set cpu_cnt 0 ...@@ -255,7 +255,7 @@ set cpu_cnt 0
while {$cpu_cnt < $task_cnt} { while {$cpu_cnt < $task_cnt} {
set mask_sum 0 set mask_sum 0
set mask [ expr 1 << $cpu_cnt ] set mask [ expr 1 << $cpu_cnt ]
send "$srun -n $task_cnt --mem_bind=map_mem:$cpu_cnt $file_prog\n" send "$srun -n $task_cnt --mem_bind=map_mem:$cpu_cnt $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr mask_sum $expect_out(3,string) incr mask_sum $expect_out(3,string)
...@@ -289,7 +289,7 @@ while {$cpu_cnt < $task_cnt} { ...@@ -289,7 +289,7 @@ while {$cpu_cnt < $task_cnt} {
set mask_sum 0 set mask_sum 0
set mask [ expr 1 << $cpu_cnt ] set mask [ expr 1 << $cpu_cnt ]
set mstr [ dec2hex $mask] set mstr [ dec2hex $mask]
send "$srun -n $task_cnt --mem_bind=mask_mem:$mstr $file_prog\n" send "$srun -n $task_cnt --mem_bind=mask_mem:$mstr $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr mask_sum $expect_out(3,string) incr mask_sum $expect_out(3,string)
...@@ -365,7 +365,7 @@ send_user "alt_mask: $alt_mask\n" ...@@ -365,7 +365,7 @@ send_user "alt_mask: $alt_mask\n"
# Run all tasks bound to a different CPU's memory by specifying a forward map # Run all tasks bound to a different CPU's memory by specifying a forward map
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=map_mem:$fwd_map $file_prog\n" send "$srun -n $task_cnt --mem_bind=map_mem:$fwd_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -393,7 +393,7 @@ if {$task_mask != $full_mask} { ...@@ -393,7 +393,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU's memory by specifying a reverse map # Run all tasks bound to a different CPU's memory by specifying a reverse map
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=map_mem:$rev_map $file_prog\n" send "$srun -n $task_cnt --mem_bind=map_mem:$rev_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -421,7 +421,7 @@ if {$task_mask != $full_mask} { ...@@ -421,7 +421,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU's memroy by specifying an alternating map # Run all tasks bound to a different CPU's memroy by specifying an alternating map
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=map_mem:$alt_map $file_prog\n" send "$srun -n $task_cnt --mem_bind=map_mem:$alt_map $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -449,7 +449,7 @@ if {$task_mask != $full_mask} { ...@@ -449,7 +449,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU's memory by specifying a forward mask # Run all tasks bound to a different CPU's memory by specifying a forward mask
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=mask_mem:$fwd_mask $file_prog\n" send "$srun -n $task_cnt --mem_bind=mask_mem:$fwd_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -477,7 +477,7 @@ if {$task_mask != $full_mask} { ...@@ -477,7 +477,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU's memory by specifying a reverse mask # Run all tasks bound to a different CPU's memory by specifying a reverse mask
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=mask_mem:$rev_mask $file_prog\n" send "$srun -n $task_cnt --mem_bind=mask_mem:$rev_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -505,7 +505,7 @@ if {$task_mask != $full_mask} { ...@@ -505,7 +505,7 @@ if {$task_mask != $full_mask} {
# Run all tasks bound to a different CPU's memory by specifying an alternating mask # Run all tasks bound to a different CPU's memory by specifying an alternating mask
# #
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt --mem_bind=mask_mem:$alt_mask $file_prog\n" send "$srun -n $task_cnt --mem_bind=mask_mem:$alt_mask $file_prog\r"
expect { expect {
-re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" { -re "TASK_ID:($number),CPU_MASK:($number),MEM_MASK:($number)" {
incr task_mask $expect_out(3,string) incr task_mask $expect_out(3,string)
...@@ -532,7 +532,7 @@ if {$task_mask != $full_mask} { ...@@ -532,7 +532,7 @@ if {$task_mask != $full_mask} {
# #
# Terminate the job, free the allocation # Terminate the job, free the allocation
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
send_user "\nFAILURE: some error occurred\n" send_user "\nFAILURE: some error occurred\n"
......
...@@ -137,7 +137,7 @@ set salloc_pid [spawn $salloc -w $node_name -N1 --exclusive --verbose -t2 $bin_b ...@@ -137,7 +137,7 @@ set salloc_pid [spawn $salloc -w $node_name -N1 --exclusive --verbose -t2 $bin_b
expect -re $prompt expect -re $prompt
set mask 0 set mask 0
set task_cnt 0 set task_cnt 0
send "$srun -c1 $file_prog\n" send "$srun -c1 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_cnt incr task_cnt
...@@ -164,7 +164,7 @@ expect { ...@@ -164,7 +164,7 @@ expect {
# #
set expected_mask [ expr ((1 << $task_cnt) - 1) ] set expected_mask [ expr ((1 << $task_cnt) - 1) ]
set task_mask 0 set task_mask 0
send "$srun -c1 -n $task_cnt -B 1:1:1 $file_prog\n" send "$srun -c1 -n $task_cnt -B 1:1:1 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -197,7 +197,7 @@ while {$this_cnt <= $num_sockets} { ...@@ -197,7 +197,7 @@ while {$this_cnt <= $num_sockets} {
set num_tasks 0 set num_tasks 0
set num_bits 0 set num_bits 0
set task_mask 0 set task_mask 0
send "$srun -B $this_cnt-$this_cnt:$num_cores:$num_threads $file_prog\n" send "$srun -B $this_cnt-$this_cnt:$num_cores:$num_threads $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -247,7 +247,7 @@ while {$this_cnt <= $num_cores} { ...@@ -247,7 +247,7 @@ while {$this_cnt <= $num_cores} {
set num_tasks 0 set num_tasks 0
set num_bits 0 set num_bits 0
set task_mask 0 set task_mask 0
send "$srun -B $num_sockets:$this_cnt-$this_cnt:$num_threads $file_prog\n" send "$srun -B $num_sockets:$this_cnt-$this_cnt:$num_threads $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -297,7 +297,7 @@ while {$this_cnt <= $num_threads} { ...@@ -297,7 +297,7 @@ while {$this_cnt <= $num_threads} {
set num_tasks 0 set num_tasks 0
set num_bits 0 set num_bits 0
set task_mask 0 set task_mask 0
send "$srun -B $num_sockets:$num_cores:$this_cnt-$this_cnt $file_prog\n" send "$srun -B $num_sockets:$num_cores:$this_cnt-$this_cnt $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -346,7 +346,7 @@ while {$this_cnt <= $task_cnt} { ...@@ -346,7 +346,7 @@ while {$this_cnt <= $task_cnt} {
set num_tasks 0 set num_tasks 0
set num_bits 0 set num_bits 0
set task_mask 0 set task_mask 0
send "$srun -c$this_cnt -B 1:1:1 $file_prog\n" send "$srun -c$this_cnt -B 1:1:1 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -392,7 +392,7 @@ while {$this_cnt <= $task_cnt} { ...@@ -392,7 +392,7 @@ while {$this_cnt <= $task_cnt} {
# #
set expected_mask [ expr ((1 << $task_cnt) - 1) ] set expected_mask [ expr ((1 << $task_cnt) - 1) ]
set task_mask 0 set task_mask 0
send "$srun -n $task_cnt -m plane=4 $file_prog\n" send "$srun -n $task_cnt -m plane=4 $file_prog\r"
expect { expect {
-re "TASK_ID:($number),MASK:($number)" { -re "TASK_ID:($number),MASK:($number)" {
incr task_mask $expect_out(2,string) incr task_mask $expect_out(2,string)
...@@ -419,7 +419,7 @@ if {$task_mask != $expected_mask} { ...@@ -419,7 +419,7 @@ if {$task_mask != $expected_mask} {
# #
# Terminate the job, free the allocation # Terminate the job, free the allocation
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
send_user "\nFAILURE: some error occurred\n" send_user "\nFAILURE: some error occurred\n"
......
...@@ -66,7 +66,7 @@ expect { ...@@ -66,7 +66,7 @@ expect {
exit 0 exit 0
} }
-re $prompt { -re $prompt {
send "$srun -l -c1 $file_bash | sort -n\n" send "$srun -l -c1 $file_bash | sort -n\r"
} }
timeout { timeout {
send_user "\nFAILURE: salloc not responding\n" send_user "\nFAILURE: salloc not responding\n"
...@@ -129,7 +129,7 @@ if {$task_cnt < (2 * $node_cnt)} { ...@@ -129,7 +129,7 @@ if {$task_cnt < (2 * $node_cnt)} {
set this_cnt 0 set this_cnt 0
set prev_node -1 set prev_node -1
set this_node -1 set this_node -1
send "$srun -l -n $task_cnt -m block $file_bash | sort -n\n" send "$srun -l -n $task_cnt -m block $file_bash | sort -n\r"
expect { expect {
-re "nodeid:($number) taskid:($number) localid:($number)" { -re "nodeid:($number) taskid:($number) localid:($number)" {
set this_node $expect_out(1,string) set this_node $expect_out(1,string)
...@@ -179,7 +179,7 @@ set this_cnt 0 ...@@ -179,7 +179,7 @@ set this_cnt 0
set prev_node -1 set prev_node -1
set this_node -1 set this_node -1
set prev_cnt $block_size set prev_cnt $block_size
send "$srun -l -n $task_cnt -m cyclic $file_bash | sort -n\n" send "$srun -l -n $task_cnt -m cyclic $file_bash | sort -n\r"
expect { expect {
-re "nodeid:($number) taskid:($number) localid:($number)" { -re "nodeid:($number) taskid:($number) localid:($number)" {
set this_node $expect_out(1,string) set this_node $expect_out(1,string)
...@@ -229,7 +229,7 @@ set this_cnt 0 ...@@ -229,7 +229,7 @@ set this_cnt 0
set prev_node -1 set prev_node -1
set this_node -1 set this_node -1
set prev_cnt $block_size set prev_cnt $block_size
send "$srun -l -n $task_cnt -m plane=$block_size $file_bash | sort -n\n" send "$srun -l -n $task_cnt -m plane=$block_size $file_bash | sort -n\r"
expect { expect {
-re "nodeid:($number) taskid:($number) localid:($number)" { -re "nodeid:($number) taskid:($number) localid:($number)" {
set this_node $expect_out(1,string) set this_node $expect_out(1,string)
...@@ -274,7 +274,7 @@ if {$this_cnt != $task_cnt} { ...@@ -274,7 +274,7 @@ if {$this_cnt != $task_cnt} {
# #
# Terminate the job, free the allocation # Terminate the job, free the allocation
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
send_user "\nFAILURE: some error occurred\n" send_user "\nFAILURE: some error occurred\n"
......
...@@ -89,7 +89,7 @@ exec $bin_rm -f $file_in ...@@ -89,7 +89,7 @@ exec $bin_rm -f $file_in
# #
set host_0 "" set host_0 ""
set host_1 "" set host_1 ""
send "$srun -l --mpi=lam $bin_printenv SLURMD_NODENAME\n" send "$srun -l --mpi=lam $bin_printenv SLURMD_NODENAME\r"
expect { expect {
-re "($number): ($alpha_numeric_under)" { -re "($number): ($alpha_numeric_under)" {
set host_inx $expect_out(1,string) set host_inx $expect_out(1,string)
...@@ -134,7 +134,7 @@ if {[string compare $host_0 $host_1] == 0} { ...@@ -134,7 +134,7 @@ if {[string compare $host_0 $host_1] == 0} {
# #
# Post-processing # Post-processing
# #
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
send_user "\nFAILURE: Some error occured\n" send_user "\nFAILURE: Some error occured\n"
......
...@@ -107,14 +107,14 @@ expect { ...@@ -107,14 +107,14 @@ expect {
set stuff [concat $stuff "11"] set stuff [concat $stuff "11"]
incr matches incr matches
exec sleep 1 exec sleep 1
send "\n" send "\r"
exp_continue exp_continue
} }
"qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj" { "qqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqqj" {
# This is the bottom line of the smap box I know it # This is the bottom line of the smap box I know it
# looks wierd, but this is what expect sees it as. # looks wierd, but this is what expect sees it as.
# exec sleep 1 # exec sleep 1
send "\n" send "\r"
exp_continue exp_continue
} }
timeout { timeout {
......
...@@ -70,11 +70,11 @@ expect { ...@@ -70,11 +70,11 @@ expect {
} }
-re "to exit" { -re "to exit" {
if { $matches == 0 } { if { $matches == 0 } {
send "create 1\n" send "create 1\r"
} elseif { $matches == 1 } { } elseif { $matches == 1 } {
send "save $file\n" send "save $file\r"
} elseif { $matches == 2 } { } elseif { $matches == 2 } {
send "exit\n" send "exit\r"
} }
incr matches incr matches
exp_continue exp_continue
......
...@@ -66,7 +66,7 @@ expect { ...@@ -66,7 +66,7 @@ expect {
send "j" send "j"
} }
if { $matches >= 3 } { if { $matches >= 3 } {
send "\n" send "\r"
} }
exp_continue exp_continue
} }
......
...@@ -99,7 +99,7 @@ set job_id $expect_out(1,string) ...@@ -99,7 +99,7 @@ set job_id $expect_out(1,string)
# start initial job step to claim some switch windows # start initial job step to claim some switch windows
expect -re $prompt expect -re $prompt
send "$srun -N1 -O -n$windows_used $bin_sleep $step_delay &\n" send "$srun -N1 -O -n$windows_used $bin_sleep $step_delay &\r"
# start more job steps to check see if any switch window conflicts occur # start more job steps to check see if any switch window conflicts occur
for {set inx 0} {$inx < $windows_iterations} {incr inx} { for {set inx 0} {$inx < $windows_iterations} {incr inx} {
...@@ -111,7 +111,7 @@ for {set inx 0} {$inx < $windows_iterations} {incr inx} { ...@@ -111,7 +111,7 @@ for {set inx 0} {$inx < $windows_iterations} {incr inx} {
} }
-re $prompt { -re $prompt {
send_user "spawning step $inx\n" send_user "spawning step $inx\n"
send "$srun -N1 -O -n$windows_used true\n" send "$srun -N1 -O -n$windows_used true\r"
} }
timeout { timeout {
send_user "\nFAILURE: salloc not responding\n" send_user "\nFAILURE: salloc not responding\n"
...@@ -130,7 +130,7 @@ for {set inx 0} {$inx < $windows_iterations} {incr inx} { ...@@ -130,7 +130,7 @@ for {set inx 0} {$inx < $windows_iterations} {incr inx} {
expect -re $prompt expect -re $prompt
send_user "(sleeping for $step_delay seconds, for job step zero to complete) " send_user "(sleeping for $step_delay seconds, for job step zero to complete) "
exec $bin_sleep $step_delay exec $bin_sleep $step_delay
send "exit\n" send "exit\r"
expect { expect {
-re "error" { -re "error" {
......
...@@ -46,12 +46,12 @@ for {set inx 1} {$inx < 4} {set inx [expr $inx * 2]} { ...@@ -46,12 +46,12 @@ for {set inx 1} {$inx < 4} {set inx [expr $inx * 2]} {
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$scontrol show job $job_id\n" send "$scontrol show job $job_id\r"
exp_continue exp_continue
} }
-re "ReqProcs=($number).*" { -re "ReqProcs=($number).*" {
set tasks_get $expect_out(1,string) set tasks_get $expect_out(1,string)
send "exit\n" send "exit\r"
exp_continue exp_continue
} }
-re "Failed to allocate.*" { -re "Failed to allocate.*" {
......
...@@ -61,7 +61,7 @@ set salloc_pid [spawn $salloc -t1 --job-name=$job_name $bin_bash] ...@@ -61,7 +61,7 @@ set salloc_pid [spawn $salloc -t1 --job-name=$job_name $bin_bash]
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$scontrol show job $job_id\n" send "$scontrol show job $job_id\r"
exp_continue exp_continue
} }
-re "Name=$job_name" { -re "Name=$job_name" {
...@@ -70,7 +70,7 @@ expect { ...@@ -70,7 +70,7 @@ expect {
} }
-re "Priority=($number)" { -re "Priority=($number)" {
set priority1 $expect_out(1,string) set priority1 $expect_out(1,string)
send "exit\n" send "exit\r"
exp_continue exp_continue
} }
timeout { timeout {
...@@ -104,12 +104,12 @@ set salloc_pid [spawn $salloc -t1 --nice=1000 $bin_bash] ...@@ -104,12 +104,12 @@ set salloc_pid [spawn $salloc -t1 --nice=1000 $bin_bash]
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$scontrol show job $job_id\n" send "$scontrol show job $job_id\r"
exp_continue exp_continue
} }
-re "Priority=($number)" { -re "Priority=($number)" {
set priority2 $expect_out(1,string) set priority2 $expect_out(1,string)
send "exit\n" send "exit\r"
exp_continue exp_continue
} }
timeout { timeout {
......
...@@ -60,7 +60,7 @@ expect { ...@@ -60,7 +60,7 @@ expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
send_user "\nFAILURE: salloc job submitted with invalid constraint\n" send_user "\nFAILURE: salloc job submitted with invalid constraint\n"
set exit_code 1 set exit_code 1
send "exit\n" send "exit\r"
} }
-re "Pending job allocation ($number)" { -re "Pending job allocation ($number)" {
send_user "\nFAILURE: salloc job submitted with invalid constraint\n" send_user "\nFAILURE: salloc job submitted with invalid constraint\n"
......
...@@ -65,17 +65,17 @@ set salloc_pid [spawn $salloc -N$node_cnt -t1 $bin_bash] ...@@ -65,17 +65,17 @@ set salloc_pid [spawn $salloc -N$node_cnt -t1 $bin_bash]
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id_1 $expect_out(1,string) set job_id_1 $expect_out(1,string)
send "$sbatch --jobid=$job_id_1 -o none -e none $file_in \n" send "$sbatch --jobid=$job_id_1 -o none -e none $file_in \r"
exp_continue exp_continue
} }
-re "Submitted batch job ($number)" { -re "Submitted batch job ($number)" {
set job_id_2 $expect_out(1,string) set job_id_2 $expect_out(1,string)
send "exit \n" send "exit \r"
exp_continue exp_continue
} }
-re "jobid ($number).0 submitted" { -re "jobid ($number).0 submitted" {
set job_id_2 $expect_out(1,string) set job_id_2 $expect_out(1,string)
send "exit \n" send "exit \r"
exp_continue exp_continue
} }
timeout { timeout {
......
...@@ -71,7 +71,7 @@ set salloc_pid [spawn $salloc -N$node_cnt -t1 $srun -l $bin_printenv SLURMD_NODE ...@@ -71,7 +71,7 @@ set salloc_pid [spawn $salloc -N$node_cnt -t1 $srun -l $bin_printenv SLURMD_NODE
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$bin_echo MY_ID=\$SLURM_JOB_ID \n" send "$bin_echo MY_ID=\$SLURM_JOB_ID \r"
exp_continue exp_continue
} }
-re "More processors requested than permitted" { -re "More processors requested than permitted" {
......
...@@ -59,8 +59,8 @@ expect { ...@@ -59,8 +59,8 @@ expect {
} }
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$scontrol show job $job_id\n" send "$scontrol show job $job_id\r"
send "exit\n" send "exit\r"
exp_continue exp_continue
} }
-re "TimeLimit=($number):($number):" { -re "TimeLimit=($number):($number):" {
......
...@@ -50,7 +50,7 @@ set salloc_pid [spawn $salloc -t1 $bin_bash] ...@@ -50,7 +50,7 @@ set salloc_pid [spawn $salloc -t1 $bin_bash]
expect { expect {
-re "Granted job allocation ($number)" { -re "Granted job allocation ($number)" {
set job_id $expect_out(1,string) set job_id $expect_out(1,string)
send "$bin_echo MY_ID=\$SLURM_JOB_ID \n" send "$bin_echo MY_ID=\$SLURM_JOB_ID \r"
array unset expect_out array unset expect_out
exp_continue exp_continue
} }
...@@ -62,7 +62,7 @@ expect { ...@@ -62,7 +62,7 @@ expect {
break break
} }
} }
send "exit 4\n" send "exit 4\r"
exp_continue exp_continue
} }
-re "\[Ee\]xit 4" { -re "\[Ee\]xit 4" {
......
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