From: Frank Ch. Eigler Date: Mon, 29 Oct 2012 02:39:36 +0000 (-0400) Subject: testsuite: make stap_run[23] more verbose when failing X-Git-Tag: release-2.1~332 X-Git-Url: https://sourceware.org/git/?a=commitdiff_plain;h=fe0fc0df853078e58911f3d2f33f8c384dc7721a;p=systemtap.git testsuite: make stap_run[23] more verbose when failing If a stap_run[23] test case fails, in that the actual output varies from the expected output, all remaining actual output lines were neither compared nor reported in systemtap.log. * testsuite/lib/stap_run2.exp (stap_run3): In case of a line mismatch, report any remaining actual lines. --- diff --git a/testsuite/lib/stap_run2.exp b/testsuite/lib/stap_run2.exp index c3bfb7a51..66ff3ece4 100644 --- a/testsuite/lib/stap_run2.exp +++ b/testsuite/lib/stap_run2.exp @@ -40,6 +40,13 @@ proc stap_run3 { TEST_NAME TEST_FILE args } { fail "$TEST_NAME" send_log "line [expr $n + 1]: expected \"[lindex $expected $n]\"\n" send_log "Got \"$line\"\n" + set m 0 + foreach line2 [split $res "\n"] { + if {$m > $n} { + send_log " \"$line2\"\n" + } + incr m + } return } incr n