summaryrefslogtreecommitdiff
path: root/t/t5700-clone-reference.sh
diff options
context:
space:
mode:
authorLibravatar Daniel Barkalow <barkalow@iabervon.org>2008-05-22 18:03:08 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2008-05-22 23:33:50 -0700
commit4ba776c231f27e69435d76bac98d033db859cd6f (patch)
tree5d1106347f7732bf117fc3bb2b5d1c38f94b8ca7 /t/t5700-clone-reference.sh
parentclone: fall back to copying if hardlinking fails (diff)
downloadtgif-4ba776c231f27e69435d76bac98d033db859cd6f.tar.xz
Test that --reference actually suppresses fetching referenced objects
Signed-off-by: Daniel Barkalow <barkalow@iabervon.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t5700-clone-reference.sh')
-rwxr-xr-xt/t5700-clone-reference.sh9
1 files changed, 8 insertions, 1 deletions
diff --git a/t/t5700-clone-reference.sh b/t/t5700-clone-reference.sh
index b6a54867b4..58a97f1ed1 100755
--- a/t/t5700-clone-reference.sh
+++ b/t/t5700-clone-reference.sh
@@ -8,6 +8,8 @@ test_description='test clone --reference'
base_dir=`pwd`
+U=$base_dir/UPLOAD_LOG
+
test_expect_success 'preparing first repository' \
'test_create_repo A && cd A &&
echo first > file1 &&
@@ -50,8 +52,13 @@ diff expected current'
cd "$base_dir"
+rm -f $U
+
test_expect_success 'cloning with reference (no -l -s)' \
-'git clone --reference B file://`pwd`/A D'
+'GIT_DEBUG_SEND_PACK=3 git clone --reference B file://`pwd`/A D 3>$U'
+
+test_expect_success 'fetched no objects' \
+'! grep "^want" $U'
cd "$base_dir"