From c42da632e9d46240e6fa3530dd44bf22307cc97b Mon Sep 17 00:00:00 2001 From: Zoran Zaric Date: Mon, 6 Dec 2010 13:00:03 +0100 Subject: [PATCH] Adds testcases for --strip and --strip-path. Signed-off-by: Zoran Zaric --- t/test.sh | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/t/test.sh b/t/test.sh index 0c83ba7..a38eb56 100755 --- a/t/test.sh +++ b/t/test.sh @@ -303,3 +303,37 @@ WVPASSEQ "$(bup ls exclude-from/latest/$TOP/$D/)" "a b f" rm $EXCLUDE_FILE + +WVSTART "strip" +D=strip.tmp +rm -rf $D +mkdir $D +export BUP_DIR="$D/.bup" +WVPASS bup init +touch $D/a +WVPASS bup random 128k >$D/b +mkdir $D/d $D/d/e +WVPASS bup random 512 >$D/f +WVPASS bup index -ux $D +bup save --strip -n strip $D +WVPASSEQ "$(bup ls strip/latest/)" "a +b +d/ +f" + +WVSTART "strip-path" +D=strip-path.tmp +rm -rf $D +mkdir $D +export BUP_DIR="$D/.bup" +WVPASS bup init +touch $D/a +WVPASS bup random 128k >$D/b +mkdir $D/d $D/d/e +WVPASS bup random 512 >$D/f +WVPASS bup index -ux $D +bup save --strip-path $TOP -n strip-path $D +WVPASSEQ "$(bup ls strip-path/latest/$D/)" "a +b +d/ +f" -- 2.39.2