summaryrefslogtreecommitdiff
path: root/tests/ls
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ls')
-rwxr-xr-xtests/ls/abmon-align2
-rwxr-xr-xtests/ls/capability2
-rwxr-xr-xtests/ls/color-clear-to-eol4
-rwxr-xr-xtests/ls/color-dtype-dir6
-rwxr-xr-xtests/ls/color-norm12
-rwxr-xr-xtests/ls/dangle14
-rwxr-xr-xtests/ls/dired2
-rwxr-xr-xtests/ls/follow-slink10
-rwxr-xr-xtests/ls/infloop8
-rwxr-xr-xtests/ls/inode4
-rwxr-xr-xtests/ls/m-option4
-rwxr-xr-xtests/ls/multihardlink20
-rwxr-xr-xtests/ls/nameless-uid4
-rwxr-xr-xtests/ls/no-arg8
-rwxr-xr-xtests/ls/recursive4
-rwxr-xr-xtests/ls/rt-16
-rwxr-xr-xtests/ls/stat-dtype14
-rwxr-xr-xtests/ls/stat-failed6
-rwxr-xr-xtests/ls/stat-free-symlinks6
-rwxr-xr-xtests/ls/symlink-slash4
-rwxr-xr-xtests/ls/x-option6
21 files changed, 73 insertions, 73 deletions
diff --git a/tests/ls/abmon-align b/tests/ls/abmon-align
index e2f8dc22a..d581d8e28 100755
--- a/tests/ls/abmon-align
+++ b/tests/ls/abmon-align
@@ -20,7 +20,7 @@
print_ver_ ls
for mon in $(seq -w 12); do
- touch -d"+$mon month" $mon.ts || framework_failure
+ touch -d"+$mon month" $mon.ts || framework_failure_
done
diff --git a/tests/ls/capability b/tests/ls/capability
index c4762c963..da6182076 100755
--- a/tests/ls/capability
+++ b/tests/ls/capability
@@ -55,7 +55,7 @@ for ex in '' ex=:; do
dir:
\e[${code}mcap_neg\e[0m
cap_pos
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
done
diff --git a/tests/ls/color-clear-to-eol b/tests/ls/color-clear-to-eol
index dc41e3565..164b163c7 100755
--- a/tests/ls/color-clear-to-eol
+++ b/tests/ls/color-clear-to-eol
@@ -20,13 +20,13 @@
print_ver_ ls
long_name=zzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzzz.foo
-touch $long_name || framework_failure
+touch $long_name || framework_failure_
e='\33'
color_code='0;31;42'
c_pre="$e[0m$e[${color_code}m"
c_post="$e[0m$e[K\n"
-printf "$c_pre$long_name$c_post\n" > exp || framework_failure
+printf "$c_pre$long_name$c_post\n" > exp || framework_failure_
env TERM=xterm COLUMNS=80 LS_COLORS="*.foo=$color_code" TIME_STYLE=+T \
ls -og --color=always $long_name > out || fail=1
diff --git a/tests/ls/color-dtype-dir b/tests/ls/color-dtype-dir
index 8f6b279f0..b677240db 100755
--- a/tests/ls/color-dtype-dir
+++ b/tests/ls/color-dtype-dir
@@ -25,9 +25,9 @@ print_ver_ ls
# Don't let a different umask perturb the results.
umask 22
-mkdir d other-writable sticky || framework_failure
-chmod o+w other-writable || framework_failure
-chmod o+t sticky || framework_failure
+mkdir d other-writable sticky || framework_failure_
+chmod o+w other-writable || framework_failure_
+chmod o+t sticky || framework_failure_
ls --color=always > out || fail=1
diff --git a/tests/ls/color-norm b/tests/ls/color-norm
index 20bc1217f..c8691034b 100755
--- a/tests/ls/color-norm
+++ b/tests/ls/color-norm
@@ -30,9 +30,9 @@ export TIME_STYLE="+norm"
# helper to strip ls columns up to "norm" time
qls() { sed 's/-r.*norm/norm/'; }
-touch exe || framework_failure
-chmod u+x exe || framework_failure
-touch nocolor || framework_failure
+touch exe || framework_failure_
+chmod u+x exe || framework_failure_
+touch nocolor || framework_failure_
TCOLORS="no=7:ex=01;32"
@@ -58,10 +58,10 @@ LS_COLORS=$TCOLORS ls -mFU --color nocolor exe >> out || fail=1
# Ensure no coloring is done unless enabled
LS_COLORS=$TCOLORS ls -gGU nocolor exe | qls >> out || fail=1
-cat -A out > out.display || framework_failure
-mv out.display out || framework_failure
+cat -A out > out.display || framework_failure_
+mv out.display out || framework_failure_
-cat <<\EOF > exp || framework_failure
+cat <<\EOF > exp || framework_failure_
^[[0m^[[7mnorm ^[[m^[[01;32mexe^[[0m$
^[[7mnorm nocolor^[[0m$
^[[0m^[[7m^[[m^[[01;32mexe^[[0m ^[[7mnocolor^[[0m$
diff --git a/tests/ls/dangle b/tests/ls/dangle
index 2f722de3d..35035febe 100755
--- a/tests/ls/dangle
+++ b/tests/ls/dangle
@@ -19,13 +19,13 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-ln -s no-such-file dangle || framework_failure
-mkdir -p dir/sub || framework_failure
-ln -s dir slink-to-dir || framework_failure
-mkdir d || framework_failure
-ln -s no-such d/dangle || framework_failure
-printf '? dangle\n' > subdir_Li_exp || framework_failure
-printf 'total 0\n? dangle\n' > subdir_Ls_exp || framework_failure
+ln -s no-such-file dangle || framework_failure_
+mkdir -p dir/sub || framework_failure_
+ln -s dir slink-to-dir || framework_failure_
+mkdir d || framework_failure_
+ln -s no-such d/dangle || framework_failure_
+printf '? dangle\n' > subdir_Li_exp || framework_failure_
+printf 'total 0\n? dangle\n' > subdir_Ls_exp || framework_failure_
# This must exit nonzero.
diff --git a/tests/ls/dired b/tests/ls/dired
index 076ee7aad..18cd1eaa3 100755
--- a/tests/ls/dired
+++ b/tests/ls/dired
@@ -19,7 +19,7 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir dir || framework_failure
+mkdir dir || framework_failure_
LC_MESSAGES=C ls -lR --dired dir > out || fail=1
diff --git a/tests/ls/follow-slink b/tests/ls/follow-slink
index 0715d6962..cb4922b37 100755
--- a/tests/ls/follow-slink
+++ b/tests/ls/follow-slink
@@ -20,15 +20,15 @@
print_ver_ ls
# Isolate output files from directory being listed
-mkdir dir dir/sub dir1 || framework_failure
-cd dir || framework_failure
-ln -s link link || framework_failure
-ln -s ../../dir1 sub/link-to-dir || framework_failure
+mkdir dir dir/sub dir1 || framework_failure_
+cd dir || framework_failure_
+ln -s link link || framework_failure_
+ln -s ../../dir1 sub/link-to-dir || framework_failure_
# Make sure the symlink was created.
# `ln -s link link' succeeds, but creates no file on
# systems running some DJGPP-2.03 libc.
-ls -F link > /dev/null || framework_failure
+ls -F link > /dev/null || framework_failure_
# When explicitly listing a broken link, the command must fail.
diff --git a/tests/ls/infloop b/tests/ls/infloop
index e994de960..34d963311 100755
--- a/tests/ls/infloop
+++ b/tests/ls/infloop
@@ -20,15 +20,15 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir loop || framework_failure
-ln -s ../loop loop/sub || framework_failure
+mkdir loop || framework_failure_
+ln -s ../loop loop/sub || framework_failure_
-cat <<\EOF > exp-out || framework_failure
+cat <<\EOF > exp-out || framework_failure_
loop:
sub
EOF
-cat <<\EOF > exp-err || framework_failure
+cat <<\EOF > exp-err || framework_failure_
ls: loop/sub: not listing already-listed directory
EOF
diff --git a/tests/ls/inode b/tests/ls/inode
index b570fecae..7b28640de 100755
--- a/tests/ls/inode
+++ b/tests/ls/inode
@@ -19,8 +19,8 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-touch f || framework_failure
-ln -s f slink || framework_failure
+touch f || framework_failure_
+ln -s f slink || framework_failure_
# When listed explicitly:
diff --git a/tests/ls/m-option b/tests/ls/m-option
index e0dd447ff..2e6ec03d2 100755
--- a/tests/ls/m-option
+++ b/tests/ls/m-option
@@ -19,8 +19,8 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-seq 2000 > b || framework_failure
-touch a || framework_failure
+seq 2000 > b || framework_failure_
+touch a || framework_failure_
# Before coreutils-5.1.1, the following would output a space after the comma.
diff --git a/tests/ls/multihardlink b/tests/ls/multihardlink
index a9d31f4b7..4a5900073 100755
--- a/tests/ls/multihardlink
+++ b/tests/ls/multihardlink
@@ -20,7 +20,7 @@
print_ver_ ls
working_umask_or_skip_
-touch file file1 || framework_failure
+touch file file1 || framework_failure_
ln file1 file2 || skip_ "can't create hard link"
code_mh='44;37'
code_ex='01;32'
@@ -32,33 +32,33 @@ c_png=$(printf '\033[%sm' $code_png)
# regular file - not hard linked
LS_COLORS="mh=$code_mh" ls -U1 --color=always file > out || fail=1
-printf "file\n" > out_ok || framework_failure
+printf "file\n" > out_ok || framework_failure_
compare out out_ok || fail=1
# hard links
LS_COLORS="mh=$code_mh" ls -U1 --color=always file1 file2 > out || fail=1
printf "$c0${c_mh}file1$c0
${c_mh}file2$c0
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
# hard links and png (hard link coloring takes precedence)
-mv file2 file2.png || framework_failure
+mv file2 file2.png || framework_failure_
LS_COLORS="mh=$code_mh:*.png=$code_png" ls -U1 --color=always file1 file2.png \
> out || fail=1
printf "$c0${c_mh}file1$c0
${c_mh}file2.png$c0
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
# hard links and exe (exe coloring takes precedence)
-chmod a+x file2.png || framework_failure
+chmod a+x file2.png || framework_failure_
LS_COLORS="mh=$code_mh:*.png=$code_png:ex=$code_ex" \
ls -U1 --color=always file1 file2.png > out || fail=1
-chmod a-x file2.png || framework_failure
+chmod a-x file2.png || framework_failure_
printf "$c0${c_ex}file1$c0
${c_ex}file2.png$c0
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
# hard links and png (hard link coloring disabled => png coloring enabled)
@@ -66,7 +66,7 @@ LS_COLORS="mh=00:*.png=$code_png" ls -U1 --color=always file1 file2.png > out \
|| fail=1
printf "file1
$c0${c_png}file2.png$c0
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
# hard links and png (hard link coloring not enabled explicitly => png coloring)
@@ -74,7 +74,7 @@ LS_COLORS="*.png=$code_png" ls -U1 --color=always file1 file2.png > out \
|| fail=1
printf "file1
$c0${c_png}file2.png$c0
-" > out_ok || framework_failure
+" > out_ok || framework_failure_
compare out out_ok || fail=1
Exit $fail
diff --git a/tests/ls/nameless-uid b/tests/ls/nameless-uid
index a0de6ce92..49521037e 100755
--- a/tests/ls/nameless-uid
+++ b/tests/ls/nameless-uid
@@ -32,8 +32,8 @@ if test x$nameless_uid = x; then
skip_ "couldn't find a nameless UID"
fi
-touch f || framework_failure
-chown $nameless_uid f || framework_failure
+touch f || framework_failure_
+chown $nameless_uid f || framework_failure_
set -- `ls -o f` || fail=1
diff --git a/tests/ls/no-arg b/tests/ls/no-arg
index 5e26114b4..f61846b97 100755
--- a/tests/ls/no-arg
+++ b/tests/ls/no-arg
@@ -19,11 +19,11 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir -p dir/subdir || framework_failure
-touch dir/subdir/file2 || framework_failure
-ln -s f symlink || framework_failure
+mkdir -p dir/subdir || framework_failure_
+touch dir/subdir/file2 || framework_failure_
+ln -s f symlink || framework_failure_
-cat > exp <<\EOF || framework_failure
+cat > exp <<\EOF || framework_failure_
dir
exp
out
diff --git a/tests/ls/recursive b/tests/ls/recursive
index 4e42890de..677b5fdb2 100755
--- a/tests/ls/recursive
+++ b/tests/ls/recursive
@@ -20,8 +20,8 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir x y a b c a/1 a/2 a/3 || framework_failure
-touch f a/1/I a/1/II || framework_failure
+mkdir x y a b c a/1 a/2 a/3 || framework_failure_
+touch f a/1/I a/1/II || framework_failure_
# This first example is from Andreas Schwab's bug report.
diff --git a/tests/ls/rt-1 b/tests/ls/rt-1
index f546c9ed0..05d2a039f 100755
--- a/tests/ls/rt-1
+++ b/tests/ls/rt-1
@@ -21,9 +21,9 @@ print_ver_ ls touch
date=1998-01-15
-touch -d "$date" c || framework_failure
-touch -d "$date" a || framework_failure
-touch -d "$date" b || framework_failure
+touch -d "$date" c || framework_failure_
+touch -d "$date" a || framework_failure_
+touch -d "$date" b || framework_failure_
ls -1t a b c > out || fail=1
diff --git a/tests/ls/stat-dtype b/tests/ls/stat-dtype
index dfa2dd555..8ee94344f 100755
--- a/tests/ls/stat-dtype
+++ b/tests/ls/stat-dtype
@@ -27,18 +27,18 @@ print_ver_ ls
# Skip this test unless "." is on a file system with useful d_type info.
# FIXME: This uses "ls -p" to decide whether to test "ls" with other options,
# but if ls's d_type code is buggy then "ls -p" might be buggy too.
-mkdir -p c/d || framework_failure
-chmod a-x c || framework_failure
+mkdir -p c/d || framework_failure_
+chmod a-x c || framework_failure_
if test "X`ls -p c 2>&1`" != Xd/; then
skip_ "'.' is not on a suitable file system for this test"
fi
-mkdir d || framework_failure
-ln -s / d/s || framework_failure
-chmod 600 d || framework_failure
+mkdir d || framework_failure_
+ln -s / d/s || framework_failure_
+chmod 600 d || framework_failure_
-mkdir -p e/a2345 e/b || framework_failure
-chmod 600 e || framework_failure
+mkdir -p e/a2345 e/b || framework_failure_
+chmod 600 e || framework_failure_
ls --file-type d > out || fail=1
diff --git a/tests/ls/stat-failed b/tests/ls/stat-failed
index 3ce941350..5a22c7bf9 100755
--- a/tests/ls/stat-failed
+++ b/tests/ls/stat-failed
@@ -21,9 +21,9 @@
print_ver_ ls
skip_if_root_
-mkdir d || framework_failure
-ln -s / d/s || framework_failure
-chmod 600 d || framework_failure
+mkdir d || framework_failure_
+ln -s / d/s || framework_failure_
+chmod 600 d || framework_failure_
ls -Log d > out
diff --git a/tests/ls/stat-free-symlinks b/tests/ls/stat-free-symlinks
index 21f5c1268..ab2011925 100755
--- a/tests/ls/stat-free-symlinks
+++ b/tests/ls/stat-free-symlinks
@@ -20,9 +20,9 @@
print_ver_ ls
require_strace_ stat
-touch x || framework_failure
-chmod a+x x || framework_failure
-ln -s x link-to-x || framework_failure
+touch x || framework_failure_
+chmod a+x x || framework_failure_
+ln -s x link-to-x || framework_failure_
# ls from coreutils 6.9 would unnecessarily stat a symlink in an unusual case:
diff --git a/tests/ls/symlink-slash b/tests/ls/symlink-slash
index b74e8d172..d70e4cd7b 100755
--- a/tests/ls/symlink-slash
+++ b/tests/ls/symlink-slash
@@ -19,8 +19,8 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir dir || framework_failure
-ln -s dir symlink || framework_failure
+mkdir dir || framework_failure_
+ln -s dir symlink || framework_failure_
set `ls -l symlink/`
diff --git a/tests/ls/x-option b/tests/ls/x-option
index 1bd152acb..7a451f54b 100755
--- a/tests/ls/x-option
+++ b/tests/ls/x-option
@@ -19,9 +19,9 @@
. "${srcdir=.}/init.sh"; path_prepend_ ../src
print_ver_ ls
-mkdir subdir || framework_failure
-touch subdir/b || framework_failure
-touch subdir/a || framework_failure
+mkdir subdir || framework_failure_
+touch subdir/b || framework_failure_
+touch subdir/a || framework_failure_
# Coreutils 6.8 and 6.9 would output this in the wrong order.