##// END OF EJS Templates
add zmq checking in iptest
MinRK -
Show More
@@ -82,7 +82,7 b" warnings.filterwarnings('ignore', 'wxPython/wxWidgets release number mismatch',"
82 # Logic for skipping doctests
82 # Logic for skipping doctests
83 #-----------------------------------------------------------------------------
83 #-----------------------------------------------------------------------------
84
84
85 def test_for(mod):
85 def test_for(mod, min_version=None):
86 """Test to see if mod is importable."""
86 """Test to see if mod is importable."""
87 try:
87 try:
88 __import__(mod)
88 __import__(mod)
@@ -91,6 +91,9 b' def test_for(mod):'
91 # importable.
91 # importable.
92 return False
92 return False
93 else:
93 else:
94 if min_version:
95 return sys.modules[mod].__version__ >= min_version
96 else:
94 return True
97 return True
95
98
96 # Global dict where we can store information on what we have and what we don't
99 # Global dict where we can store information on what we have and what we don't
@@ -101,6 +104,7 b" have['curses'] = test_for('_curses')"
101 have['wx'] = test_for('wx')
104 have['wx'] = test_for('wx')
102 have['wx.aui'] = test_for('wx.aui')
105 have['wx.aui'] = test_for('wx.aui')
103 have['pexpect'] = test_for('pexpect')
106 have['pexpect'] = test_for('pexpect')
107 have['zmq'] = test_for('zmq', '2.0.10')
104
108
105 #-----------------------------------------------------------------------------
109 #-----------------------------------------------------------------------------
106 # Functions and classes
110 # Functions and classes
@@ -179,6 +183,9 b' def make_exclude():'
179 exclusions.extend([ipjoin('scripts', 'irunner'),
183 exclusions.extend([ipjoin('scripts', 'irunner'),
180 ipjoin('lib', 'irunner')])
184 ipjoin('lib', 'irunner')])
181
185
186 if not have['zmq']:
187 exclusions.append(ipjoin('zmq'))
188
182 # This is needed for the reg-exp to match on win32 in the ipdoctest plugin.
189 # This is needed for the reg-exp to match on win32 in the ipdoctest plugin.
183 if sys.platform == 'win32':
190 if sys.platform == 'win32':
184 exclusions = [s.replace('\\','\\\\') for s in exclusions]
191 exclusions = [s.replace('\\','\\\\') for s in exclusions]
General Comments 0
You need to be logged in to leave comments. Login now