diff options
author | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2015-07-04 19:03:44 +0100 |
---|---|---|
committer | Ian Jackson <ijackson@chiark.greenend.org.uk> | 2015-07-04 21:38:48 +0100 |
commit | 889b45aa70ebb3aaecda8802eb9ab9b2015ce642 (patch) | |
tree | 676fd9e7cffb5abe7b54c217b988645602abb596 /tests/tests/tag-updates | |
parent | 8c95b29b79a159e5153f51affece9cf9314b4d84 (diff) |
Test suite: Check tag updates work properly
Diffstat (limited to 'tests/tests/tag-updates')
-rwxr-xr-x | tests/tests/tag-updates | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/tests/tag-updates b/tests/tests/tag-updates new file mode 100755 index 0000000..544be16 --- /dev/null +++ b/tests/tests/tag-updates @@ -0,0 +1,38 @@ +#!/bin/bash +set -e +. tests/lib + +t-tstunt-parsechangelog +t-prep-newpackage example 1.0 + +cd $p +revision=1 +t-dgit build +t-dgit push --new + +tagref=`t-v-tag` +tagname=${tn#refs/tags} + +(set -e + cd $tmp/git/$p.git + git tag -m UNWANTED unwanted dgit/sid) + +fetch-check () { + t-dgit fetch + t-ref-same-exact $tagref + t-refs-notexist refs/tags/unwanted + git rev-parse refs/dgit-fetch/sid/tags/unwanted +} + +t-ref-same-exact $tagref +fetch-check + +git tag -d $tagname +fetch-check + +git tag -f -m BOGUS $tagname HEAD +t-refs-same-start +t-ref-same-exact $tagref +fetch-check + +echo done. |