[Python-apps-commits] r10701 - in packages/mercurial/trunk/debian (2 files)

vicho at users.alioth.debian.org vicho at users.alioth.debian.org
Sat Mar 22 14:53:40 UTC 2014


    Date: Saturday, March 22, 2014 @ 14:53:39
  Author: vicho
Revision: 10701

Fix "autopkgtest hgsubversion shouldn't need network connectivity" by making the test create a local svn repository (Closes: #735578)

Modified:
  packages/mercurial/trunk/debian/changelog
  packages/mercurial/trunk/debian/tests/hgsubversion	(contents, properties)

Modified: packages/mercurial/trunk/debian/changelog
===================================================================
--- packages/mercurial/trunk/debian/changelog	2014-03-21 18:40:03 UTC (rev 10700)
+++ packages/mercurial/trunk/debian/changelog	2014-03-22 14:53:39 UTC (rev 10701)
@@ -3,6 +3,8 @@
   * Fix "please downgrade 'wish' Recommends to Suggests" by downgrading it
     and removing the redundant suggest from mercurial-control (Closes: #741514)
   * Drop Suggests of vim or emacs
+  * Fix "autopkgtest hgsubversion shouldn't need network connectivity"
+    by making the test create a local svn repository (Closes: #735578)
 
  -- Javi Merino <vicho at debian.org>  Fri, 14 Mar 2014 23:33:43 +0100
 

Modified: packages/mercurial/trunk/debian/tests/hgsubversion
===================================================================
--- packages/mercurial/trunk/debian/tests/hgsubversion	2014-03-21 18:40:03 UTC (rev 10700)
+++ packages/mercurial/trunk/debian/tests/hgsubversion	2014-03-22 14:53:39 UTC (rev 10701)
@@ -1,3 +1,39 @@
 #!/bin/sh
 
-exec hg --config extensions.hgsubversion= clone svn://anonscm.debian.org/python-apps/packages/mercurial/trunk/
+set -e
+
+SVN_ROOT=$(mktemp --tmpdir -d hgsubversion.XXXXX)
+mkdir -p $SVN_ROOT
+
+PID_FILE=/var/run/svnmock.pid
+
+# Create a local svn server with an empty repo
+svnadmin create $SVN_ROOT/celesteville
+cat > $SVN_ROOT/celesteville/conf/svnserve.conf << EOF
+[general]
+anon-access = write
+EOF
+svnserve -d --pid-file /var/run/svnmock.pid -r $SVN_ROOT
+
+# Put some content in the repository
+svn co svn://127.0.0.1/celesteville
+cd celesteville
+echo Cornelius > people
+svn add people
+svn commit -m "Add people"
+cd ..
+rm -r celesteville
+
+# Now test hgsubversion
+hg --config extensions.hgsubversion= clone svn://127.0.0.1/celesteville
+cd celesteville
+echo Arthur >> people
+hg ci -u "Babar <babar at jungle.org>" -m "Add more people"
+hg --config extensions.hgsubversion= push
+cd ..
+
+# Kill the server and cleanup
+kill $(cat /var/run/svnmock.pid)
+rm -r $SVN_ROOT
+
+rm -r celesteville




More information about the Python-apps-commits mailing list