From: Ian Jackson Date: Sun, 8 Jan 2017 23:20:11 +0000 (+0000) Subject: test suite: protocol-compat: New test (wip) X-Git-Tag: archive/debian/3.0~46 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=dgit.git;a=commitdiff_plain;h=866a4b0d97a4863c9c0c2f6b984d8f373b11af52;ds=sidebyside test suite: protocol-compat: New test (wip) Signed-off-by: Ian Jackson --- diff --git a/debian/tests/control b/debian/tests/control index 49eefbca..3530d7ac 100644 --- a/debian/tests/control +++ b/debian/tests/control @@ -25,7 +25,7 @@ Tests-Directory: tests/tests Depends: dgit, dgit-infrastructure, devscripts, debhelper (>=8), fakeroot, build-essential Restrictions: x-dgit-git-only -Tests: absurd-gitapply badcommit-rewrite build-modes build-modes-asplit build-modes-gbp-asplit clone-clogsigpipe clone-gitnosuite clone-nogit debpolicy-dbretry debpolicy-newreject debpolicy-quilt-gbp distropatches-reject downstream-gitless drs-clone-nogit drs-push-masterupdate drs-push-rejects dsd-clone-nogit dsd-divert fetch-localgitonly fetch-somegit-notlast gbp-orig gitconfig import-dsc import-native import-nonnative import-tarbomb inarchivecopy mismatches-contents mismatches-dscchanges multisuite newtag-clone-nogit oldnewtagalt oldtag-clone-nogit orig-include-exclude orig-include-exclude-chkquery overwrite-chkclog overwrite-junk overwrite-splitbrains overwrite-version push-buildproductsdir push-newpackage push-nextdgit quilt quilt-gbp quilt-gbp-build-modes quilt-singlepatch quilt-splitbrains rpush tag-updates test-list-uptodate trustingpolicy-replay unrepresentable version-opt +Tests: absurd-gitapply badcommit-rewrite build-modes build-modes-asplit build-modes-gbp-asplit clone-clogsigpipe clone-gitnosuite clone-nogit debpolicy-dbretry debpolicy-newreject debpolicy-quilt-gbp distropatches-reject downstream-gitless drs-clone-nogit drs-push-masterupdate drs-push-rejects dsd-clone-nogit dsd-divert fetch-localgitonly fetch-somegit-notlast gbp-orig gitconfig import-dsc import-native import-nonnative import-tarbomb inarchivecopy mismatches-contents mismatches-dscchanges multisuite newtag-clone-nogit oldnewtagalt oldtag-clone-nogit orig-include-exclude orig-include-exclude-chkquery overwrite-chkclog overwrite-junk overwrite-splitbrains overwrite-version protocol-compat push-buildproductsdir push-newpackage push-nextdgit quilt quilt-gbp quilt-gbp-build-modes quilt-singlepatch quilt-splitbrains rpush tag-updates test-list-uptodate trustingpolicy-replay unrepresentable version-opt Tests-Directory: tests/tests Depends: dgit, dgit-infrastructure, devscripts, debhelper (>=8), fakeroot, build-essential diff --git a/tests/tests/protocol-compat b/tests/tests/protocol-compat new file mode 100755 index 00000000..47074d51 --- /dev/null +++ b/tests/tests/protocol-compat @@ -0,0 +1,40 @@ +#!/bin/bash +set -e +. tests/lib +. $troot/lib-reprepro + +t-setup-import examplegit +t-tstunt-parsechangelog + +prep () { + dscf=$tmp/mirror/pool/main/example_$v.dsc +} + +check () { + t-archive-none $p + t-archive-query $suite + + t-dgit clone $p stable $p.cloned + cd $p.cloned + t-ref-head + + t-dgit import-dsc $dscf +imported + t-ref-same refs/heads/imported + cd .. +} + +: ---------- older ---------- + +suite=stable +v=1.2 + +prep + +perl -i -pe 's/^(Dgit: \w+).*/$1/' $dscf + +dgit_config_debian_alias='-cdgit-distro.debian.alias-canon=test-dummy' +# old Dgit fields are supposed to mean Debian + +check + +#t-ok