Revision: b9901a9e6f32
Branch:   default
Author:   Pekka Klärck
Date:     Thu Sep 13 07:03:51 2012
Log: run_atests.py: requiring previous tempdir to be always cleanly removed when starting new execution turned out to be a bad idea in practice. such dirs are left, for example, on ci when job is stopped, and then starting new job fails. a drawback of this change is that now there is no clear warning if running tests with same interpreter simultaneously. doubt that will be too big a problem, though.
http://code.google.com/p/robotframework/source/detail?r=b9901a9e6f32

Modified:
 /atest/run_atests.py

=======================================
--- /atest/run_atests.py        Wed Sep 12 12:59:25 2012
+++ /atest/run_atests.py        Thu Sep 13 07:03:51 2012
@@ -78,23 +78,17 @@
     print 'Running command\n%s\n' % command
     sys.stdout.flush()
     signal.signal(signal.SIGINT, signal.SIG_IGN)
-    try:
-        return subprocess.call(command.split(), env=environ)
-    finally:
-        shutil.rmtree(tempdir)
+    return subprocess.call(command.split(), env=environ)


 def _get_result_and_temp_dirs(interpreter):
     interpreter = splitext(basename(interpreter))[0]
     resultdir = join(CURDIR, 'results', interpreter)
     tempdir = join(tempfile.gettempdir(), 'robottests', interpreter)
-    if os.path.exists(tempdir):
- print 'Temp directory for this interpreter already exists:', tempdir
-        print 'Cannot run tests simultaneously with same interpreter.'
-        print 'Remove the directory if it is left from an interrupted run.'
-        sys.exit(255)
     if exists(resultdir):
         shutil.rmtree(resultdir)
+    if exists(tempdir):
+        shutil.rmtree(tempdir)
     os.makedirs(tempdir)
     return resultdir, tempdir

Reply via email to