mirror of
https://github.com/samba-team/samba.git
synced 2024-12-22 13:34:15 +03:00
selftest/tests: add helper method to simplify plantestsuite
Signed-off-by: Joe Guo <joeg@catalyst.net.nz> Reviewed-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
fa8a848365
commit
e051d787f4
@ -91,66 +91,85 @@ planpythontestsuite(
|
|||||||
"none", "wafsamba.tests.test_suite",
|
"none", "wafsamba.tests.test_suite",
|
||||||
extra_path=[os.path.join(samba4srcdir, "..", "buildtools"),
|
extra_path=[os.path.join(samba4srcdir, "..", "buildtools"),
|
||||||
os.path.join(samba4srcdir, "..", "third_party", "waf")])
|
os.path.join(samba4srcdir, "..", "third_party", "waf")])
|
||||||
|
|
||||||
|
|
||||||
|
def cmdline(script, *args):
|
||||||
|
"""
|
||||||
|
Prefix PYTHON env var and append --configurefile option to abs script path.
|
||||||
|
|
||||||
|
script.sh arg1 arg2
|
||||||
|
-->
|
||||||
|
PYTHON=python /path/to/bbdir/script.sh arg1 arg2 \
|
||||||
|
--configurefile $SMB_CONF_FILE
|
||||||
|
"""
|
||||||
|
return [
|
||||||
|
"PYTHON=%s" % python,
|
||||||
|
os.path.join(bbdir, script),
|
||||||
|
] + list(args) + [configuration]
|
||||||
|
|
||||||
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.demote-saveddb", "none",
|
"samba4.blackbox.demote-saveddb", "none",
|
||||||
["PYTHON=%s" % python, os.path.join(bbdir, "demote-saveddb.sh"),
|
cmdline('demote-saveddb.sh', '$PREFIX_ABS/demote'))
|
||||||
'$PREFIX_ABS/demote', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck.alpha13", "none",
|
"samba4.blackbox.dbcheck.alpha13", "none",
|
||||||
["PYTHON=%s" % python, os.path.join(bbdir, "dbcheck-oldrelease.sh"),
|
cmdline('dbcheck-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
'$PREFIX_ABS/provision', 'alpha13', configuration])
|
'alpha13'))
|
||||||
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck.release-4-0-0", "none",
|
"samba4.blackbox.dbcheck.release-4-0-0", "none",
|
||||||
["PYTHON=%s" % python, os.path.join(bbdir, "dbcheck-oldrelease.sh"),
|
cmdline('dbcheck-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
'$PREFIX_ABS/provision', 'release-4-0-0', configuration])
|
'release-4-0-0'))
|
||||||
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck.release-4-1-0rc3", "none",
|
"samba4.blackbox.dbcheck.release-4-1-0rc3", "none",
|
||||||
["PYTHON=%s" % python, os.path.join(bbdir, "dbcheck-oldrelease.sh"),
|
cmdline('dbcheck-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
'$PREFIX_ABS/provision', 'release-4-1-0rc3', configuration])
|
'release-4-1-0rc3'))
|
||||||
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck.release-4-1-6-partial-object", "none",
|
"samba4.blackbox.dbcheck.release-4-1-6-partial-object", "none",
|
||||||
["PYTHON=%s" % python, os.path.join(bbdir, "dbcheck-oldrelease.sh"),
|
cmdline('dbcheck-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
'$PREFIX_ABS/provision', 'release-4-1-6-partial-object', configuration])
|
'release-4-1-6-partial-object'))
|
||||||
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck.release-4-5-0-pre1", "none",
|
"samba4.blackbox.dbcheck.release-4-5-0-pre1", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('dbcheck-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "dbcheck-oldrelease.sh"),
|
'release-4-5-0-pre1'))
|
||||||
'$PREFIX_ABS/provision', 'release-4-5-0-pre1', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.upgradeprovision.alpha13", "none",
|
"samba4.blackbox.upgradeprovision.alpha13", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('upgradeprovision-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "upgradeprovision-oldrelease.sh"),
|
'alpha13'))
|
||||||
'$PREFIX_ABS/provision', 'alpha13', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.upgradeprovision.release-4-0-0", "none",
|
"samba4.blackbox.upgradeprovision.release-4-0-0", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('upgradeprovision-oldrelease.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "upgradeprovision-oldrelease.sh"),
|
'release-4-0-0'))
|
||||||
'$PREFIX_ABS/provision', 'release-4-0-0', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.tombstones-expunge.release-4-5-0-pre1", "none",
|
"samba4.blackbox.tombstones-expunge.release-4-5-0-pre1", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('tombstones-expunge.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "tombstones-expunge.sh"),
|
'release-4-5-0-pre1'))
|
||||||
'$PREFIX_ABS/provision', 'release-4-5-0-pre1', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.dbcheck-links.release-4-5-0-pre1", "none",
|
"samba4.blackbox.dbcheck-links.release-4-5-0-pre1", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('dbcheck-links.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "dbcheck-links.sh"),
|
'release-4-5-0-pre1'))
|
||||||
'$PREFIX_ABS/provision', 'release-4-5-0-pre1', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.runtime-links.release-4-5-0-pre1", "none",
|
"samba4.blackbox.runtime-links.release-4-5-0-pre1", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('runtime-links.sh', '$PREFIX_ABS/provision',
|
||||||
os.path.join(bbdir, "runtime-links.sh"),
|
'release-4-5-0-pre1'))
|
||||||
'$PREFIX_ABS/provision', 'release-4-5-0-pre1', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.schemaupgrade", "none",
|
"samba4.blackbox.schemaupgrade", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('schemaupgrade.sh', '$PREFIX_ABS/provision'))
|
||||||
os.path.join(bbdir, "schemaupgrade.sh"),
|
|
||||||
'$PREFIX_ABS/provision', configuration])
|
|
||||||
plantestsuite(
|
plantestsuite(
|
||||||
"samba4.blackbox.functionalprep", "none",
|
"samba4.blackbox.functionalprep", "none",
|
||||||
["PYTHON=%s" % python,
|
cmdline('functionalprep.sh', '$PREFIX_ABS/provision'))
|
||||||
os.path.join(bbdir, "functionalprep.sh"),
|
|
||||||
'$PREFIX_ABS/provision', configuration])
|
|
||||||
planpythontestsuite("none", "samba.tests.upgradeprovision", py3_compatible=True)
|
planpythontestsuite("none", "samba.tests.upgradeprovision", py3_compatible=True)
|
||||||
planpythontestsuite("none", "samba.tests.xattr", py3_compatible=True)
|
planpythontestsuite("none", "samba.tests.xattr", py3_compatible=True)
|
||||||
planpythontestsuite("none", "samba.tests.ntacls", py3_compatible=True)
|
planpythontestsuite("none", "samba.tests.ntacls", py3_compatible=True)
|
||||||
|
Loading…
Reference in New Issue
Block a user