From 2776ee197409e31c8ac90a47356d7890072868da Mon Sep 17 00:00:00 2001 From: Sebastian Spaeth Date: Wed, 18 Jan 2012 23:12:27 +0100 Subject: [PATCH] Create temp directories in "test" dir Don't create the temp dirs in the current directory, but create them in the same directory as the credentials.conf file is. We still need to prevent deleting them on test failure, so that they can be inspected manually. Signed-off-by: Sebastian Spaeth --- test/OLItest/TestRunner.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/test/OLItest/TestRunner.py b/test/OLItest/TestRunner.py index bb7e1c6..0d0730b 100644 --- a/test/OLItest/TestRunner.py +++ b/test/OLItest/TestRunner.py @@ -50,9 +50,10 @@ class OLITestLib(): directory at a time. OLITestLib is not suited for running several tests in parallel. The user is responsible for cleaning that up herself.""" - # creating temporary directory for testing in current dir + # creating temporary dir for testing in same dir as credentials.conf cls.testdir = os.path.abspath( - tempfile.mkdtemp(prefix='tmp_%s_'%suffix, dir='.')) + tempfile.mkdtemp(prefix='tmp_%s_'%suffix, + dir=os.path.dirname(cls.cred_file))) cls.create_config_file() return cls.testdir