diff options
author | hunt <hunt> | 2007-05-25 14:40:31 +0000 |
---|---|---|
committer | hunt <hunt> | 2007-05-25 14:40:31 +0000 |
commit | 5980a64171df3af58258d93ae3b0729cdc900f2e (patch) | |
tree | 1447aa5a1777d72e637944b3f0b2fab76ce07a4a /testsuite/lib/stap_run.exp | |
parent | f29c6102608f553542f443b4fc981700261fee59 (diff) | |
download | systemtap-steved-5980a64171df3af58258d93ae3b0729cdc900f2e.tar.gz systemtap-steved-5980a64171df3af58258d93ae3b0729cdc900f2e.tar.xz systemtap-steved-5980a64171df3af58258d93ae3b0729cdc900f2e.zip |
2007-05-25 Martin Hunt <hunt@redhat.com>
* systemtap.samples/lket.exp (cleanfiles): Set timeout inside expect.
* systemtap.maps/absentstats.exp: Set timeout inside expect.
* lib/stap_run2.exp (stap_run2): Set timeout to 180 inside expect.
* lib/stap_run.exp (stap_run): Set timeout to 180 for slower machines.
Remove $ anchor on output. Fix a few minor nits in patterns.
Diffstat (limited to 'testsuite/lib/stap_run.exp')
-rw-r--r-- | testsuite/lib/stap_run.exp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/testsuite/lib/stap_run.exp b/testsuite/lib/stap_run.exp index baf41d9b..8b1c8eaa 100644 --- a/testsuite/lib/stap_run.exp +++ b/testsuite/lib/stap_run.exp @@ -31,12 +31,13 @@ proc stap_run { TEST_NAME {LOAD_GEN_FUNCTION ""} {OUTPUT_CHECK_STRING ""} args } } eval spawn $cmd expect { - -re {^Pass\ ([1234]):[^\r]*\ in\ ([0-9]+)usr/([0-9]+)sys/([0-9]+)real\ ms.\r\n} + -timeout 180 + -re {^Pass\ ([1234]):[^\r]*\ in\ ([0-9]+)usr/([0-9]+)sys/([0-9]+)real\ ms\.\r\n} {set pass$expect_out(1,string) "\t$expect_out(2,string)\t$expect_out(3,string)\t$expect_out(4,string)"; exp_continue} - -re {^Pass\ ([34]): using cached .+\r\n} + -re {^Pass\ ([34]): using cached [^\r]+\r\n} {set pass$expect_out(1,string) "\t0\t0\t0"; exp_continue} -re {^Pass 5: starting run.\r\n} {exp_continue} - -timeout 30 -re "^systemtap starting probe\r\n" { + -re "^systemtap starting probe\r\n" { pass "$TEST_NAME startup" if {$LOAD_GEN_FUNCTION != ""} then { #run the interesting test here @@ -50,13 +51,14 @@ proc stap_run { TEST_NAME {LOAD_GEN_FUNCTION ""} {OUTPUT_CHECK_STRING ""} args } send "\003" # check the output to see if it is sane - set output "^systemtap ending probe\r\n$OUTPUT_CHECK_STRING$" + set output "^systemtap ending probe\r\n$OUTPUT_CHECK_STRING" expect { + -timeout 20 -re $output { pass "$TEST_NAME shutdown and output" expect { - -re {^Pass\ ([5]):[^\r]*\ in\ ([0-9]+)usr/([0-9]+)sys/([0-9]+)real\ ms.\r\n} + -re {^Pass\ ([5]):[^\r]*\ in\ ([0-9]+)usr/([0-9]+)sys/([0-9]+)real\ ms\.\r\n} {set pass$expect_out(1,string) "\t$expect_out(2,string)\t$expect_out(3,string)\t$expect_out(4,string)" verbose -log "metric:\t$TEST_NAME $pass1$pass2$pass3$pass4$pass5"} -re {^WARNING: Number of errors: ([0-9]+), skipped probes: ([0-9]+)\r\n} |