Some more minor changes for the skip/missing/dry_run code.
[rsync/rsync.git] / testsuite / missing.test
CommitLineData
83a8ca7b
MM
1#! /bin/sh
2
3# This program is distributable under the terms of the GNU GPL (see
4# COPYING).
5
6# Test three bugs fixed by my redoing of the missing_below logic.
7
8. $srcdir/testsuite/rsync.fns
9
6e0bf4d8 10makepath "$fromdir/subdir" "$todir"
83a8ca7b
MM
11echo data >"$fromdir/subdir/file"
12echo data >"$todir/other"
13
14# Test 1: Too much "not creating new..." output on a dry run
15$RSYNC -n -r --ignore-non-existing -vv "$fromdir/" "$todir/" | tee "$scratchdir/out"
16if grep 'not creating new.*subdir/file' "$scratchdir/out" >/dev/null; then
17 test_fail 'test 1 failed'
18fi
19
20# Test 2: Attempt to make a fuzzy dirlist for a dir not created on a dry run
21$RSYNC -n -r -R --no-implied-dirs -y "$fromdir/./subdir/file" "$todir/" \
22 || test_fail 'test 2 failed'
23
24# Test 3: --delete-after pass skipped when last dir is dry-missing
25$RSYNC -n -r --delete-after -i "$fromdir/" "$todir/" | tee "$scratchdir/out"
6e0bf4d8 26grep '^\*deleting * other' "$scratchdir/out" >/dev/null \
83a8ca7b 27 || test_fail 'test 3 failed'