From 96f120e2349b855ea34888ad923861e787812827 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 19 Jun 2010 17:48:37 +0200 Subject: python/passwords: Clean up imports. --- source4/lib/ldb/tests/python/passwords.py | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) (limited to 'source4') diff --git a/source4/lib/ldb/tests/python/passwords.py b/source4/lib/ldb/tests/python/passwords.py index c26bbf0a12..b3e6fc949e 100755 --- a/source4/lib/ldb/tests/python/passwords.py +++ b/source4/lib/ldb/tests/python/passwords.py @@ -22,18 +22,16 @@ import samba.getopt as options from samba.auth import system_session from samba.credentials import Credentials -from ldb import SCOPE_SUBTREE, SCOPE_ONELEVEL, SCOPE_BASE, LdbError +from ldb import SCOPE_BASE, LdbError from ldb import ERR_NO_SUCH_OBJECT, ERR_ATTRIBUTE_OR_VALUE_EXISTS -from ldb import ERR_ENTRY_ALREADY_EXISTS, ERR_UNWILLING_TO_PERFORM -from ldb import ERR_NOT_ALLOWED_ON_NON_LEAF, ERR_OTHER, ERR_INVALID_DN_SYNTAX +from ldb import ERR_UNWILLING_TO_PERFORM from ldb import ERR_NO_SUCH_ATTRIBUTE -from ldb import ERR_OBJECT_CLASS_VIOLATION, ERR_NOT_ALLOWED_ON_RDN -from ldb import ERR_NAMING_VIOLATION, ERR_CONSTRAINT_VIOLATION -from ldb import ERR_UNDEFINED_ATTRIBUTE_TYPE +from ldb import ERR_CONSTRAINT_VIOLATION from ldb import Message, MessageElement, Dn -from ldb import FLAG_MOD_ADD, FLAG_MOD_REPLACE, FLAG_MOD_DELETE +from ldb import FLAG_MOD_REPLACE, FLAG_MOD_DELETE from samba import gensec from samba.samdb import SamDB +import samba.tests from subunit.run import SubunitTestRunner import unittest @@ -62,7 +60,8 @@ creds.set_gensec_features(creds.get_gensec_features() | gensec.FEATURE_SEAL) # Tests start here # -class PasswordTests(unittest.TestCase): +class PasswordTests(samba.tests.TestCase): + def delete_force(self, ldb, dn): try: ldb.delete(dn) -- cgit