summaryrefslogtreecommitdiff
path: root/testsuite/daemon.test
diff options
context:
space:
mode:
authorWayne Davison <wayne@opencoder.net>2020-06-23 15:53:47 -0700
committerWayne Davison <wayne@opencoder.net>2020-06-23 15:53:47 -0700
commitd1fdf9ff8dad4f64259d78f8bc912aed782848d9 (patch)
tree856d58da55eeaf58c2e0f6563568b3c950597bac /testsuite/daemon.test
parente93f40d8b4068a0170ec0d8a6d6ab74850ba358f (diff)
downloadrsync-d1fdf9ff8dad4f64259d78f8bc912aed782848d9.tar.gz
Avoid -U if --atimes is disabled.
Diffstat (limited to 'testsuite/daemon.test')
-rw-r--r--testsuite/daemon.test13
1 files changed, 7 insertions, 6 deletions
diff --git a/testsuite/daemon.test b/testsuite/daemon.test
index a8acd04e..a736ee83 100644
--- a/testsuite/daemon.test
+++ b/testsuite/daemon.test
@@ -91,12 +91,13 @@ drwxr-xr-x DIR ####/##/## ##:##:## foo
EOT
diff $diffopt "$chkfile" "$outfile" || test_fail "test 3 failed"
-$RSYNC -rU localhost::test-from/f* \
- | sed "$FILE_REPL" | sed "$DIR_REPL" | sed "$LS_REPL" \
- | tee "$outfile"
-cat <<EOT >"$chkfile"
+if $RSYNC --version | grep "[, ] atimes" >/dev/null; then
+ $RSYNC -rU localhost::test-from/f* \
+ | sed "$FILE_REPL" | sed "$DIR_REPL" | sed "$LS_REPL" \
+ | tee "$outfile"
+ cat <<EOT >"$chkfile"
drwxr-xr-x DIR ####/##/## ##:##:## foo
-rw-r--r-- 4 ####/##/## ##:##:## ####/##/## ##:##:## foo/one
EOT
-diff $diffopt "$chkfile" "$outfile" || test_fail "test 3 failed"
-
+ diff $diffopt "$chkfile" "$outfile" || test_fail "test 3 failed"
+fi