From 2cdfaedee203a726bddfb46fb10d9604de32a05f Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Mon, 14 Apr 2008 19:20:43 +0200 Subject: Make sure credentials are specified when running the Python winreg RPC tests. (This used to be commit 280339e3d126f5c72dc271051b72839fde0c5c9f) --- source4/scripting/bin/subunitrun | 3 +-- source4/scripting/python/samba/tests/dcerpc/registry.py | 4 ++-- source4/selftest/samba4_tests.sh | 2 +- 3 files changed, 4 insertions(+), 5 deletions(-) (limited to 'source4') diff --git a/source4/scripting/bin/subunitrun b/source4/scripting/bin/subunitrun index 3730a15e1b..fbbffde42c 100755 --- a/source4/scripting/bin/subunitrun +++ b/source4/scripting/bin/subunitrun @@ -38,8 +38,7 @@ args = parser.parse_args()[1] samba.tests.cmdline_loadparm = sambaopts.get_loadparm() samba.tests.cmdline_credentials = credopts.get_credentials(samba.tests.cmdline_loadparm) -import pdb -pdb.set_trace() +param.cvar.default_config = samba.tests.cmdline_loadparm runner = SubunitTestRunner() program = TestProgram(module=None, argv=[sys.argv[0]] + args, testRunner=runner) diff --git a/source4/scripting/python/samba/tests/dcerpc/registry.py b/source4/scripting/python/samba/tests/dcerpc/registry.py index 1afdc582a7..05ac7c66ee 100644 --- a/source4/scripting/python/samba/tests/dcerpc/registry.py +++ b/source4/scripting/python/samba/tests/dcerpc/registry.py @@ -23,8 +23,8 @@ from samba.tests import RpcInterfaceTestCase class WinregTests(RpcInterfaceTestCase): def setUp(self): - self.conn = winreg.winreg("ncalrpc:", self.get_loadparm(), - self.get_credentials()) + lp = self.get_loadparm() + self.conn = winreg.winreg("ncalrpc:", lp, self.get_credentials()) def get_hklm(self): return self.conn.OpenHKLM(None, diff --git a/source4/selftest/samba4_tests.sh b/source4/selftest/samba4_tests.sh index 7e545664d1..d52c240b93 100755 --- a/source4/selftest/samba4_tests.sh +++ b/source4/selftest/samba4_tests.sh @@ -342,7 +342,7 @@ plantest "unixinfo.python" dc $SUBUNITRUN samba.tests.dcerpc.unix plantest "events.python" none PYTHONPATH="$PYTHONPATH:lib/events" $SUBUNITRUN tests plantest "samba3sam.python" none PYTHONPATH="$PYTHONPATH:dsdb/samdb/ldb_modules/tests" $SUBUNITRUN samba3sam plantest "rpcecho.python" dc $SUBUNITRUN samba.tests.dcerpc.rpcecho -plantest "winreg.python" dc $SUBUNITRUN samba.tests.dcerpc.registry +plantest "winreg.python" dc $SUBUNITRUN -U\$USERNAME%\$PASSWORD samba.tests.dcerpc.registry plantest "ldap.python" dc $PYTHON $samba4srcdir/lib/ldb/tests/python/ldap.py $CONFIGURATION \$SERVER -U\$USERNAME%\$PASSWORD -W \$DOMAIN plantest "blackbox.samba3dump" none $PYTHON scripting/bin/samba3dump $samba4srcdir/../testdata/samba3 rm -rf $PREFIX/upgrade -- cgit