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 8607047 + 4bdae6b commit 9b593aeCopy full SHA for 9b593ae
lib/matplotlib/tests/__init__.py
@@ -11,7 +11,17 @@ def setup():
11
# The baseline images are created in this locale, so we should use
12
# it during all of the tests.
13
import locale
14
- locale.setlocale(locale.LC_ALL, str('en_US.UTF-8'))
+ import warnings
15
+
16
+ try:
17
+ locale.setlocale(locale.LC_ALL, str('en_US.UTF-8'))
18
+ except:
19
20
+ locale.setlocale(locale.LC_ALL, str('English_United States.1252'))
21
22
+ warnings.warn(
23
+ "Could not set locale to English/United States. "
24
+ "Some date-related tests may fail")
25
26
use('Agg', warn=False) # use Agg backend for these tests
27
0 commit comments