X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=t%2Ft5000-tar-tree.sh;h=d9068981f8475c37d30e584bc6b795075a2f3063;hb=247f9d23da8cfd255533433ad2aa07d172afac0b;hp=889842e7fc0cf80f7e8b6016a508bffdb0399d32;hpb=b1b7cedcfe351870d4c56f664695a25f8651d5b3;p=git.git diff --git a/t/t5000-tar-tree.sh b/t/t5000-tar-tree.sh index 889842e7f..527c9e754 100755 --- a/t/t5000-tar-tree.sh +++ b/t/t5000-tar-tree.sh @@ -242,6 +242,14 @@ test_expect_success \ 'git archive --list outside of a git repo' \ 'GIT_DIR=some/non-existing/directory git archive --list' +test_expect_success 'clients cannot access unreachable commits' ' + test_commit unreachable && + sha1=`git rev-parse HEAD` && + git reset --hard HEAD^ && + git archive $sha1 >remote.tar && + test_must_fail git archive --remote=. $sha1 >remote.tar +' + test_expect_success 'git-archive --prefix=olde-' ' git archive --prefix=olde- >h.tar HEAD && (