diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2015-02-05 19:57:26 +0100 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2015-03-06 04:41:49 +0100 |
commit | a6b2110abd061b0e03d8b684e5a2edd12fbc1c64 (patch) | |
tree | 65204fb4e6092cbbe803e0ff67c7ccf49f3294fa | |
parent | d459096e7c35f7bc7a83fd69cf0f70fc5ae4e15f (diff) | |
download | samba-a6b2110abd061b0e03d8b684e5a2edd12fbc1c64.tar.gz |
Implement TestCase.assertIn for older versions of Python.
Change-Id: I17d855166b439c0bd9344a17a454ea5bc6e057aa
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
-rw-r--r-- | python/samba/tests/__init__.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/python/samba/tests/__init__.py b/python/samba/tests/__init__.py index 413ac69833c..840e5c36285 100644 --- a/python/samba/tests/__init__.py +++ b/python/samba/tests/__init__.py @@ -61,6 +61,9 @@ class TestCase(unittest.TestCase): def skipTest(self, reason): raise SkipTest(reason) + def assertIn(self, member, container, msg=None): + self.assertTrue(member in container, msg) + def assertIs(self, a, b): self.assertTrue(a is b) |