summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--testsuite/ChangeLog5
-rw-r--r--testsuite/systemtap.context/pid.tcl6
2 files changed, 9 insertions, 2 deletions
diff --git a/testsuite/ChangeLog b/testsuite/ChangeLog
index e4e46c4f..c5c68bc4 100644
--- a/testsuite/ChangeLog
+++ b/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2007-07-10 Martin Hunt <hunt@redhat.com>
+
+ * systemtap.context/pid.tcl: Don't try to get real ppid,
+ just match pattern.
+
2007-07-09 Martin Hunt <hunt@redhat.com>
* systemtap.context/systemtap_test_module1.c (stm_write_cmd):
diff --git a/testsuite/systemtap.context/pid.tcl b/testsuite/systemtap.context/pid.tcl
index e1ae9897..a99f69b1 100644
--- a/testsuite/systemtap.context/pid.tcl
+++ b/testsuite/systemtap.context/pid.tcl
@@ -1,10 +1,11 @@
set tests [list execname pexecname pid ppid tid uid euid gid egid]
spawn stap pid.stp
+exp_internal 1
expect {
-timeout 240
"READY" {
set pid [exec echo 1 > /proc/stap_test_cmd &]
- set ppid [lindex [split [exec grep PPid /proc/$pid/status]] 1]
+ set ppid {[0-9]*}
set uid [exec id -ru]
set gid [exec id -rg]
set euid [exec id -u]
@@ -13,9 +14,10 @@ expect {
set i 0
foreach t $tests {
+ puts "Expecting [lindex $results $i]"
expect {
-timeout 5
- [lindex $results $i] {
+ -re [lindex $results $i] {
pass $t
}
timeout {fail "$t - timeout"}