File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -143,7 +143,7 @@ def switch_backend(backend):
143143 yield
144144
145145
146- def _close_figure (fig ):
146+ def close_mpl_figure (fig ):
147147 "Close a given matplotlib Figure. Any other type of figure is ignored"
148148
149149 import matplotlib .pyplot as plt
@@ -244,7 +244,7 @@ def item_function_wrapper(*args, **kwargs):
244244 test_image = os .path .abspath (os .path .join (result_dir , filename ))
245245
246246 fig .savefig (test_image , ** savefig_kwargs )
247- _close_figure (fig )
247+ close_mpl_figure (fig )
248248
249249 # Find path to baseline image
250250 if baseline_remote :
@@ -275,7 +275,7 @@ def item_function_wrapper(*args, **kwargs):
275275 os .makedirs (self .generate_dir )
276276
277277 fig .savefig (os .path .abspath (os .path .join (self .generate_dir , filename )), ** savefig_kwargs )
278- _close_figure (fig )
278+ close_mpl_figure (fig )
279279 pytest .skip ("Skipping test, since generating data" )
280280
281281 if item .cls is not None :
@@ -312,7 +312,7 @@ def item_function_wrapper(*args, **kwargs):
312312 else : # function
313313 fig = original (* args , ** kwargs )
314314
315- _close_figure (fig )
315+ close_mpl_figure (fig )
316316
317317 if item .cls is not None :
318318 setattr (item .cls , item .function .__name__ , item_function_wrapper )
You can’t perform that action at this time.
0 commit comments