Files
django-test/apps/base/tests/utils.py
Jens Kleineheismann e9a43740ee
All checks were successful
buildbot/django-test-test-python3 Build done.
buildbot/django-test-test-python2 Build done.
FIX using pylint for python2.
2019-10-24 16:33:11 +02:00

14 lines
384 B
Python

# -*- coding: utf-8 -*-
from __future__ import unicode_literals
import os
from tempfile import mkdtemp as _mkdtmp
def mkdtemp(prefix):
dirname = os.path.dirname
pkg_base_dir = dirname(dirname(dirname(__file__)))
tmp_dir = os.path.join(pkg_base_dir, 'tmp')
# os.makedirs(tmp_dir, exist_ok=True)
os.makedirs(tmp_dir)
return _mkdtmp(prefix=prefix, dir=tmp_dir)