chiark / gitweb /
test suite: Make example_1.1 contain a patch with Name and Topic
[dgit.git] / tests / enumerate-tests
index 912ee4f..0f37c96 100755 (executable)
@@ -15,6 +15,8 @@ restriction- () {
        set +e
        whynot=$(t-restriction-$r)
        rc=$?
+       whynot="${whynot//
+/ / }"
        set -e
        case "$rc.$whynot" in
        0.)     ;;
@@ -40,15 +42,30 @@ finish- () {
 
 test-begin-gencontrol () {
        restrictions=''
-       dependencies=''
+       dependencies='dgit, dgit-infrastructure, devscripts, debhelper (>=8), fakeroot, build-essential, chiark-utils-bin, bc'
 }
 
 restriction-gencontrol () {
        restrictions+=" $r"
 }
 
+gencontrol-add-deps () {
+       for dep in "$@"; do
+               dependencies+="${dependencies:+, }$dep"
+       done
+}
+
 dependencies-gencontrol () {
-       dependencies+=", $deps"
+       for dep in "$deps"; do
+               case "$dep" in
+               NO-DGIT) dependencies='chiark-utils-bin' ;;
+               NO-DEFAULT) dependencies='' ;;
+               GDR) gencontrol-add-deps \
+                       git-debrebase git-buildpackage faketime
+                       ;;
+               *) gencontrol-add-deps "$dep" ;;
+               esac
+       done
 }
 
 test-done-gencontrol () {