summaryrefslogtreecommitdiff
path: root/t/t1512-rev-parse-disambiguation.sh
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2012-07-02 23:35:05 -0700
committerJunio C Hamano <gitster@pobox.com>2012-07-09 16:42:22 -0700
commitdaba53aeaf6565b4bbdd6783c659480453ec3c5e (patch)
treec4d4c9ef0161760d0ffb2f051b683fd3f50d8db7 /t/t1512-rev-parse-disambiguation.sh
parentd5f6b1d756a29255efedee3cb6e8526aedcfeb00 (diff)
downloadgit-daba53aeaf6565b4bbdd6783c659480453ec3c5e.tar.gz
sha1_name.c: add support for disambiguating other types
This teaches the revision parser that in "$name:$path" (used for a blob object name), "$name" must be a tree-ish. There are many more places where we know what types of objects are called for. This patch adds support for "commit", "treeish", "tree", and "blob", which could be used in the following contexts: - "git apply --build-fake-ancestor" reads the "index" lines from the patch; they must name blob objects (not even "blob-ish"); - "git commit-tree" reads a tree object name (not "tree-ish"), and zero or more commit object names (not "committish"); - "git reset $rev" wants a committish; "git reset $rev -- $path" wants a treeish. They will come in later patches in the series. Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 't/t1512-rev-parse-disambiguation.sh')
-rwxr-xr-xt/t1512-rev-parse-disambiguation.sh2
1 files changed, 1 insertions, 1 deletions
diff --git a/t/t1512-rev-parse-disambiguation.sh b/t/t1512-rev-parse-disambiguation.sh
index da25fad924..fbd3658ca8 100755
--- a/t/t1512-rev-parse-disambiguation.sh
+++ b/t/t1512-rev-parse-disambiguation.sh
@@ -45,7 +45,7 @@ test_expect_success 'warn ambiguity when no candidate matches type hint' '
grep "short SHA1 000000000 is ambiguous" actual
'
-test_expect_failure 'disambiguate tree-ish' '
+test_expect_success 'disambiguate tree-ish' '
# feed tree-ish in an unambiguous way
git rev-parse --verify 0000000000cdc:a0blgqsjc &&