Skip to content

Commit e9da814

Browse files
committed
Add a smoke test for star tuple markers.
We don't really have an equivalent for it, so just do a smoke test.
1 parent 0d33834 commit e9da814

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

lib/matplotlib/tests/test_marker.py

+12
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
import numpy as np
2+
import matplotlib.pyplot as plt
23
from matplotlib import markers
34
from matplotlib.path import Path
45
from matplotlib.testing.decorators import check_figures_equal
@@ -86,6 +87,17 @@ def test_poly_marker(fig_test, fig_ref):
8687
ax_ref.set(xlim=(-0.5, 5.5), ylim=(-0.5, 5.5))
8788

8889

90+
def test_star_marker():
91+
# We don't really have a strict equivalent to this marker, so we'll just do
92+
# a smoke test.
93+
size = 20**2
94+
95+
fig, ax = plt.subplots()
96+
ax.scatter([0], [0], marker=(5, 1), s=size)
97+
ax.scatter([1], [1], marker=(5, 1, 0), s=size)
98+
ax.set(xlim=(-0.5, 0.5), ylim=(-0.5, 1.5))
99+
100+
89101
# The asterisk marker is really a star with 0-size inner circle, so the ends
90102
# are corners and get a slight bevel. The reference markers are just singular
91103
# lines without corners, so they have no bevel, and we need to add a slight

0 commit comments

Comments
 (0)