diff options
author | Adrien Di Mascio <Adrien.DiMascio@logilab.fr> | 2007-04-11 17:40:55 +0200 |
---|---|---|
committer | Adrien Di Mascio <Adrien.DiMascio@logilab.fr> | 2007-04-11 17:40:55 +0200 |
commit | 8f303842aba31e8ba4419e975e237080d44b8fe0 (patch) | |
tree | b46d61682aeda71faa95123a5299adf56c060982 | |
parent | b8b506ddff2aff7bacce9deca6627731c65f5517 (diff) | |
download | logilab-common-8f303842aba31e8ba4419e975e237080d44b8fe0.tar.gz |
explicit check that suite is a function, not a callable
-rw-r--r-- | testlib.py | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -608,7 +608,7 @@ Examples: self.capture += 1 if len(args) == 0 and self.defaultTest is None: suitefunc = getattr(self.module, 'suite', None) - if callable(suitefunc): + if hasattr(suitefunc, 'im_func'): self.test = self.module.suite() else: self.test = self.testLoader.loadTestsFromModule(self.module) |