Skip to content

Commit

Permalink
selftest: don't hardcode '.python3' for extra-python tests
Browse files Browse the repository at this point in the history
Instead of hardcoding '.python3' we now hardcode the extra python
exe (which will be python2 for a default python3 build)

Signed-off-by: Noel Power <[email protected]>
Reviewed-by: Andrew Bartlett <[email protected]>
  • Loading branch information
noelpower authored and Noel Power committed Dec 10, 2018
1 parent 2fb74e6 commit e3c37bb
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion selftest/selftesthelpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,8 @@ def planpythontestsuite(env, module, name=None, extra_path=None,
if py3_compatible and extra_python is not None:
# Plan one more test for Python 3 compatible module
args[0] = extra_python
plantestsuite_loadlist(name + ".python3", env, pypath + args)
python_name = os.path.basename(extra_python)
plantestsuite_loadlist(name + "." + python_name, env, pypath + args)


def get_env_torture_options():
Expand Down
3 changes: 2 additions & 1 deletion source4/selftest/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -625,7 +625,8 @@ def planoldpythontestsuite(env, module, name=None, extra_path=[], environ={}, ex
plantestsuite_loadlist(name, env, args)
if py3_compatible and extra_python is not None:
args[args.index(subunitrun)] = subunitrun3
plantestsuite_loadlist(name + ".python3", env, args)
python_name = os.path.basename(extra_python)
plantestsuite_loadlist(name + "." + python_name, env, args)

# Run complex search expressions test once for each database backend.
# Right now ad_dc has mdb and ad_dc_ntvfs has tdb
Expand Down

0 comments on commit e3c37bb

Please sign in to comment.