mirror of
https://github.com/samba-team/samba.git
synced 2025-08-02 00:22:11 +03:00
Improve formatting in Python file.
This commit is contained in:
@ -26,6 +26,7 @@ import tempfile
|
|||||||
import unittest
|
import unittest
|
||||||
|
|
||||||
class LdbTestCase(unittest.TestCase):
|
class LdbTestCase(unittest.TestCase):
|
||||||
|
|
||||||
"""Trivial test case for running tests against a LDB."""
|
"""Trivial test case for running tests against a LDB."""
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
self.filename = os.tempnam()
|
self.filename = os.tempnam()
|
||||||
@ -41,6 +42,7 @@ class LdbTestCase(unittest.TestCase):
|
|||||||
|
|
||||||
|
|
||||||
class TestCaseInTempDir(unittest.TestCase):
|
class TestCaseInTempDir(unittest.TestCase):
|
||||||
|
|
||||||
def setUp(self):
|
def setUp(self):
|
||||||
super(TestCaseInTempDir, self).setUp()
|
super(TestCaseInTempDir, self).setUp()
|
||||||
self.tempdir = tempfile.mkdtemp()
|
self.tempdir = tempfile.mkdtemp()
|
||||||
@ -52,6 +54,7 @@ class TestCaseInTempDir(unittest.TestCase):
|
|||||||
|
|
||||||
|
|
||||||
class SubstituteVarTestCase(unittest.TestCase):
|
class SubstituteVarTestCase(unittest.TestCase):
|
||||||
|
|
||||||
def test_empty(self):
|
def test_empty(self):
|
||||||
self.assertEquals("", samba.substitute_var("", {}))
|
self.assertEquals("", samba.substitute_var("", {}))
|
||||||
|
|
||||||
@ -75,6 +78,7 @@ class SubstituteVarTestCase(unittest.TestCase):
|
|||||||
|
|
||||||
|
|
||||||
class LdbExtensionTests(TestCaseInTempDir):
|
class LdbExtensionTests(TestCaseInTempDir):
|
||||||
|
|
||||||
def test_searchone(self):
|
def test_searchone(self):
|
||||||
path = self.tempdir + "/searchone.ldb"
|
path = self.tempdir + "/searchone.ldb"
|
||||||
l = samba.Ldb(path)
|
l = samba.Ldb(path)
|
||||||
@ -90,6 +94,7 @@ cmdline_loadparm = None
|
|||||||
cmdline_credentials = None
|
cmdline_credentials = None
|
||||||
|
|
||||||
class RpcInterfaceTestCase(unittest.TestCase):
|
class RpcInterfaceTestCase(unittest.TestCase):
|
||||||
|
|
||||||
def get_loadparm(self):
|
def get_loadparm(self):
|
||||||
assert cmdline_loadparm is not None
|
assert cmdline_loadparm is not None
|
||||||
return cmdline_loadparm
|
return cmdline_loadparm
|
||||||
|
Reference in New Issue
Block a user