Skip to content

Commit 1ad3408

Browse files
tacaswellKojoley
authored andcommitted
TST: fix scatter test
Should create two identical figures to exercise data kwarg
1 parent 3f3991a commit 1ad3408

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/matplotlib/tests/test_axes.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1266,16 +1266,16 @@ def test_hist2d_transpose():
12661266
ax.hist2d(x, y, bins=10)
12671267

12681268

1269-
@image_comparison(baseline_images=['scatter'])
1269+
@image_comparison(baseline_images=['scatter', 'scatter'])
12701270
def test_scatter_plot():
1271-
ax = plt.axes()
1271+
fig, ax = plt.subplots()
12721272
data = {"x": [3, 4, 2, 6], "y": [2, 5, 2, 3], "c": ['r', 'y', 'b', 'lime'],
12731273
"s": [24, 15, 19, 29]}
12741274

12751275
ax.scatter(data["x"], data["y"], c=data["c"], s=data["s"])
12761276

12771277
# Reuse testcase from above for a labeled data test
1278-
ax = plt.axes()
1278+
fig, ax = plt.subplots()
12791279
ax.scatter("x", "y", c="c", s="s", data=data)
12801280

12811281

0 commit comments

Comments
 (0)