X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=dgit.git;a=blobdiff_plain;f=tests%2Flib;h=70cda8f6fefa45d911df58f659da06192542eb0d;hp=1516646f23ae1d239be725cb0ccf468afa8ca00f;hb=637c65f6a92e5a8436661ef0898079c0c0a104b0;hpb=475e31b775275ac895e21afa4143c10596b512d1 diff --git a/tests/lib b/tests/lib index 1516646f..70cda8f6 100644 --- a/tests/lib +++ b/tests/lib @@ -22,9 +22,9 @@ if [ x"$tmp" = x ]; then mkdir $tmp fi cd $tmp -export HOME=$tmp tmp=`pwd` +export HOME=$tmp export DGIT_TEST_DUMMY_DIR=$tmp ln -f $troot/ssh ssh @@ -81,7 +81,20 @@ t-has-ancestor () { if [ x$mbase != x$ancestor ]; then fail "not ff $ancestor..$now, $mbase != $ancestor" fi -} +} + +t-prep-newpackage () { + p=$1 + v=$2 + t-archive-none $p + t-git-none + v=3-1 + t-worktree $v + cd $p + git branch -m dgit/sid master + git remote rm dgit + cd .. +} t-archive-none () { p=$1