Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent feaf9c6 commit 1e4823bCopy full SHA for 1e4823b
lib/matplotlib/testing/decorators.py
@@ -328,8 +328,13 @@ def _image_directories(func):
328
subdir = os.path.splitext(os.path.split(script_name)[1])[0]
329
else:
330
mods = module_name.split('.')
331
- mods.pop(0) # <- will be the name of the package being tested (in
332
- # most cases "matplotlib")
+ if len(mods) >= 3:
+ mods.pop(0)
333
+ # mods[0] will be the name of the package being tested (in
334
+ # most cases "matplotlib") However if this is a
335
+ # namespace package pip installed and run via the nose
336
+ # multiprocess plugin or as a specific test this may be
337
+ # missing. See https://github.com/matplotlib/matplotlib/issues/3314
338
assert mods.pop(0) == 'tests'
339
subdir = os.path.join(*mods)
340
0 commit comments