diff options
author | Andrew Tridgell <tridge@samba.org> | 2011-02-03 15:14:31 +1100 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2011-02-07 13:22:00 +1100 |
commit | 6484da4859fe9b00a7129d89e185bb7947621243 (patch) | |
tree | e62e382fb2288d1dd3e0c352c94a215a2cdefc45 /source4/selftest/tests.py | |
parent | e7b2e06130fd74a539c58a48c870c9fa1961f699 (diff) | |
download | samba-6484da4859fe9b00a7129d89e185bb7947621243.tar.gz samba-6484da4859fe9b00a7129d89e185bb7947621243.tar.bz2 samba-6484da4859fe9b00a7129d89e185bb7947621243.zip |
s4-test: allow make test to work from top level directory
this fixes the path assumptions in Samba4 make test to allow it to
work from the top level directory.
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'source4/selftest/tests.py')
-rwxr-xr-x | source4/selftest/tests.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py index 6e2ade145e..047d75a8b0 100755 --- a/source4/selftest/tests.py +++ b/source4/selftest/tests.py @@ -65,7 +65,10 @@ def plantestsuite(name, env, cmdline, allow_empty_output=False): filter_subunit_args.append("--fail-on-empty") if "$LISTOPT" in cmdline: filter_subunit_args.append("$LISTOPT") - print "%s 2>&1 | ../selftest/filter-subunit %s --prefix=\"%s.\"" % (cmdline, " ".join(filter_subunit_args), name) + print "%s 2>&1 | %s/selftest/filter-subunit %s --prefix=\"%s.\"" % (cmdline, + srcdir, + " ".join(filter_subunit_args), + name) if allow_empty_output: print "WARNING: allowing empty subunit output from %s" % name @@ -75,7 +78,7 @@ def add_prefix(prefix, support_list=False): listopt = "$LISTOPT " else: listopt = "" - return "../selftest/filter-subunit %s--fail-on-empty --prefix=\"%s.\"" % (listopt, prefix) + return "%s/selftest/filter-subunit %s--fail-on-empty --prefix=\"%s.\"" % (srcdir, listopt, prefix) def plantestsuite_loadlist(name, env, cmdline): @@ -136,7 +139,8 @@ def plansmbtorturetestsuite(name, env, options): plantestsuite_loadlist(modname, env, cmdline) -samba4srcdir = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(__file__)), "..")) +srcdir = os.path.normpath(os.path.join(os.path.dirname(os.path.abspath(__file__)), "../..")) +samba4srcdir = os.path.join(srcdir, 'source4') builddir = os.getenv("BUILDDIR", samba4srcdir) samba4bindir = os.path.normpath(os.path.join(builddir, "bin")) smb4torture = binpath("smbtorture") @@ -163,7 +167,7 @@ else: subprocess.call([smb4torture, "-V"]) -bbdir = "../testprogs/blackbox" +bbdir = os.path.join(srcdir, "testprogs/blackbox") configuration = "--configfile=$SMB_CONF_PATH" |