]> sourceware.org Git - systemtap.git/commitdiff
static_uprobes test case cleanup
authorFrank Ch. Eigler <fche@elastic.org>
Fri, 20 Feb 2009 02:57:12 +0000 (21:57 -0500)
committerFrank Ch. Eigler <fche@elastic.org>
Fri, 20 Feb 2009 02:57:12 +0000 (21:57 -0500)
testsuite/ChangeLog
testsuite/systemtap.base/static_uprobes.exp

index 65244185f930f9ec9dd462416c4edc924e622471..afb757ae0df45c59d9182048f5669bf8f78bc80e 100644 (file)
@@ -1,3 +1,8 @@
+2009-02-19  Frank Ch. Eigler  <fche@elastic.org>
+
+       * systemtap.base/static_uprobes.exp: Standardized pass/fail message
+       strings.  Removed "objcopy -R .probe" for C++ test case.
+
 2009-02-18  Stan Cox  <scox@redhat.com>
 
        * systemtap.base/static_uprobes.exp: Also test without .probes section.
index d80bd0c4424068b8c1faa994840fb682fab036ed..11fec9b162d1ae1b0f24d1fce9f5dbcb04f19ba8 100644 (file)
@@ -89,9 +89,9 @@ if {[catch {exec $dtrace -h -s $sup_dpath} res]} {
     verbose -log "unable to run $dtrace: $res"
 }
 if {[file exists $sup_hpath]} then {
-    pass "generating $sup_hpath"
+    pass "$test generating header"
 } else {
-    fail "generating $sup_hpath"
+    fail "$test generating header"
     catch {exec rm -f $sup_srcpath $sup_hpath $sup_stppath}
     return
 }
@@ -108,11 +108,11 @@ set sup_flags "additional_flags=-I$sdtdir additional_flags=-g additional_flags=-
 set res [target_compile $sup_srcpath $sup_exepath executable $sup_flags]
 if { $res != "" } {
     verbose "target_compile failed: $res" 2
-    fail "compiling $sup_srcpath -g"
+    fail "$test compiling C -g"
     catch {exec rm -f $sup_srcpath $sup_hpath $sup_stppath}
     return
 } else {
-    pass "compiling $sup_srcpath -g"
+    pass "$test compiling C -g"
 }
 
 spawn mv $sup_srcpath "[pwd]/static_uprobes.cc"
@@ -121,11 +121,11 @@ set sup_flags "$sup_flags c++"
 set res [target_compile $sup_srcpath $supcplus_exepath executable $sup_flags]
 if { $res != "" } {
     verbose "target_compile failed: $res" 2
-    fail "compiling $sup_srcpath -g"
+    fail "$test compiling C++ -g"
     catch {exec rm -f $sup_srcpath $sup_exepath $sup_hpath $sup_stppath}
     return
 } else {
-    pass "compiling $sup_srcpath -g"
+    pass "$test compiling C++ -g"
 }
 
 if {![installtest_p]} {untested $test; return}
@@ -153,17 +153,19 @@ expect {
     -re {In test_probe_0 probe 0x3} { incr ok; exp_continue }
     -re {In test_probe_3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
     -re {In test_probe_4 dtrace probe 0x4} { incr ok; exp_continue }
-    timeout { fail "$test (timeout)" }
+    timeout { fail "$test (timeout)" }
     eof { }
 }
 
 wait
 
-if {$ok == 4} { pass "$test" } { fail "$test ($ok)" }
+if {$ok == 4} { pass "$test C" } { fail "$test C ($ok)" }
 
 set ok 0
 
-spawn objcopy -R .probes $supcplus_exepath $sup_exepath 
+# spawn objcopy -R .probes $supcplus_exepath $sup_exepath 
+verbose -log "cp $supcplus_exepath $sup_exepath"
+spawn cp $supcplus_exepath $sup_exepath
 verbose -log "spawn stap -c $sup_exepath $sup_stppath"
 spawn stap -c $sup_exepath $sup_stppath
 expect {
@@ -173,11 +175,15 @@ expect {
     -re {In test_probe_0 probe 0x3} { incr ok; exp_continue }
     -re {In test_probe_3 probe 0x3 0x[0-9a-f][0-9a-f]} { incr ok; exp_continue }
     -re {In test_probe_4 dtrace probe 0x4} { incr ok; exp_continue }
-    timeout { fail "$test (timeout)" }
+    timeout { fail "$test C++ (timeout)" }
     eof { }
 }
 
 wait
 
-if {$ok == 4} { pass "$test" } { fail "$test ($ok)" }
-catch {exec rm -f $sup_srcpath $sup_exepath $supcplus_exepath $sup_hpath $sup_stppath}
+if {$ok == 4} { pass "$test C++" } { fail "$test C++ ($ok)" }
+
+# catch {exec rm -f $sup_srcpath $sup_exepath $supcplus_exepath $sup_hpath $sup_stppath}
+
+# It's not so important to clean up, and it's unhelpful if
+# one needs to diagnose a test failure.
\ No newline at end of file
This page took 0.032424 seconds and 5 git commands to generate.