Skip to content

Commit c5b5bb4

Browse files
committed
Fix test
1 parent dc291e0 commit c5b5bb4

File tree

2 files changed

+7
-5
lines changed

2 files changed

+7
-5
lines changed

lib/matplotlib/style/core.py

+6-4
Original file line numberDiff line numberDiff line change
@@ -53,12 +53,14 @@ def use(name):
5353
mpl.rcParams.update(library[style])
5454
else:
5555
try:
56-
settings = mpl._rc_params_in_file(style)
57-
mpl.rcParams.update(settings)
56+
rc = rc_params_from_file(style, use_default_template=False)
57+
print rc
58+
print type(rc)
59+
mpl.rcParams.update(rc)
5860
except:
5961
msg = ("'%s' not found in the style library and input is "
60-
"not a valid URL. See `style.available` for list of "
61-
"available styles.")
62+
"not a valid URL or path. See `style.available` for "
63+
"list of available styles.")
6264
raise ValueError(msg % style)
6365

6466

lib/matplotlib/tests/test_style.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ def test_use_url():
5050
with temp_style('test', DUMMY_SETTINGS):
5151
style.use('https://gist.github.com/adrn/6590261/raw')
5252

53-
assert mpl.rcParams['axes.facecolor'] == "adeade"
53+
assert mpl.rcParams['axes.facecolor'] == "#adeade"
5454

5555
def test_context():
5656
mpl.rcParams[PARAM] = 'gray'

0 commit comments

Comments
 (0)