summaryrefslogtreecommitdiff
path: root/tests/regressiontests/admin_scripts
diff options
context:
space:
mode:
authorRussell Keith-Magee <russell@keith-magee.com>2008-07-30 09:29:51 +0000
committerRussell Keith-Magee <russell@keith-magee.com>2008-07-30 09:29:51 +0000
commit0dc11a0c1d92fc9c3d93056f0e307126ea13e9b2 (patch)
tree91e3f3c0fb1419778979979c06e257c498169116 /tests/regressiontests/admin_scripts
parent74dde43989517076fe7387665dbf0aec52e6d006 (diff)
Fixed #8029 -- Modified admin_scripts test to use the PYTHONPATH from the environment where the test is executed. Thanks to Ramiro and Alex Gaynor for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8149 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'tests/regressiontests/admin_scripts')
-rw-r--r--tests/regressiontests/admin_scripts/tests.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/regressiontests/admin_scripts/tests.py b/tests/regressiontests/admin_scripts/tests.py
index 7de7f3ee5a..1f60ab17c1 100644
--- a/tests/regressiontests/admin_scripts/tests.py
+++ b/tests/regressiontests/admin_scripts/tests.py
@@ -67,7 +67,10 @@ class AdminScriptTestCase(unittest.TestCase):
elif 'DJANGO_SETTINGS_MODULE' in os.environ:
del os.environ['DJANGO_SETTINGS_MODULE']
- os.environ['PYTHONPATH'] = os.pathsep.join([test_dir,base_dir])
+ if old_python_path:
+ os.environ['PYTHONPATH'] = os.pathsep.join([test_dir, base_dir, old_python_path])
+ else:
+ os.environ['PYTHONPATH'] = os.pathsep.join([test_dir, base_dir])
# Move to the test directory and run
os.chdir(test_dir)