chiark / gitweb /
Test suite: oldnewtagalt: New test
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Wed, 21 Sep 2016 20:19:46 +0000 (21:19 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Mon, 26 Sep 2016 00:16:58 +0000 (01:16 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
TODO.BRANCH
debian/tests/control
tests/tests/oldnewtagalt [new file with mode: 0755]

index a8f5deb..488765c 100644 (file)
@@ -13,11 +13,6 @@ TESTS
 
 Want tests for
 
- - start repo with old tag, push with new tag, run
-   "old" dgit to push again with new tag, push again with
-   old tag
-
-
  * Test all three new --quilt=unapplied|gbp|dpm
 
 
index e227e2b..df9fdf8 100644 (file)
@@ -21,7 +21,7 @@ Tests-Directory: tests/tests
 Depends: dgit, dgit-infrastructure, devscripts
 Restrictions: x-dgit-git-only
 
-Tests: build-modes build-modes-asplit build-modes-gbp-asplit clone-gitnosuite clone-nogit debpolicy-dbretry debpolicy-newreject debpolicy-quilt-gbp distropatches-reject drs-clone-nogit drs-push-masterupdate drs-push-rejects dsd-clone-nogit dsd-divert fetch-localgitonly fetch-somegit-notlast inarchivecopy newtag-clone-nogit oldtag-clone-nogit push-buildproductsdir push-newpackage push-nextdgit quilt quilt-gbp quilt-gbp-build-modes quilt-singlepatch rpush tag-updates test-list-uptodate trustingpolicy-replay
+Tests: build-modes build-modes-asplit build-modes-gbp-asplit clone-gitnosuite clone-nogit debpolicy-dbretry debpolicy-newreject debpolicy-quilt-gbp distropatches-reject drs-clone-nogit drs-push-masterupdate drs-push-rejects dsd-clone-nogit dsd-divert fetch-localgitonly fetch-somegit-notlast inarchivecopy newtag-clone-nogit oldnewtagalt oldtag-clone-nogit push-buildproductsdir push-newpackage push-nextdgit quilt quilt-gbp quilt-gbp-build-modes quilt-singlepatch rpush tag-updates test-list-uptodate trustingpolicy-replay
 Tests-Directory: tests/tests
 Depends: dgit, dgit-infrastructure, devscripts
 
diff --git a/tests/tests/oldnewtagalt b/tests/tests/oldnewtagalt
new file mode 100755 (executable)
index 0000000..cb270b2
--- /dev/null
@@ -0,0 +1,25 @@
+#!/bin/bash
+set -e
+. tests/lib
+
+t-setup-import examplegit
+t-tstunt-parsechangelog
+
+cd $p
+
+test-push () {
+       t-commit "$1"
+       t-dgit build-source
+       t-dgit push
+}
+
+for count in 1 2; do
+       t-oldtag
+       test-push "oldtag $count"
+
+       t-newtag
+       test-push "newtag $count"
+done
+
+echo ok.
+