-
Notifications
You must be signed in to change notification settings - Fork 49
Closed
Description
My code (simplified)
@pytest.fixture(params=['/some/data1', '/some/data2'])
def dataframe(reqeust):
return transform(request.param)
@pytest.mark.mpl_image_compare(baseline_dir=BASELINE_DIR)
def test_plot(dataframe):
fig = my_plotter(dataframe)
return figWhen I run pytest test_my_plotters.py --mpl --mpl-generate-path=baseline, I get something like (simplified):
IOError: [Errno 2] No such file or directory: '.../baseline/test_plot_/some/data1.png'
../venv/local/lib/python2.7/site-packages/matplotlib/backends/backend_agg.py:532: IOError
In short, print_png in matplotlib/backends/backend_agg.py is failing because the intermediate paths (.../some/...) is missing.
This work around seems to work (gshiba@3c8aa6e) but not sure if this is the right approach.
Thanks
Metadata
Metadata
Assignees
Labels
No labels