8000 Corrected the test. · matplotlib/matplotlib@d435754 · GitHub
[go: up one dir, main page]

Skip to content

Commit d435754

Browse files
committed
Corrected the test.
1 parent d29bb26 commit d435754

File tree

1 file changed

+9
-2
lines changed

1 file changed

+9
-2
lines changed

lib/matplotlib/tests/test_axes.py

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,21 @@ def get_next_color():
5959

6060

6161
def test_get_next_color():
62+
"""
63+
Testing that our simplified helper function works with _parse_scatter_color_args.
64+
"""
6265
result = mpl.axes.Axes._parse_scatter_color_args(
63-
c=None,
66+
c=None,
6467
edgecolors=None,
6568
kwargs={},
6669
xsize=2,
6770
get_next_color_func=get_next_color
6871
)
69-
assert result.colors == 'blue'
72+
c, colors, _edgecolors = result
73+
assert c == 'b', f"Expected color spec 'b', got {c}"
74+
assert np.array_equal(colors, [[0, 0, 1, 1]]), \
75+
f"Expected [[0, 0, 1, 1]], got {colors}"
76+
assert _edgecolors is None, f"Expected edgecolors None, got {_edgecolors}"
7077

7178

7279
@check_figures_equal(extensions=["png"])

0 commit comments

Comments
 (0)
0