##// END OF EJS Templates
Merge pull request #13202 from Kojoley/fix-unintentional-skipping-of-module-level-doctests...
Matthias Bussonnier -
r26876:a05271cc merge
parent child Browse files
Show More
@@ -142,7 +142,7 b' from traitlets.config.configurable import Configurable'
142 import __main__
142 import __main__
143
143
144 # skip module docstests
144 # skip module docstests
145 skip_doctest = True
145 __skip_doctest__ = True
146
146
147 try:
147 try:
148 import jedi
148 import jedi
@@ -116,6 +116,8 b' from IPython.utils import coloransi, py3compat'
116 from IPython.core.excolors import exception_colors
116 from IPython.core.excolors import exception_colors
117 from IPython.testing.skipdoctest import skip_doctest
117 from IPython.testing.skipdoctest import skip_doctest
118
118
119 # skip module docstests
120 __skip_doctest__ = True
119
121
120 prompt = 'ipdb> '
122 prompt = 'ipdb> '
121
123
@@ -97,7 +97,7 b' Some of the known remaining caveats are:'
97 - C extension modules cannot be reloaded, and so cannot be autoreloaded.
97 - C extension modules cannot be reloaded, and so cannot be autoreloaded.
98 """
98 """
99
99
100 skip_doctest = True
100 __skip_doctest__ = True
101
101
102 # -----------------------------------------------------------------------------
102 # -----------------------------------------------------------------------------
103 # Copyright (C) 2000 Thomas Heller
103 # Copyright (C) 2000 Thomas Heller
@@ -125,7 +125,7 b' class DocTestFinder(doctest.DocTestFinder):'
125 add them to `tests`.
125 add them to `tests`.
126 """
126 """
127 print('_find for:', obj, name, module) # dbg
127 print('_find for:', obj, name, module) # dbg
128 if hasattr(obj,"skip_doctest"):
128 if bool(getattr(obj, "__skip_doctest__", False)):
129 #print 'SKIPPING DOCTEST FOR:',obj # dbg
129 #print 'SKIPPING DOCTEST FOR:',obj # dbg
130 obj = DocTestSkip(obj)
130 obj = DocTestSkip(obj)
131
131
@@ -15,5 +15,5 b' def skip_doctest(f):'
15 This decorator allows you to mark a function whose docstring you wish to
15 This decorator allows you to mark a function whose docstring you wish to
16 omit from testing, while preserving the docstring for introspection, help,
16 omit from testing, while preserving the docstring for introspection, help,
17 etc."""
17 etc."""
18 f.skip_doctest = True
18 f.__skip_doctest__ = True
19 return f
19 return f
General Comments 0
You need to be logged in to leave comments. Login now