s4-test: make sure the selftest prefix exists
authorAndrew Tridgell <tridge@samba.org>
Mon, 8 Nov 2010 23:22:48 +0000 (10:22 +1100)
committerAndrew Tridgell <tridge@samba.org>
Tue, 9 Nov 2010 00:05:22 +0000 (00:05 +0000)
Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Tue Nov  9 00:05:22 UTC 2010 on sn-devel-104

source4/selftest/wscript

index 19f7a0bb932644f62f406614a3985aeb97155bad..a5fafa3d6a4f5d590e714c10a09720f0e9a5017d 100644 (file)
@@ -154,6 +154,9 @@ def cmd_testonly(opt):
     if os.path.exists(st_done):
         os.unlink(st_done)
 
+    if not os.path.isdir(env.SELFTEST_PREFIX):
+        os.makedirs(env.SELFTEST_PREFIX, int('755', 8))
+
     # We use the full path rather than relative path because it cause problems on some plateforms (ie. solaris 8).
     cmd = '(${PERL} %s/../selftest/selftest.pl --prefix=${SELFTEST_PREFIX} --builddir=. --srcdir=. --exclude=./selftest/skip --testlist="${PYTHON} ./selftest/tests.py|" ${OPTIONS} --socket-wrapper ${TESTS} && touch ${SELFTEST_PREFIX}/st_done) | ${FILTER_OPTIONS} | tee ${SELFTEST_PREFIX}/subunit' % (os.getcwd())
     if os.environ.get('RUN_FROM_BUILD_FARM') is None and not Options.options.FILTERED_SUBUNIT: