##// END OF EJS Templates
Fixes to testing system: ipdocetst plugin wasn't being properly loaded.
Fernando Perez -
Show More
@@ -1,4 +1,3 b''
1 #!/usr/bin/env python
2 1 # -*- coding: utf-8 -*-
3 2 """IPython Test Suite Runner.
4 3 """
@@ -18,18 +17,8 b' def main():'
18 17 warnings.filterwarnings('ignore',
19 18 'This will be removed soon. Use IPython.testing.util instead')
20 19
21
22 # construct list of plugins, omitting the existing doctest plugin
23 plugins = [IPythonDoctest()]
24 for p in nose.plugins.builtin.plugins:
25 plug = p()
26 if plug.name == 'doctest':
27 continue
28
29 #print 'adding plugin:',plug.name # dbg
30 plugins.append(plug)
31
32 argv = sys.argv + ['--doctest-tests','--doctest-extension=txt',
20 argv = sys.argv + [ '--with-ipdoctest',
21 '--doctest-tests','--doctest-extension=txt',
33 22 '--detailed-errors',
34 23
35 24 # We add --exe because of setuptools' imbecility (it
@@ -50,4 +39,15 b' def main():'
50 39 if not has_ip:
51 40 argv.append('IPython')
52 41
42 # construct list of plugins, omitting the existing doctest plugin
43 plugins = [IPythonDoctest()]
44 for p in nose.plugins.builtin.plugins:
45 plug = p()
46 if plug.name == 'doctest':
47 continue
48
49 #print '*** adding plugin:',plug.name # dbg
50 plugins.append(plug)
51
52
53 53 TestProgram(argv=argv,plugins=plugins)
@@ -36,8 +36,8 b' deco:'
36 36 magic: plugin
37 37 $(NOSE) IPython.Magic
38 38
39 ipipe: plugin
40 $(NOSE) IPython.Extensions.ipipe
39 excolors: plugin
40 $(NOSE) IPython.excolors
41 41
42 42 iplib: plugin
43 43 $(NOSE) IPython.iplib
@@ -688,6 +688,7 b' class ExtensionDoctest(doctests.Doctest):'
688 688 self.globs = None
689 689 self.extraglobs = None
690 690
691
691 692 def loadTestsFromExtensionModule(self,filename):
692 693 bpath,mod = os.path.split(filename)
693 694 modname = os.path.splitext(mod)[0]
@@ -703,7 +704,7 b' class ExtensionDoctest(doctests.Doctest):'
703 704 # a few modifications to control output checking.
704 705
705 706 def loadTestsFromModule(self, module):
706 #print 'lTM',module # dbg
707 #print '*** ipdoctest - lTM',module # dbg
707 708
708 709 if not self.matches(module.__name__):
709 710 log.debug("Doctest doesn't want module %s", module)
@@ -733,8 +734,6 b' class ExtensionDoctest(doctests.Doctest):'
733 734
734 735
735 736 def loadTestsFromFile(self, filename):
736 #print 'lTF',filename # dbg
737
738 737 if is_extension_module(filename):
739 738 for t in self.loadTestsFromExtensionModule(filename):
740 739 yield t
@@ -761,7 +760,7 b' class ExtensionDoctest(doctests.Doctest):'
761 760 Modified version that accepts extension modules as valid containers for
762 761 doctests.
763 762 """
764 print 'Filename:',filename # dbg
763 #print '*** ipdoctest- wantFile:',filename # dbg
765 764
766 765 # XXX - temporarily hardcoded list, will move to driver later
767 766 exclude = ['IPython/external/',
General Comments 0
You need to be logged in to leave comments. Login now