summaryrefslogtreecommitdiff
path: root/tests/touch/trailing-slash.sh
diff options
context:
space:
mode:
authorIgor Pashev <pashev.igor@gmail.com>2015-07-04 17:13:50 +0300
committerIgor Pashev <pashev.igor@gmail.com>2015-07-04 17:13:50 +0300
commit71cd8e3a743046573744123777061b64881bf372 (patch)
tree82522befe647f4fff186a5630cad0cad33f8ef53 /tests/touch/trailing-slash.sh
parentc18578632fd3c9e513e613a86ba2b7c4ebee6c45 (diff)
downloadcoreutils-upstream.tar.gz
Imported Upstream version 8.24upstream/8.24upstream
Diffstat (limited to 'tests/touch/trailing-slash.sh')
-rwxr-xr-xtests/touch/trailing-slash.sh22
1 files changed, 11 insertions, 11 deletions
diff --git a/tests/touch/trailing-slash.sh b/tests/touch/trailing-slash.sh
index 7e6eb908..2d57007b 100755
--- a/tests/touch/trailing-slash.sh
+++ b/tests/touch/trailing-slash.sh
@@ -1,7 +1,7 @@
#!/bin/sh
# Ensure that touch honors trailing slash.
-# Copyright (C) 2009-2014 Free Software Foundation, Inc.
+# Copyright (C) 2009-2015 Free Software Foundation, Inc.
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -29,22 +29,22 @@ ln -s dir link2 || framework_failure_
# Trailing slash can only appear on directory or symlink-to-directory.
# Up through coreutils 8.0, Solaris 9 failed these tests.
-touch no-file/ && fail=1
-touch file/ && fail=1
-touch dangling/ && fail=1
-touch loop/ && fail=1
-touch link1/ && fail=1
+returns_ 1 touch no-file/ || fail=1
+returns_ 1 touch file/ || fail=1
+returns_ 1 touch dangling/ || fail=1
+returns_ 1 touch loop/ || fail=1
+returns_ 1 touch link1/ || fail=1
touch dir/ || fail=1
# -c silences ENOENT, but not ENOTDIR or ELOOP
touch -c no-file/ || fail=1
-touch -c file/ && fail=1
+returns_ 1 touch -c file/ || fail=1
touch -c dangling/ || fail=1
-touch -c loop/ && fail=1
-touch -c link1/ && fail=1
+returns_ 1 touch -c loop/ || fail=1
+returns_ 1 touch -c link1/ || fail=1
touch -c dir/ || fail=1
-test -f no-file && fail=1
-test -f nowhere && fail=1
+returns_ 1 test -f no-file || fail=1
+returns_ 1 test -f nowhere || fail=1
# Trailing slash dereferences a symlink, even with -h.
# mtime is sufficient to show pass (besides, lstat changes atime of