Skip to content

Commit 1bb7fab

Browse files
committed
Rename a test_linestyle_accent to test_linestyle_variants and change getting getting value from ls_mapper_r
1 parent 9e70828 commit 1bb7fab

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

lib/matplotlib/lines.py

+1-2
Original file line numberDiff line numberDiff line change
@@ -972,8 +972,7 @@ def set_linestyle(self, linestyle):
972972
break
973973

974974
if linestyle not in self._lineStyles:
975-
if linestyle in ls_mapper_r:
976-
linestyle = ls_mapper_r[linestyle]
975+
linestyle = ls_mapper_r.get(linestyle, linestyle)
977976
else:
978977
verbose.report('Unrecognized line style %s, %s' %
979978
(linestyle, type(linestyle)))

lib/matplotlib/tests/test_lines.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ def test_line_colors():
9393

9494

9595
@cleanup
96-
def test_linestyle_accents():
96+
def test_linestyle_variants():
9797
fig = plt.figure()
9898
ax = fig.add_subplot(1, 1, 1)
9999
for ls in ["-", "solid", "--", "dashed",

0 commit comments

Comments
 (0)