[Python-modules-commits] r20425 - in packages/sphinx/trunk/debian (3 files)

jwilk at users.alioth.debian.org jwilk at users.alioth.debian.org
Sun Feb 12 22:44:34 UTC 2012


    Date: Sunday, February 12, 2012 @ 22:44:32
  Author: jwilk
Revision: 20425

Fix Python 3 sys.path for the test runner.           

Added:
  packages/sphinx/trunk/debian/patches/python3_test_syspath.diff
Modified:
  packages/sphinx/trunk/debian/changelog
  packages/sphinx/trunk/debian/patches/series

Modified: packages/sphinx/trunk/debian/changelog
===================================================================
--- packages/sphinx/trunk/debian/changelog	2012-02-12 22:43:35 UTC (rev 20424)
+++ packages/sphinx/trunk/debian/changelog	2012-02-12 22:44:32 UTC (rev 20425)
@@ -11,12 +11,14 @@
   * Run tests against Python 3:
     + Add build-dependency on python3-nose, python3-docutils,
       python3-pygments, python3-jinja2, python3-sqlalchemy.
+    * Add python3_test_syspath.diff to fix Python 3 sys.path for the test
+      runner.           
     + Add python3_test_build_dir.diff to hardcode Python 3 build directory in
       the test runner to the one that the package uses.
     + Add test running code debian/rules. Don't use --no-skip for the moment,
       as some required packages don't exist yet (see #647441, #647439).
 
- -- Jakub Wilk <jwilk at debian.org>  Sun, 12 Feb 2012 19:52:58 +0100
+ -- Jakub Wilk <jwilk at debian.org>  Sun, 12 Feb 2012 23:43:56 +0100
 
 sphinx (1.1.2+dfsg-4) unstable; urgency=low
 

Added: packages/sphinx/trunk/debian/patches/python3_test_syspath.diff
===================================================================
--- packages/sphinx/trunk/debian/patches/python3_test_syspath.diff	                        (rev 0)
+++ packages/sphinx/trunk/debian/patches/python3_test_syspath.diff	2012-02-12 22:44:32 UTC (rev 20425)
@@ -0,0 +1,23 @@
+Description: Fix Python 3 sys.path for the test runner.
+Author: Jakub Wilk <jwilk at debian.org>
+Bug: https://bitbucket.org/birkenfeld/sphinx/issue/874/tests-runpy-doesnt-always-set-syspath
+Forwarded: yes
+Last-Update: 2012-02-12
+
+--- a/tests/run.py
++++ b/tests/run.py
+@@ -22,9 +22,11 @@
+     copydir_run_2to3(testroot, newroot)
+     # switch to the converted dir so nose tests the right tests
+     chdir(newroot)
+-
+-# always test the sphinx package from this directory
+-sys.path.insert(0, path.join(path.dirname(__file__), path.pardir))
++    # always test the sphinx package from build/lib/
++    sys.path.insert(0, path.pardir)
++else:
++    # always test the sphinx package from this directory
++    sys.path.insert(0, path.join(path.dirname(__file__), path.pardir))
+ 
+ try:
+     import nose

Modified: packages/sphinx/trunk/debian/patches/series
===================================================================
--- packages/sphinx/trunk/debian/patches/series	2012-02-12 22:43:35 UTC (rev 20424)
+++ packages/sphinx/trunk/debian/patches/series	2012-02-12 22:44:32 UTC (rev 20425)
@@ -3,4 +3,5 @@
 show_more_stack_frames.diff
 initialize_autodoc.diff
 sphinxcontrib_namespace.diff
+python3_test_syspath.diff
 python3_test_build_dir.diff




More information about the Python-modules-commits mailing list