chiark / gitweb /
test suite: defdistro-dsd-clone-drs: New test
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 21 Jan 2017 11:39:16 +0000 (11:39 +0000)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 21 Jan 2017 11:39:19 +0000 (11:39 +0000)
Would have detected #851906 (and hopefully #850521).

Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
debian/changelog
debian/tests/control
tests/tests/defdistro-dsd-clone-drs [new file with mode: 0755]
tests/tests/dsd-clone-drs

index 1bada744b9a69b582c9b3cf5a6c5b4f7f778a060..a8760fa03c33944e252485e5bbf82e50a9400963 100644 (file)
@@ -4,7 +4,11 @@ dgit (3.7~) unstable; urgency=medium
   * Fix clone-dgit-repos-server and print-dgit-repos-server-print-url.
     Closes:#851906.
 
- --
+  Test suite:
+  * defdistro-dsd-clone-drs: New test which would have detected
+    #851906 (and hopefully #850521).
+
+ -- Ian Jackson <ijackson@chiark.greenend.org.uk>  Sat, 21 Jan 2017 11:38:57 +0000
 
 dgit (3.6) unstable; urgency=medium
 
index 1528fe08e852699cbbe6da0f500b0020ff94f608..871183562c92434671d710d81efa5b09774f10b8 100644 (file)
@@ -6,7 +6,7 @@ Tests: clone-reprepro downstream-gitless
 Tests-Directory: tests/tests
 Depends: dgit, dgit-infrastructure, devscripts, debhelper (>=8), fakeroot, build-essential, reprepro
 
-Tests: dsd-clone-drs
+Tests: defdistro-dsd-clone-drs dsd-clone-drs
 Tests-Directory: tests/tests
 Depends: dgit, dgit-infrastructure, devscripts, debhelper (>=8), fakeroot, build-essential
 Restrictions: x-dgit-intree-only x-dgit-git-only
diff --git a/tests/tests/defdistro-dsd-clone-drs b/tests/tests/defdistro-dsd-clone-drs
new file mode 100755 (executable)
index 0000000..1a1c138
--- /dev/null
@@ -0,0 +1,14 @@
+#!/bin/bash
+. tests/lib
+
+t-restrict x-dgit-intree-only
+t-restrict x-dgit-git-only
+
+export DGIT_TEST_DSD_CLONE_DRS_HOOK='
+       t-git-config dgit.default.distro test-dummy
+       url=$(git config dgit-distro.test-dummy.git-url)
+       t-git-config dgit-distro.test-dummy/push.git-url "$url"
+       t-git-config dgit-distro.test-dummy.git-url nosuchprotocol://
+'
+
+t-alt-test
index 4346579a8dd4f76d48b3689ca87fa1144dc6e236..6065c5f4369866944ed4a78d1319d6cc5f4cbf98 100755 (executable)
@@ -6,6 +6,7 @@ t-restrict x-dgit-intree-only
 t-restrict x-dgit-git-only
 
 t-dsd
+eval "$DGIT_TEST_DSD_CLONE_DRS_HOOK"
 
 cd $tmp
 t-dgit clone-dgit-repos-server drs-cloned