diff options
author | Dan Wandschneider <daniel.wandschneider@schrodinger.com> | 2016-06-08 19:51:55 -0400 |
---|---|---|
committer | Dan Wandschneider <daniel.wandschneider@schrodinger.com> | 2016-06-08 19:51:55 -0400 |
commit | 743058bbaf63df4e1dd32e565210eee39019fd1e (patch) | |
tree | 83ff018082cd8c296e41fd6d1e393692880ace56 /coverage/backunittest.py | |
parent | 3c214385710b6ecb10c8ac59a3f7e50384e654e4 (diff) | |
download | python-coveragepy-git-743058bbaf63df4e1dd32e565210eee39019fd1e.tar.gz |
Use caoverage.py's canonical backwards compatibility infrastructure in new test.
Diffstat (limited to 'coverage/backunittest.py')
-rw-r--r-- | coverage/backunittest.py | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/coverage/backunittest.py b/coverage/backunittest.py index 09574ccb..29fea86f 100644 --- a/coverage/backunittest.py +++ b/coverage/backunittest.py @@ -40,3 +40,8 @@ class TestCase(unittest.TestCase): if not unittest_has('assertRegex'): def assertRegex(self, *args, **kwargs): return self.assertRegexpMatches(*args, **kwargs) + + if not unittest_has('assertNotIn'): + def assertNotIn(self, needle, haystack): + self.assertTrue(needle not in haystack) + |