chiark / gitweb /
test suite: enumerate-tests: Break out allsedderies
[dgit.git] / tests / lib-baredebian
index 762e7e259b49b09ffba4b07c4b42fa1f3248d1f4..123ce35a0b3bec7eb6f5548d83e6638e4855c006 100644 (file)
@@ -4,6 +4,16 @@ baredebian-test-vars () {
        quiltmode=baredebian
        v=1.0-1
        suite=sid
+       uv=${v%-*}
+       uvtag=v$uv
+       origbase=${p}_${uv}.orig
+       xorigcomps=''
+}
+
+baredebian-tarball-mode () {
+       git tag -d $uvtag
+       uvtag=''
+       quiltmode=baredebian+tarball
 }
 
 baredebian-test-core () {
@@ -12,7 +22,13 @@ baredebian-test-core () {
 
        t-dgit -wn --dgit-view-save=split.f1 --$quiltmode quilt-fixup
 
-       tar --strip-components=1 -axf ../${p}_${v%-*}.orig.tar.*
+       tar --strip-components=1 -axf ../$origbase.tar.*
+       for comp in $xorigcomps; do
+               mkdir $comp
+               cd $comp
+               tar --strip-components=1 -axf ../../$origbase-$comp.tar.*
+               cd ..
+       done
 
        cd debian
        git clean -xdff
@@ -46,9 +62,11 @@ baredebian-test-core () {
        t-dgit -wn --quilt=$quiltmode --dgit-view-save=split.b quilt-fixup
        t-dgit -wn --quilt=$quiltmode --dgit-view-save=split.p --new push
 
-       git merge-base --is-ancestor v${v%-*} split.p
        git merge-base --is-ancestor HEAD     split.p
-       set +e; git merge-base HEAD v${v%-*}; rc=$?; set -e; [ $rc = 1 ]
+       if [ "$uvtag" ]; then
+               git merge-base --is-ancestor $uvtag split.p
+               set +e; git merge-base HEAD $uvtag; rc=$?; set -e; [ $rc = 1 ]
+       fi
 
        git clean -xdff
        # t-pushed-good-* wants a clean tree to start with, but this