summaryrefslogtreecommitdiff
path: root/source4
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2010-10-01 01:31:06 +0000
committerJelmer Vernooij <jelmer@samba.org>2010-10-01 01:31:06 +0000
commitfbee3586fdd6f04db6321646df54c147c843a5e3 (patch)
treeed14f8c3aa9bad4702b8e044bcf385707f33e76c /source4
parentdc65824065fea3e6ca9ddedd4b118d26d338ee6e (diff)
downloadsamba-fbee3586fdd6f04db6321646df54c147c843a5e3.tar.gz
samba-fbee3586fdd6f04db6321646df54c147c843a5e3.tar.bz2
samba-fbee3586fdd6f04db6321646df54c147c843a5e3.zip
selftest: Let selftest provide the tempdir, rather than creating it as sideeffect of tests.py.
Diffstat (limited to 'source4')
-rwxr-xr-xsource4/selftest/tests.py7
-rwxr-xr-xsource4/setup/upgrade_from_s31
2 files changed, 2 insertions, 6 deletions
diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py
index 63a4bcfd85..1913c40c28 100755
--- a/source4/selftest/tests.py
+++ b/source4/selftest/tests.py
@@ -152,7 +152,7 @@ bbdir = "../testprogs/blackbox"
configuration = "--configfile=$SMB_CONF_PATH"
-torture_options = [configuration, "--maximum-runtime=$SELFTEST_MAXTIME", "--target=$SELFTEST_TARGET", "--basedir=$SELFTEST_PREFIX/s4client"]
+torture_options = [configuration, "--maximum-runtime=$SELFTEST_MAXTIME", "--target=$SELFTEST_TARGET", "--basedir=$SELFTEST_TMPDIR"]
if not os.getenv("SELFTEST_VERBOSE"):
torture_options.append("--option=torture:progress=no")
torture_options.append("--format=subunit")
@@ -485,10 +485,7 @@ planpythontestsuite("none", "samba.tests.ntacls")
plantestsuite("samba4.deletetest.python(dc)", "dc", ['PYTHONPATH="$PYTHONPATH:../lib/subunit/python:../lib/testtools', python, os.path.join(samba4srcdir, "dsdb/tests/python/deletetest.py"), '$SERVER', '-U"$USERNAME%$PASSWORD','-W', '$DOMAIN'])
plantestsuite("samba4.policy.python", "none", ['PYTHONPATH="$PYTHONPATH:lib/policy/tests/python"', subunitrun, 'bindings'])
plantestsuite("samba4.blackbox.samba3dump", "none", [python, os.path.join(samba4srcdir, "scripting/bin/samba3dump"), os.path.join(samba4srcdir, "../testdata/samba3")])
-os.system("rm -rf $PREFIX/upgrade")
-plantestsuite("samba4.blackbox.upgrade", "none", [python, os.path.join(samba4srcdir, "setup/upgrade_from_s3"), "--targetdir=$PREFIX/upgrade", os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3")), os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3/smb.conf"))])
-os.system("rm -rf $PREFIX/provision") # FIXME
-os.system("mkdir $PREFIX/provision") # FIXME
+plantestsuite("samba4.blackbox.upgrade", "none", ["rm -rf $PREFIX/upgrade;", python, os.path.join(samba4srcdir, "setup/upgrade_from_s3"), "--targetdir=$PREFIX/upgrade", os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3")), os.path.normpath(os.path.join(samba4srcdir, "../testdata/samba3/smb.conf"))])
plantestsuite("samba4.blackbox.provision.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_provision.sh"), '$PREFIX/provision'])
plantestsuite("samba4.blackbox.provision-backend.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_provision-backend.sh"), '$PREFIX/provision'])
plantestsuite("samba4.blackbox.upgradeprovision.py", "none", ["PYTHON=%s" % python, os.path.join(samba4srcdir, "setup/tests/blackbox_upgradeprovision.sh"), '$PREFIX/provision'])
diff --git a/source4/setup/upgrade_from_s3 b/source4/setup/upgrade_from_s3
index cdc59dc9eb..a7bc6f0abd 100755
--- a/source4/setup/upgrade_from_s3
+++ b/source4/setup/upgrade_from_s3
@@ -46,7 +46,6 @@ parser.add_option("--targetdir", type="string", metavar="DIR",
opts, args = parser.parse_args()
-
logger = logging.getLogger("upgrade")
logger.addHandler(logging.StreamHandler(sys.stdout))
if opts.quiet: