chiark / gitweb /
test suite: defdistro-rpush: Remove workaround for missing isuite param
[dgit.git] / tests / lib
index a4932d335cd36109a440c46ad9156a812d436616..4ddd6d8ac7451d34a5728b759bac0c5a52ef0f64 100644 (file)
--- a/tests/lib
+++ b/tests/lib
@@ -28,6 +28,8 @@ t-set-intree
 : ${DGIT_TEST_DEBUG=-D}
 export DGIT_TEST_DEBUG
 
+: ${DGIT_TEST_DISTRO+ ${distro=${DGIT_TEST_DISTRO}}}
+
 export GIT_COMMITTER_DATE='1440253867 +0100'
 export GIT_AUTHOR_DATE='1440253867 +0100'
 
@@ -392,6 +394,7 @@ t-fscks () {
 }
 
 t-ok () {
+       : '========================================'
        t-fscks
        echo ok.
 }
@@ -406,6 +409,7 @@ t-dgit () {
        : '
 {{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{{'
        $dgit --dgit=$dgit --dget:-u --dput:--config=$tmp/dput.cf \
+ ${dgit_config_debian_alias-"--config-lookup-explode=dgit-distro.debian.alias-canon"} \
                ${distro--dtest-dummy} ${distro+${distro:+-d}${distro}} \
                $DGIT_TEST_OPTS $DGIT_TEST_DEBUG \
                -k39B13D8A $t_dgit_xopts "$@"
@@ -776,6 +780,11 @@ t-822-field () {
        ' <$file
 }
 
+t-defdistro () {
+       export DGIT_TEST_DISTRO=''
+       t-git-config dgit-suite.unstable.distro test-dummy
+}
+
 t-stunt-envvar () {
        local var=$1
        local tstunt=$2
@@ -799,7 +808,14 @@ t-tstunt--save-real () {
        local rc
        local real
        set +e
-       real=$(type -p "$f")
+       real=$(
+               p=":$PATH:"
+               p="${p/:"$tmp/tstunt":/:}"
+               p="${p%:}"
+               p="${p#:}"
+               PATH="$p"
+               type -p "$f"
+       )
        rc=$?
        set -e