mirror of
https://github.com/samba-team/samba.git
synced 2025-01-26 10:04:02 +03:00
Add custom implementations of TestCase.assertIs and TestCase.assertIsNot, for Python2.6.
Change-Id: I3b806abdaf9540b7c39c961c179c2d2b15d327fe Signed-off-by: Jelmer Vernooij <jelmer@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
This commit is contained in:
parent
85c1dc9908
commit
e3a9feb698
@ -57,6 +57,14 @@ class TestCase(unittest.TestCase):
|
||||
def skipTest(self, reason):
|
||||
raise SkipTest(reason)
|
||||
|
||||
if not getattr(unittest.TestCase, "assertIs", None):
|
||||
def assertIs(self, a, b):
|
||||
self.assertTrue(a is b)
|
||||
|
||||
if not getattr(unittest.TestCase, "assertIsNot", None):
|
||||
def assertIsNot(self, a, b):
|
||||
self.assertTrue(a is not b)
|
||||
|
||||
|
||||
class LdbTestCase(unittest.TestCase):
|
||||
"""Trivial test case for running tests against a LDB."""
|
||||
|
Loading…
x
Reference in New Issue
Block a user