mirror of
https://github.com/django/django.git
synced 2025-02-10 01:16:53 +00:00
Merge pull request #864 from ambv/realmacosxtmp
Fixed two test failures when tmp dirs are below a symlink. This affects OS X where /var is a symlink to /private/var.
This commit is contained in:
commit
4526b67fe4
@ -26,7 +26,7 @@ from django.utils.six import StringIO
|
|||||||
from django.test import LiveServerTestCase
|
from django.test import LiveServerTestCase
|
||||||
|
|
||||||
|
|
||||||
test_dir = os.path.join(os.environ['DJANGO_TEST_TEMP_DIR'], 'test_project')
|
test_dir = os.path.realpath(os.path.join(os.environ['DJANGO_TEST_TEMP_DIR'], 'test_project'))
|
||||||
if not os.path.exists(test_dir):
|
if not os.path.exists(test_dir):
|
||||||
os.mkdir(test_dir)
|
os.mkdir(test_dir)
|
||||||
open(os.path.join(test_dir, '__init__.py'), 'w').close()
|
open(os.path.join(test_dir, '__init__.py'), 'w').close()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user