(self, module)
| 651 | # a few modifications to control output checking. |
| 652 | |
| 653 | def loadTestsFromModule(self, module): |
| 654 | #print '*** ipdoctest - lTM',module # dbg |
| 655 | |
| 656 | if not self.matches(module.__name__): |
| 657 | log.debug("Doctest doesn't want module %s", module) |
| 658 | return |
| 659 | |
| 660 | tests = self.finder.find(module,globs=self.globs, |
| 661 | extraglobs=self.extraglobs) |
| 662 | if not tests: |
| 663 | return |
| 664 | |
| 665 | # always use whitespace and ellipsis options |
| 666 | optionflags = doctest.NORMALIZE_WHITESPACE | doctest.ELLIPSIS |
| 667 | |
| 668 | tests.sort() |
| 669 | module_file = module.__file__ |
| 670 | if module_file[-4:] in ('.pyc', '.pyo'): |
| 671 | module_file = module_file[:-1] |
| 672 | for test in tests: |
| 673 | if not test.examples: |
| 674 | continue |
| 675 | if not test.filename: |
| 676 | test.filename = module_file |
| 677 | |
| 678 | yield DocTestCase(test, |
| 679 | optionflags=optionflags, |
| 680 | checker=self.checker) |
| 681 | |
| 682 | |
| 683 | def loadTestsFromFile(self, filename): |
no test coverage detected