From 7984d0e73507f36181e79daa90a3b1dbbcdb2cb3 Mon Sep 17 00:00:00 2001 From: Danny Auble <da@schedmd.com> Date: Fri, 22 Aug 2014 11:49:54 -0700 Subject: [PATCH] Minor changes to further bullet proof test (Makes sure sacct doesn't look at any other day for -D jobs) --- testsuite/expect/test12.7 | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/testsuite/expect/test12.7 b/testsuite/expect/test12.7 index 9a4fbd5e928..1483d60980c 100755 --- a/testsuite/expect/test12.7 +++ b/testsuite/expect/test12.7 @@ -58,12 +58,12 @@ proc mod_state { state } { proc check_step { num } { global sacct job_id exit_code - set steps 0 - spawn $sacct --job=$job_id\.batch -D --noheader --format=jobid%30 -P + spawn $sacct --job=$job_id\.batch -D --start=today --noheader --format=jobid -P expect { -re "batch" { - incr steps 1 + incr steps + send_user "got here with $steps\n" exp_continue } timeout { @@ -75,6 +75,7 @@ proc check_step { num } { } } + if {$num != $steps} { send_user "\nFAILURE: found $steps step(s) when expecting " send_user "$num steps\n" @@ -86,10 +87,10 @@ proc check_sacct_states { states } { global job_id sacct set state_num 0 - spawn $sacct --job=$job_id -D --noheader --format=state -P + spawn $sacct --job=$job_id -D --start=today --noheader --format=state -P expect { -re ($states) { - incr state_num 1 + incr state_num exp_continue } timeout { -- GitLab