public inbox for systemtap@sourceware.org
 help / color / mirror / Atom feed
* [PATCH v2 1/3] fix the testcases so that the result will be more exact
@ 2015-11-10  7:48 Zhou Wenjian
  2015-11-10  7:49 ` [PATCH v2 3/3] add more test cases for timer Zhou Wenjian
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Zhou Wenjian @ 2015-11-10  7:48 UTC (permalink / raw)
  To: systemtap

	* testsuite/lib/stap_run.exp: add pass_string

fix the output string:
	* testsuite/systemtap.base/be_order.exp
	* testsuite/systemtap.base/global_init.exp
	* testsuite/systemtap.base/logical_and.exp
	* testsuite/systemtap.base/tri.exp
	* testsuite/systemtap.base/global_vars.stp
	* testsuite/systemtap.base/timers.stp
	* testsuite/systemtap.stress/current.exp
---
 testsuite/lib/stap_run.exp               | 3 ++-
 testsuite/systemtap.base/be_order.exp    | 4 ++--
 testsuite/systemtap.base/global_init.exp | 4 ++--
 testsuite/systemtap.base/logical_and.exp | 4 ++--
 testsuite/systemtap.base/timers.exp      | 2 +-
 testsuite/systemtap.base/tri.exp         | 4 ++--
 testsuite/systemtap.stress/current.exp   | 2 +-
 7 files changed, 12 insertions(+), 11 deletions(-)

diff --git a/testsuite/lib/stap_run.exp b/testsuite/lib/stap_run.exp
index f5780d0..48d1b8c 100755
--- a/testsuite/lib/stap_run.exp
+++ b/testsuite/lib/stap_run.exp
@@ -166,4 +166,5 @@ print_system_info
 # BZ692445 was fixed by removing the '$' at the end of
 # all_pass_string. Yet another expect regular expression oddity. The
 # '\r\n' is good enough at finding the EOL.
-set all_pass_string "(systemtap test success\r\n)+"
+set pass_string "(systemtap test success\r\n)"
+set all_pass_string "${pass_string}+"
diff --git a/testsuite/systemtap.base/be_order.exp b/testsuite/systemtap.base/be_order.exp
index eeae818..49e3b94 100755
--- a/testsuite/systemtap.base/be_order.exp
+++ b/testsuite/systemtap.base/be_order.exp
@@ -3,9 +3,9 @@
 set test "be_order"
 foreach runtime [get_runtime_list] {
     if {$runtime != ""} {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string \
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{2} \
 	    --runtime=$runtime
     } else {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{2}
     }
 }
diff --git a/testsuite/systemtap.base/global_init.exp b/testsuite/systemtap.base/global_init.exp
index 040ac44..d036a3f 100755
--- a/testsuite/systemtap.base/global_init.exp
+++ b/testsuite/systemtap.base/global_init.exp
@@ -4,9 +4,9 @@ set test "global_init"
 
 foreach runtime [get_runtime_list] {
     if {$runtime != ""} {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string \
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{2} \
 	    --runtime=$runtime
     } else {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{2}
     }
 }
diff --git a/testsuite/systemtap.base/logical_and.exp b/testsuite/systemtap.base/logical_and.exp
index 0e52e68..1134b38 100755
--- a/testsuite/systemtap.base/logical_and.exp
+++ b/testsuite/systemtap.base/logical_and.exp
@@ -4,9 +4,9 @@ set test "logical_and"
 
 foreach runtime [get_runtime_list] {
     if {$runtime != ""} {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string \
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{4} \
 	    --runtime=$runtime
     } else {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{4}
     }
 }
diff --git a/testsuite/systemtap.base/timers.exp b/testsuite/systemtap.base/timers.exp
index 70ed341..0f06c20 100755
--- a/testsuite/systemtap.base/timers.exp
+++ b/testsuite/systemtap.base/timers.exp
@@ -11,6 +11,6 @@ proc sleep_ten_secs {} {
 #check to see whether get the marker indicating the probe is loaded and running
 #should check to see whether exited for some reason
 #should be error is something else is printed.
-set output_string "(\\w+ = \\d+\r\n){7}${all_pass_string}(WARNING.*skipped.*)?"
+set output_string "(\\w+ = \\d+\r\n){7}${pass_string}{4}(WARNING.*skipped.*)?"
 
 stap_run $srcdir/$subdir/$test.stp sleep_ten_secs $output_string
diff --git a/testsuite/systemtap.base/tri.exp b/testsuite/systemtap.base/tri.exp
index c980284..2f600f4 100755
--- a/testsuite/systemtap.base/tri.exp
+++ b/testsuite/systemtap.base/tri.exp
@@ -4,9 +4,9 @@ set test "tri"
 
 foreach runtime [get_runtime_list] {
     if {$runtime != ""} {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string \
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{3} \
 	    --runtime=$runtime
     } else {
-	stap_run $srcdir/$subdir/$test.stp no_load $all_pass_string
+	stap_run $srcdir/$subdir/$test.stp no_load ${pass_string}{3}
     }
 }
diff --git a/testsuite/systemtap.stress/current.exp b/testsuite/systemtap.stress/current.exp
index 313b67a..46b8158 100755
--- a/testsuite/systemtap.stress/current.exp
+++ b/testsuite/systemtap.stress/current.exp
@@ -19,6 +19,6 @@ proc current_load {} {
     return 0
 }
 
-set output_string "(\\w+ = \\d+\r\n){5}${all_pass_string}(WARNING.*skipped.*)?"
+set output_string "(\\w+ = \\d+\r\n){5}${pass_string}{2}(WARNING.*skipped.*)?"
 
 stap_run $srcdir/$subdir/$test.stp current_load $output_string -g -w
-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2015-11-19 15:58 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2015-11-10  7:48 [PATCH v2 1/3] fix the testcases so that the result will be more exact Zhou Wenjian
2015-11-10  7:49 ` [PATCH v2 3/3] add more test cases for timer Zhou Wenjian
2015-11-10  7:49 ` [PATCH v2 2/3] add testcases for function definitions Zhou Wenjian
2015-11-18  2:39 ` [PATCH v2 1/3] fix the testcases so that the result will be more exact "Zhou, Wenjian/周文剑"
2015-11-19 15:58   ` David Smith

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).