X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=tests%2Flib;h=8722522daeed3856a6497e1a92552f6646c62c6a;hb=06163c6846f67fc9469c07c00611495f373f510e;hp=e4554e373f9fddef37c7cd0f302e98989e643fd1;hpb=a2f4a0b0b1f1eb286c16586af072cd419fbbf51e;p=dgit.git diff --git a/tests/lib b/tests/lib index e4554e37..8722522d 100644 --- a/tests/lib +++ b/tests/lib @@ -31,8 +31,8 @@ export DGIT_TEST_DEBUG : ${DGIT_TEST_DISTRO+ ${distro=${DGIT_TEST_DISTRO}}} -export GIT_COMMITTER_DATE='1440253867 +0100' -export GIT_AUTHOR_DATE='1440253867 +0100' +export GIT_COMMITTER_DATE='1515000000 +0100' +export GIT_AUTHOR_DATE='1515000000 +0100' root=`pwd` troot=$root/tests @@ -189,6 +189,13 @@ t-git-none () { (set -e; cd $tmp/git; tar xf $troot/git-template.tar) } +t-salsa-add-remote () { + local d=$tmp/salsa/$p + mkdir -p $d + (set -e; cd $d; git init --bare) + git remote add ${1-origin} $d +} + t-git-merge-base () { git merge-base $1 $2 || test $? = 1 } @@ -417,7 +424,7 @@ t-dgit () { ${dgit_config_debian_alias-"--config-lookup-explode=dgit-distro.debian.alias-canon"} \ ${distro+${distro:+-d}}${distro--dtest-dummy} \ $DGIT_TEST_OPTS $DGIT_TEST_DEBUG \ - -k39B13D8A $t_dgit_xopts "$@" + -kBCD22CD83243B79D3DFAC33EA3DBCBC039B13D8A $t_dgit_xopts "$@" : '}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}}} ' } @@ -997,6 +1004,11 @@ t-commit () { revision=$(( ${revision-0} + 1 )) } +t-dch-commit () { + faketime @"${GIT_AUTHOR_DATE% *}" dch "$@" + git commit -m "dch $*" debian/changelog +} + t-git-config () { git config --global "$@" }