summaryrefslogtreecommitdiff
path: root/tests/cp
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2011-05-10 08:14:16 +0100
committerPádraig Brady <P@draigBrady.com>2011-05-14 10:41:29 +0100
commit5116103826c1776be0661bd591acd08fbefe9767 (patch)
tree45aaee0a87b197a6da572694cf3a434255a2395c /tests/cp
parent27873f1deb69745c79d403bbb8e1145bc18f55b8 (diff)
downloadcoreutils-5116103826c1776be0661bd591acd08fbefe9767.tar.xz
tests: refactor more tests to use mkfifo_or_skip_
* tests/cp/existing-perm-race: s/mkfifo/mkfifo_or_skip_/ * tests/cp/file-perm-race: Likewise. * tests/cp/parent-perm-race: Likewise. * tests/cp/special-f: Likewise. * tests/dd/reblock: Likewise. * tests/ls/file-type: Likewise. * tests/misc/cat-buf: Likewise. * tests/misc/mknod: Likewise. * tests/misc/printf-surprise: Likewise. * tests/misc/selinux: Likewise. * tests/misc/sort-spinlock-abuse: Likewise. * tests/misc/stdbuf: Likewise. * tests/misc/tac-continue: Likewise. * tests/init.cfg: Improve the error message when skipping.
Diffstat (limited to 'tests/cp')
-rwxr-xr-xtests/cp/existing-perm-race3
-rwxr-xr-xtests/cp/file-perm-race3
-rwxr-xr-xtests/cp/parent-perm-race3
-rwxr-xr-xtests/cp/special-f4
4 files changed, 5 insertions, 8 deletions
diff --git a/tests/cp/existing-perm-race b/tests/cp/existing-perm-race
index 6afe1a2fa..a2a6493fa 100755
--- a/tests/cp/existing-perm-race
+++ b/tests/cp/existing-perm-race
@@ -30,8 +30,7 @@ g2=$2
umask 077
-mkfifo fifo ||
- skip_test_ "fifos not supported"
+mkfifo_or_skip_ fifo
touch fifo-copy &&
chgrp $g1 fifo &&
diff --git a/tests/cp/file-perm-race b/tests/cp/file-perm-race
index 1e84b1eb5..41f01efce 100755
--- a/tests/cp/file-perm-race
+++ b/tests/cp/file-perm-race
@@ -23,8 +23,7 @@ print_ver_ cp
require_local_dir_
umask 022
-mkfifo fifo ||
- skip_test_ "fifos not supported"
+mkfifo_or_skip_ fifo
# Copy a fifo's contents. That way, we can examine the
# destination permissions before they're finalized.
diff --git a/tests/cp/parent-perm-race b/tests/cp/parent-perm-race
index 4af3b69d0..366efbaa7 100755
--- a/tests/cp/parent-perm-race
+++ b/tests/cp/parent-perm-race
@@ -29,8 +29,7 @@ chmod g+s d 2>/dev/null # The cp test is valid either way.
for attr in mode ownership
do
- mkfifo $attr/fifo ||
- skip_test_ "fifos not supported"
+ mkfifo_or_skip_ $attr/fifo
# Copy a fifo's contents. That way, we can examine d/$attr's
# state while cp is running.
diff --git a/tests/cp/special-f b/tests/cp/special-f
index fb7550077..3f63921f1 100755
--- a/tests/cp/special-f
+++ b/tests/cp/special-f
@@ -20,8 +20,8 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ cp
-mkfifo fifo ||
- skip_test_ "fifos not supported"
+mkfifo_or_skip_ fifo
+
touch e || framework-failure