From c92db7b6dc31756fc461ea9f74e1cd675e3e160d Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Sat, 19 Jun 2010 18:58:18 +0200 Subject: python: Use samba.tests.TestCase, make sure base class tearDown and setUp methods are called, fix formatting. --- source4/scripting/python/samba/tests/samba3.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source4/scripting/python/samba/tests/samba3.py') diff --git a/source4/scripting/python/samba/tests/samba3.py b/source4/scripting/python/samba/tests/samba3.py index d7418b303dd..f81ef486c0a 100644 --- a/source4/scripting/python/samba/tests/samba3.py +++ b/source4/scripting/python/samba/tests/samba3.py @@ -24,8 +24,8 @@ from samba.samba3 import (WinsDatabase, SmbpasswdFile, ACB_NORMAL, from samba.tests import TestCase import os -DATADIR=os.path.join(os.path.dirname(__file__), "../../../../../testdata/samba3") -print "Samba 3 data dir: %s" % DATADIR +DATADIR = os.path.join(os.path.dirname(__file__), + "../../../../../testdata/samba3") class RegistryTestCase(TestCase): @@ -35,6 +35,7 @@ class RegistryTestCase(TestCase): def tearDown(self): self.registry.close() + super(RegistryTestCase, self).tearDown() def test_length(self): self.assertEquals(28, len(self.registry)) -- cgit