summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2009-01-28 16:42:20 +0000
committerPádraig Brady <P@draigBrady.com>2009-01-28 16:43:52 +0000
commit05a50b7848e235289b32fa8c712c38fb58209893 (patch)
tree366c9cf4e28bc1a8cd46a3781cb028f67f777508
parent2f61473e85f984f8b65dc149553241ebef7b5e76 (diff)
downloadcoreutils-05a50b7848e235289b32fa8c712c38fb58209893.tar.xz
tests: Fixup shred-passes test
* tests/misc/shred-passes: Set the $fail variable correctly. The issue was noticed by Jim Meyering.
-rwxr-xr-xtests/misc/shred-passes9
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/misc/shred-passes b/tests/misc/shred-passes
index 07823b109..712c7bd67 100755
--- a/tests/misc/shred-passes
+++ b/tests/misc/shred-passes
@@ -23,6 +23,7 @@ fi
. $srcdir/test-lib.sh
+
# shred a single letter, zero length file which should result in
# 3 random passes and a single rename.
touch f || framework_failure
@@ -32,10 +33,12 @@ shred: f: pass 2/3 (random)...
shred: f: pass 3/3 (random)...
shred: f: removing
shred: f: renamed to 0
-shred: f: removed" > exp
+shred: f: removed" > exp || framework_failure
+
+fail=0
-shred -v -u f 2>out
+shred -v -u f 2>out || fail=1
-compare exp out || fail
+compare exp out || fail=1
Exit $fail