| #! /bin/sh |
| |
| |
| |
| |
| |
| |
| |
| |
| . "$suitedir/rsync.fns" |
| |
| hands_setup |
| |
| cd "$tmpdir" |
| |
| |
| $RSYNC -av --exclude=foobar.baz "$fromdir/" "$chkdir/" |
| |
| $RSYNC -av --only-write-batch=BATCH --exclude=foobar.baz "$fromdir/" "$todir/missing/" |
| test -d "$todir/missing" && test_fail "--only-write-batch should not have created destination dir" |
| |
| runtest "--read-batch (only)" 'checkit "$RSYNC -av --read-batch=BATCH \"$todir\"" "$chkdir" "$todir"' |
| |
| rm -rf "$todir" BATCH* |
| runtest "local --write-batch" 'checkit "$RSYNC -av --write-batch=BATCH \"$fromdir/\" \"$todir\"" "$fromdir" "$todir"' |
| |
| rm -rf "$todir" |
| runtest "--read-batch" 'checkit "$RSYNC -av --read-batch=BATCH \"$todir\"" "$fromdir" "$todir"' |
| |
| build_rsyncd_conf |
| |
| RSYNC_CONNECT_PROG="$RSYNC --config=$conf --daemon" |
| export RSYNC_CONNECT_PROG |
| |
| rm -rf "$todir" |
| runtest "daemon sender --write-batch" 'checkit "$RSYNC -av --write-batch=BATCH rsync://localhost/test-from/ \"$todir\"" "$chkdir" "$todir"' |
| |
| rm -rf "$todir" |
| runtest "--read-batch from daemon" 'checkit "$RSYNC -av --read-batch=BATCH \"$todir\"" "$chkdir" "$todir"' |
| |
| rm -rf "$todir" |
| runtest "BATCH.sh use of --read-batch" 'checkit "./BATCH.sh" "$chkdir" "$todir"' |
| |
| runtest "do-nothing re-run of batch" 'checkit "./BATCH.sh" "$chkdir" "$todir"' |
| |
| rm -rf "$todir" |
| mkdir "$todir" || test_fail "failed to restore empty destination directory" |
| runtest "daemon recv --write-batch" 'checkit "\"$ignore23\" $RSYNC -av --write-batch=BATCH \"$fromdir/\" rsync://localhost/test-to" "$chkdir" "$todir"' |
| |
| |
| exit 0 |