summaryrefslogtreecommitdiff
path: root/t
diff options
context:
space:
mode:
Diffstat (limited to 't')
-rwxr-xr-xt/t6120-describe.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/t/t6120-describe.sh b/t/t6120-describe.sh
index 1d20854609..c0e5b2a627 100755
--- a/t/t6120-describe.sh
+++ b/t/t6120-describe.sh
@@ -186,4 +186,16 @@ test_expect_success 'name-rev with exact tags' '
test_cmp expect actual
'
+test_expect_success 'describe --contains with the exact tags' '
+ echo "A^0" >expect &&
+ tag_object=$(git rev-parse refs/tags/A) &&
+ git describe --contains $tag_object >actual &&
+ test_cmp expect actual &&
+
+ echo "A^0" >expect &&
+ tagged_commit=$(git rev-parse "refs/tags/A^0") &&
+ git describe --contains $tagged_commit >actual &&
+ test_cmp expect actual
+'
+
test_done