Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Properly handle the fact that lists are mutable when trying to mainta…

…in state in a test.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@14429 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 7dfefa74ca8e5b0d37a5d13f0fcde6e6f98de9a4 1 parent 909c44e
Alex Gaynor authored November 02, 2010
4  tests/regressiontests/app_loading/tests.py
@@ -10,7 +10,7 @@
10 10
 
11 11
 class InstalledAppsGlobbingTest(TestCase):
12 12
     def setUp(self):
13  
-        self.OLD_SYS_PATH = sys.path
  13
+        self.OLD_SYS_PATH = sys.path[:]
14 14
         sys.path.append(os.path.dirname(os.path.abspath(__file__)))
15 15
         self.OLD_TZ = os.environ.get("TZ")
16 16
 
@@ -28,7 +28,7 @@ def tearDown(self):
28 28
 class EggLoadingTest(TestCase):
29 29
 
30 30
     def setUp(self):
31  
-        self.old_path = sys.path
  31
+        self.old_path = sys.path[:]
32 32
         self.egg_dir = '%s/eggs' % os.path.dirname(__file__)
33 33
 
34 34
         # This test adds dummy applications to the app cache. These

0 notes on commit 7dfefa7

Please sign in to comment.
Something went wrong with that request. Please try again.