Added support for multiple --*-dest options.
[rsync/rsync.git] / testsuite / compare-dest.test
CommitLineData
dce70db3
WD
1#! /bin/sh
2
0abda1b1 3# Copyright (C) 2004 by Wayne Davison <wayned@samba.org>
dce70db3
WD
4
5# This program is distributable under the terms of the GNU GPL see
6# COPYING).
7
0abda1b1 8# Test rsync handling of the --compare-dest option.
dce70db3
WD
9
10. "$suitedir/rsync.fns"
11
12set -x
13
14altdir="$tmpdir/alt"
15
16# Build some files/dirs/links to copy
17
18hands_setup
19
3381b77d 20# Setup the alt and chk dirs
dce70db3
WD
21$RSYNC -av --include=text --include='*/' --exclude='*' "$fromdir/" "$altdir/"
22
3381b77d
WD
23sleep 1
24touch "$fromdir/dir/text"
25
26$RSYNC -av --exclude=/text "$fromdir/" "$chkdir/"
27
28# Let's do it!
29checkit "$RSYNC -avv --no-whole-file --compare-dest=\"$altdir\" \
30 \"$fromdir/\" \"$todir/\"" "$chkdir" "$todir"
dce70db3
WD
31
32# The script would have aborted on error, so getting here means we've won.
33exit 0