summaryrefslogtreecommitdiff
path: root/tests/touch
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@altlinux.org>2009-11-22 18:37:34 +0300
committerJim Meyering <meyering@redhat.com>2009-11-22 16:40:18 +0100
commit9cf9f8e1e05c07e9dcf707e604b37c9a8f736c29 (patch)
tree2ef155c455a48388eb9c0f87bb77a1020d1f9a76 /tests/touch
parentad1f07b3c450a3804b144b655de6e2c45f374ef1 (diff)
downloadcoreutils-9cf9f8e1e05c07e9dcf707e604b37c9a8f736c29.tar.xz
tests: do not fail on read-only root file system
* tests/touch/not-owner: Handle the case when the root file system is mounted read-only. Reported by Solar Designer.
Diffstat (limited to 'tests/touch')
-rwxr-xr-xtests/touch/not-owner5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/touch/not-owner b/tests/touch/not-owner
index 3dd8a8086..9cfa026bb 100755
--- a/tests/touch/not-owner
+++ b/tests/touch/not-owner
@@ -42,7 +42,10 @@ touch / > out 2>&1 && fail=1
# On SunOS4, EPERM is `Not owner'.
# On some *BSD systems it's `Operation not permitted'.
-for msg in 'Not owner' 'Operation not permitted' 'Permission denied'; do
+# On a system where root file system is mounted read-only
+# it's `Read-only file system'.
+for msg in 'Not owner' 'Operation not permitted' 'Permission denied' \
+ 'Read-only file system'; do
cat > exp <<EOF
touch: setting times of \`/': $msg
EOF