diff options
author | Yann Leboulanger <asterix@lagaule.org> | 2008-10-11 13:44:12 +0400 |
---|---|---|
committer | Yann Leboulanger <asterix@lagaule.org> | 2008-10-11 13:44:12 +0400 |
commit | 73aee40542e00c51eb0369e37211748bd0b03448 (patch) | |
tree | 38c91e9bd698b07e1029b3aef32b9e1c5a6407ce /test/lib | |
parent | ed748fdda3f494300dd76638745805d77e2b52ce (diff) |
[thorstenp] replace none equality test with identity test
Diffstat (limited to 'test/lib')
-rw-r--r-- | test/lib/mock.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/test/lib/mock.py b/test/lib/mock.py index 5d6348b1a..c4a4e6332 100644 --- a/test/lib/mock.py +++ b/test/lib/mock.py @@ -116,7 +116,7 @@ class Mock: raise a MockInterfaceError. Based on the Python 2.3.3 Reference Manual section 5.3.4: Calls. """ - if self.realClassMethods == None: + if self.realClassMethods is None: return if name not in self.realClassMethods: raise MockInterfaceError("Calling mock method '%s' that was not found in the original class" % name) @@ -411,7 +411,7 @@ def NOT(cond): def MATCHES(regex, *args, **kwargs): compiled_regex = re.compile(regex, *args, **kwargs) def testFn(param): - return compiled_regex.match(param) != None + return compiled_regex.match(param) is not None return testFn def SEQ(*sequence): |