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.
2 parents e940795 + bda6e6a commit efc2402Copy full SHA for efc2402
lib/matplotlib/testing/decorators.py
@@ -180,17 +180,14 @@ class ImageComparisonTest(CleanupTest):
180
@classmethod
181
def setup_class(cls):
182
CleanupTest.setup_class()
183
- cls._initial_settings = mpl.rcParams.copy()
184
try:
185
matplotlib.style.use(cls._style)
+ matplotlib.testing.set_font_settings_for_testing()
186
+ cls._func()
187
except:
188
# Restore original settings before raising errors during the update.
- mpl.rcParams.clear()
189
- mpl.rcParams.update(cls._initial_settings)
+ CleanupTest.teardown_class()
190
raise
191
- cls.original_settings = cls._initial_settings
192
- matplotlib.testing.set_font_settings_for_testing()
193
- cls._func()
194
195
196
def teardown_class(cls):
0 commit comments