Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 4018a62

Browse files
committed
feat: add datetime test for StepPatch
1 parent 6d17761 commit 4018a62

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

lib/matplotlib/tests/test_axes.py

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1877,6 +1877,15 @@ def test_stairs_options():
18771877
ax.legend(loc=0)
18781878

18791879

1880+
@image_comparison(['test_stairs_datetime.png'])
1881+
def test_stairs_datetime():
1882+
f, ax = plt.subplots(constrained_layout=True)
1883+
ax.stairs(np.arange(36),
1884+
np.arange(np.datetime64('2001-12-27'),
1885+
np.datetime64('2002-02-02')))
1886+
plt.xticks(rotation=30)
1887+
1888+
18801889
def contour_dat():
18811890
x = np.linspace(-3, 5, 150)
18821891
y = np.linspace(-3, 5, 120)

0 commit comments

Comments
 (0)