diff options
Diffstat (limited to 'Lib/bsddb/test/test_dbtables.py')
-rw-r--r-- | Lib/bsddb/test/test_dbtables.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/bsddb/test/test_dbtables.py b/Lib/bsddb/test/test_dbtables.py index 2ff93a3..a31fcec 100644 --- a/Lib/bsddb/test/test_dbtables.py +++ b/Lib/bsddb/test/test_dbtables.py @@ -26,6 +26,7 @@ try: pickle = cPickle except ImportError: import pickle +import tempfile import unittest from .test_all import verbose @@ -46,7 +47,7 @@ class TableDBTestCase(unittest.TestCase): db_name = 'test-table.db' def setUp(self): - homeDir = os.path.join(os.path.dirname(sys.argv[0]), 'db_home') + homeDir = os.path.join(tempfile.gettempdir(), 'db_home') self.homeDir = homeDir try: os.mkdir(homeDir) except os.error: pass |