Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 236411c

Browse files
committed
Merge pull request #6022 from anntzer/cleanup-generative-tests-again
Make @cleanup *really* support generative tests.
2 parents 0805e16 + 56ec0c6 commit 236411c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/testing/decorators.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ def cleanup(style=None):
130130
# writing a decorator with optional arguments.
131131

132132
def make_cleanup(func):
133-
if inspect.isgenerator(func):
133+
if inspect.isgeneratorfunction(func):
134134
@functools.wraps(func)
135135
def wrapped_callable(*args, **kwargs):
136136
original_units_registry = matplotlib.units.registry.copy()

0 commit comments

Comments
 (0)