summaryrefslogtreecommitdiff
path: root/t/t5000-tar-tree.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2014-10-08 13:05:25 -0700
committerJunio C Hamano <gitster@pobox.com>2014-10-08 13:05:26 -0700
commitb2c45f5b961b3b5d894fb723d2031e8ff41cadf7 (patch)
treeae94ddbc40beb6c552d4c6907eff133831be930f /t/t5000-tar-tree.sh
parentfb06b5280ea05d75515fa780cf08d4ec9d6fe101 (diff)
parented22b4173bd8d6dbce6236480bd30a63dd54834e (diff)
downloadgit-b2c45f5b961b3b5d894fb723d2031e8ff41cadf7.tar.gz
Merge branch 'nd/archive-pathspec'
"git archive" learned to filter what gets archived with pathspec. * nd/archive-pathspec: archive: support filtering paths with glob
Diffstat (limited to 't/t5000-tar-tree.sh')
-rwxr-xr-xt/t5000-tar-tree.sh14
1 files changed, 14 insertions, 0 deletions
diff --git a/t/t5000-tar-tree.sh b/t/t5000-tar-tree.sh
index 7b8babd89b..d01bbdc968 100755
--- a/t/t5000-tar-tree.sh
+++ b/t/t5000-tar-tree.sh
@@ -305,4 +305,18 @@ test_expect_success GZIP 'remote tar.gz can be disabled' '
>remote.tar.gz
'
+test_expect_success 'archive and :(glob)' '
+ git archive -v HEAD -- ":(glob)**/sh" >/dev/null 2>actual &&
+ cat >expect <<EOF &&
+a/
+a/bin/
+a/bin/sh
+EOF
+ test_cmp expect actual
+'
+
+test_expect_success 'catch non-matching pathspec' '
+ test_must_fail git archive -v HEAD -- "*.abc" >/dev/null
+'
+
test_done