summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJosh Stone <jistone@redhat.com>2009-08-05 17:56:44 -0700
committerJosh Stone <jistone@redhat.com>2009-08-05 17:56:44 -0700
commit68d47ee749911aa9babdfe37efd85db115e316be (patch)
treee36db009d6260f465d56a19d9edb0ff391958a2f
parentf249edcd5f135278e15ccafb497be520c325a5e4 (diff)
downloadsystemtap-steved-68d47ee749911aa9babdfe37efd85db115e316be.tar.gz
systemtap-steved-68d47ee749911aa9babdfe37efd85db115e316be.tar.xz
systemtap-steved-68d47ee749911aa9babdfe37efd85db115e316be.zip
Remove as_root calls from the printf testsuite
Once upon a time, we would use sudo staprun, and so output files from "-o" were owned by root. For a while now we've used a setuid staprun instead, and the output files are created by stapio as the user. Thus, we don't need as_root to remove those files anymore. * testsuite/systemtap.printf/end1b.exp: Clean up without as_root. * testsuite/systemtap.printf/mixed_outb.exp: Ditto. * testsuite/systemtap.printf/out1b.exp: Ditto. * testsuite/systemtap.printf/out2b.exp: Ditto. * testsuite/systemtap.printf/out3b.exp: Ditto.
-rw-r--r--testsuite/systemtap.printf/end1b.exp8
-rw-r--r--testsuite/systemtap.printf/mixed_outb.exp8
-rw-r--r--testsuite/systemtap.printf/out1b.exp8
-rw-r--r--testsuite/systemtap.printf/out2b.exp8
-rw-r--r--testsuite/systemtap.printf/out3b.exp8
5 files changed, 20 insertions, 20 deletions
diff --git a/testsuite/systemtap.printf/end1b.exp b/testsuite/systemtap.printf/end1b.exp
index 46cdc9c7..c3c9d4cf 100644
--- a/testsuite/systemtap.printf/end1b.exp
+++ b/testsuite/systemtap.printf/end1b.exp
@@ -18,24 +18,24 @@ if {[catch {exec mktemp -t staptestXXXXXX} tmpfile]} {
if {[catch {exec stap -b -o $tmpfile $test} res]} {
puts "stap failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {eval [list exec $stap_merge_path -o $tmpfile] [glob "${tmpfile}_*"]} res]} {
puts "merge failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {exec cmp $tmpfile $srcdir/$subdir/large_output} res]} {
puts "$res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
pass $TEST_NAME
-as_root "/bin/rm -f [glob ${tmpfile}*]"
+eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
diff --git a/testsuite/systemtap.printf/mixed_outb.exp b/testsuite/systemtap.printf/mixed_outb.exp
index c15520b1..1225f9ce 100644
--- a/testsuite/systemtap.printf/mixed_outb.exp
+++ b/testsuite/systemtap.printf/mixed_outb.exp
@@ -18,24 +18,24 @@ if {[catch {exec mktemp -t staptestXXXXXX} tmpfile]} {
if {[catch {exec stap -DMAXACTION=100000 -b -o $tmpfile $test} res]} {
fail $TEST_NAME
puts "stap failed: $res"
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {eval [list exec $stap_merge_path -o $tmpfile] [glob "${tmpfile}_*"]} res]} {
puts "merge failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {exec cmp $tmpfile $srcdir/$subdir/large_output} res]} {
puts "$res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
pass $TEST_NAME
-as_root "/bin/rm -f [glob ${tmpfile}*]"
+eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
diff --git a/testsuite/systemtap.printf/out1b.exp b/testsuite/systemtap.printf/out1b.exp
index 24efbf4c..d09dadef 100644
--- a/testsuite/systemtap.printf/out1b.exp
+++ b/testsuite/systemtap.printf/out1b.exp
@@ -18,24 +18,24 @@ if {[catch {exec mktemp -t staptestXXXXXX} tmpfile]} {
if {[catch {exec stap -b -o $tmpfile $test} res]} {
fail $TEST_NAME
puts "stap failed: $res"
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {eval [list exec $stap_merge_path -o $tmpfile] [glob "${tmpfile}_*"]} res]} {
puts "merge failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {exec cmp $tmpfile $srcdir/$subdir/large_output} res]} {
puts "$res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
pass $TEST_NAME
-as_root "/bin/rm -f [glob ${tmpfile}*]"
+eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
diff --git a/testsuite/systemtap.printf/out2b.exp b/testsuite/systemtap.printf/out2b.exp
index 70a98ea2..bb732c42 100644
--- a/testsuite/systemtap.printf/out2b.exp
+++ b/testsuite/systemtap.printf/out2b.exp
@@ -18,24 +18,24 @@ if {[catch {exec mktemp -t staptestXXXXXX} tmpfile]} {
if {[catch {exec stap -b -o $tmpfile $test} res]} {
fail $TEST_NAME
puts "stap failed: $res"
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {eval [list exec $stap_merge_path -o $tmpfile] [glob "${tmpfile}_*"]} res]} {
puts "merge failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {exec cmp $tmpfile $srcdir/$subdir/large_output} res]} {
puts "$res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
pass $TEST_NAME
-as_root "/bin/rm -f [glob ${tmpfile}*]"
+eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
diff --git a/testsuite/systemtap.printf/out3b.exp b/testsuite/systemtap.printf/out3b.exp
index d49625e9..5d82512a 100644
--- a/testsuite/systemtap.printf/out3b.exp
+++ b/testsuite/systemtap.printf/out3b.exp
@@ -18,24 +18,24 @@ if {[catch {exec mktemp -t staptestXXXXXX} tmpfile]} {
if {[catch {exec stap -DMAXACTION=100000 -b -o $tmpfile $test} res]} {
fail $TEST_NAME
puts "stap failed: $res"
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {eval [list exec $stap_merge_path -o $tmpfile] [glob "${tmpfile}_*"]} res]} {
puts "merge failed: $res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
if {[catch {exec cmp $tmpfile $srcdir/$subdir/large_output} res]} {
puts "$res"
fail $TEST_NAME
- as_root "/bin/rm -f [glob ${tmpfile}*]"
+ eval [list exec /bin/rm -f] [glob "${tmpfile}*"]
return
}
pass $TEST_NAME
-as_root "/bin/rm -f [glob ${tmpfile}*]"
+eval [list exec /bin/rm -f] [glob "${tmpfile}*"]