summaryrefslogtreecommitdiff
path: root/tests/ls/time-1
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2001-05-20 20:43:52 +0000
committerJim Meyering <jim@meyering.net>2001-05-20 20:43:52 +0000
commitf7b3fa35e68032363b92fc73a12e1bd62bbd1d41 (patch)
tree9c97b65676d7cbe953acced4db45148b633bd98c /tests/ls/time-1
parentc9277ec2a9f7a3c4cfcd42740158a340d7cb973d (diff)
downloadcoreutils-f7b3fa35e68032363b92fc73a12e1bd62bbd1d41.tar.xz
Unset QUOTING_STYLE and TIME_STYLE. Set TZ.
Adjust to change in full-time format. Fix typo in failure messages (-a and -m were interchanged).
Diffstat (limited to 'tests/ls/time-1')
-rwxr-xr-xtests/ls/time-132
1 files changed, 18 insertions, 14 deletions
diff --git a/tests/ls/time-1 b/tests/ls/time-1
index 104796742..f3bcf6f9d 100755
--- a/tests/ls/time-1
+++ b/tests/ls/time-1
@@ -6,10 +6,14 @@ if test "$VERBOSE" = yes; then
ls --version
fi
-# Date output in ls -l is locale-sensitive, so this test fails if the
-# current locale produces a date that doesn't match the embedded value
-# here (Jan 15 23:00:00 1998), which is in the C (POSIX) locale.
-. $srcdir/../lang-default
+# Avoid any possible glitches due to daylight-saving changes near the
+# time stamps used during the test.
+TZ=UTC0
+export TZ
+
+# Avoid glitches due to the environment specifying `ls' styles.
+unset QUOTING_STYLE
+unset TIME_STYLE
tmp=t-ls.$$
@@ -51,15 +55,15 @@ ln c d || framework_failure=1
# Before we go any further, verify that touch's -m option works.
set -- `ls --full -l a`
case "$*" in
- *'Jan 15 23:00:00 1998 a') ;;
+ *" $t3:00.000000000 +0000 a") ;;
*)
# This might be what's making HPUX 11 systems fail this test.
- cat >&2 << \EOF
-A basic test of touch -a has just failed, so the subsequent
+ cat >&2 << EOF
+A basic test of touch -m has just failed, so the subsequent
tests in this file will not be run.
-In the output below, the date of last modification for `a' should
-have been Jan 15 23:00:00 1998.
+In the output below, the date of last modification for \`a' should
+have been $t3.
EOF
#`
ls --full -l a
@@ -70,15 +74,15 @@ esac
# Now test touch's -a option.
set -- `ls --full -lu a`
case "$*" in
- *'Jan 14 11:00:00 1998 a') ;;
+ *" $u1:00.000000000 +0000 a") ;;
*)
# This might be what's making HPUX 11 systems fail this test.
- cat >&2 << \EOF
-A basic test of touch -m has just failed, so the subsequent
+ cat >&2 << EOF
+A basic test of touch -a has just failed, so the subsequent
tests in this file will not be run.
-In the output below, the date of last access for `a' should
-have been Jan 14 11:00:00 1998.
+In the output below, the date of last access for \`a' should
+have been $u1.
EOF
ls --full -lu a
framework_failure=1