summaryrefslogtreecommitdiff
path: root/source4/scripting
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2008-05-29 17:38:12 +0200
committerJelmer Vernooij <jelmer@samba.org>2008-05-29 17:38:12 +0200
commit6f7b2b69333230016a9538b024faec0d97095c69 (patch)
tree5b7b5f1326f7338d6e62eb603f6a7601bcb5d78f /source4/scripting
parente16f0e15b40229e7a42311dddfb391cf6142462e (diff)
downloadsamba-6f7b2b69333230016a9538b024faec0d97095c69.tar.gz
samba-6f7b2b69333230016a9538b024faec0d97095c69.tar.bz2
samba-6f7b2b69333230016a9538b024faec0d97095c69.zip
Fix samdb test and enable it.
(This used to be commit 6b202d3780f8ff50e0bdfa4a749c43b5639e4880)
Diffstat (limited to 'source4/scripting')
-rw-r--r--source4/scripting/python/samba/tests/samdb.py8
1 files changed, 6 insertions, 2 deletions
diff --git a/source4/scripting/python/samba/tests/samdb.py b/source4/scripting/python/samba/tests/samdb.py
index a022d7bb51..7e8ba053d4 100644
--- a/source4/scripting/python/samba/tests/samdb.py
+++ b/source4/scripting/python/samba/tests/samdb.py
@@ -19,7 +19,7 @@
from samba.auth import system_session
from samba.credentials import Credentials
import os
-from samba.provision import setup_samdb, guess_names
+from samba.provision import setup_samdb, guess_names, setup_templatesdb
from samba.samdb import SamDB
from samba.tests import cmdline_loadparm, TestCaseInTempDir
from samba import security
@@ -42,12 +42,16 @@ class SamDBTestCase(TestCaseInTempDir):
domainsid = security.random_sid()
hostguid = str(uuid.uuid4())
path = os.path.join(self.tempdir, "samdb.ldb")
+ session_info = system_session()
names = guess_names(lp=cmdline_loadparm, hostname="foo",
domain="EXAMPLE.COM", dnsdomain="example.com",
serverrole="domain controller",
domaindn=self.domaindn, configdn=configdn,
schemadn=schemadn)
- self.samdb = setup_samdb(path, setup_path, system_session(), creds,
+ setup_templatesdb(os.path.join(self.tempdir, "templates.ldb"),
+ setup_path, session_info=session_info,
+ credentials=creds, lp=cmdline_loadparm)
+ self.samdb = setup_samdb(path, setup_path, session_info, creds,
cmdline_loadparm, names,
lambda x: None, domainsid,
"# no aci", domainguid,