os.makedirs(test_prefix)
os.environ['TEST_DATA_PREFIX'] = test_prefix
os.environ['LDB_MODULES_PATH'] = Context.g_module.out + "/modules/ldb"
- if env.HAVE_LMDB:
- os.environ['HAVE_LMDB'] = '1'
- else:
- os.environ['HAVE_LMDB'] = '0'
samba_utils.ADD_LD_LIBRARY_PATH('bin/shared')
samba_utils.ADD_LD_LIBRARY_PATH('bin/shared/private')
ret = samba_utils.RUN_COMMAND(cmd)
print("testsuite returned %d" % ret)
- tmp_dir = os.path.join(test_prefix, 'tmp')
- if not os.path.exists(tmp_dir):
- os.mkdir(tmp_dir)
- pyret = samba_utils.RUN_PYTHON_TESTS(
- ['tests/python/api.py',
- 'tests/python/crash.py',
- 'tests/python/index.py',
- 'tests/python/repack.py'],
- extra_env={'SELFTEST_PREFIX': test_prefix})
- pyret = samba_utils.RUN_PYTHON_TESTS(
- ['tests/python/api.py',
- 'tests/python/crash.py',
- 'tests/python/index.py',
- 'tests/python/repack.py'],
- extra_env={'SELFTEST_PREFIX': test_prefix,
- 'LC_ALL': 'tr_TR.UTF-8'}) or pyret
- print("Python testsuite returned %d" % pyret)
-
cmocka_ret = 0
test_exes = ['test_ldb_qsort',
'test_ldb_dn',
cmd = os.path.join(Context.g_module.out, test_exe)
cmocka_ret = cmocka_ret or samba_utils.RUN_COMMAND(cmd)
- sys.exit(ret or pyret or cmocka_ret)
+ sys.exit(ret or cmocka_ret)
def dist():
'''makes a tarball for distribution'''
pam_set_items_so_path = config_hash.get("PAM_SET_ITEMS_SO_PATH")
have_heimdal_support = "SAMBA4_USES_HEIMDAL" in config_hash
using_system_gssapi = "USING_SYSTEM_GSSAPI" in config_hash
+have_lmdb = "HAVE_LMDB" in config_hash
planpythontestsuite("none", "samba.tests.source")
planpythontestsuite("none", "samba.tests.source_chars")
planpythontestsuite("none", "subunit.tests.test_suite")
planpythontestsuite("none", "samba.tests.blackbox.ndrdump")
planpythontestsuite("none", "samba.tests.blackbox.check_output")
-planpythontestsuite("none", "api", name="ldb.python", extra_path=['lib/ldb/tests/python'])
+
+# LDB tests for standalone operation
+planpythontestsuite("none", "api",
+ name="ldb.python.api",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'HAVE_LMDB': str(int(have_lmdb))})
+planpythontestsuite("none", "crash",
+ name="ldb.python.crash",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'HAVE_LMDB': str(int(have_lmdb))})
+planpythontestsuite("none", "index",
+ name="ldb.python.index",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'HAVE_LMDB': str(int(have_lmdb))})
+planpythontestsuite("none", "repack",
+ name="ldb.python.repack",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'HAVE_LMDB': str(int(have_lmdb))})
+
+# LDB tests for standalone operation, in the tr_TR.UTF-8 to cover
+# dotless i locales, see
+# https://bugzilla.samba.org/show_bug.cgi?id=15248
+planpythontestsuite("none", "api",
+ name="ldb.python.api.tr",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'LC_ALL': 'tr_TR.UTF-8'})
+planpythontestsuite("none", "crash",
+ name="ldb.python.crash.tr",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'LC_ALL': 'tr_TR.UTF-8'})
+planpythontestsuite("none", "index",
+ name="ldb.python.index.tr",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'LC_ALL': 'tr_TR.UTF-8'})
+planpythontestsuite("none", "repack",
+ name="ldb.python.repack.tr",
+ extra_path=['lib/ldb/tests/python'],
+ environ={'LC_ALL': 'tr_TR.UTF-8'})
+
planpythontestsuite("none", "samba.tests.credentials")
planpythontestsuite("none", "samba.tests.registry")
planpythontestsuite("ad_dc_ntvfs:local", "samba.tests.auth")