[Python-checkins] r54518 - sandbox/trunk/2to3/tests/__init__.py sandbox/trunk/2to3/tests/support.py
collin.winter
python-checkins at python.org
Thu Mar 22 00:21:29 CET 2007
Author: collin.winter
Date: Thu Mar 22 00:21:24 2007
New Revision: 54518
Modified:
sandbox/trunk/2to3/tests/__init__.py
sandbox/trunk/2to3/tests/support.py
Log:
Fix broken sys.path manipulation.
Modified: sandbox/trunk/2to3/tests/__init__.py
==============================================================================
--- sandbox/trunk/2to3/tests/__init__.py (original)
+++ sandbox/trunk/2to3/tests/__init__.py Thu Mar 22 00:21:24 2007
@@ -12,7 +12,7 @@
all_tests = unittest.TestSuite()
-tests_dir = os.path.join(os.getcwd(), 'tests')
+tests_dir = os.path.join(os.path.dirname(__file__), '..', 'tests')
tests = [t[0:-3] for t in os.listdir(tests_dir)
if t.startswith('test_') and t.endswith('.py')]
Modified: sandbox/trunk/2to3/tests/support.py
==============================================================================
--- sandbox/trunk/2to3/tests/support.py (original)
+++ sandbox/trunk/2to3/tests/support.py Thu Mar 22 00:21:24 2007
@@ -23,4 +23,4 @@
def reformat(string):
return dedent(string) + "\n\n"
-sys.path.insert(0, os.path.dirname(__file__))
+sys.path.insert(0, os.path.join(os.path.dirname(__file__), ".."))
More information about the Python-checkins
mailing list