@@ -2070,7 +2070,7 @@ def test_stairs_options():
20702070 ax .stairs (y [::- 1 ]* 3 + 14 , x , baseline = 26 ,
20712071 color = 'purple' , ls = '--' , lw = 2 , label = "F" )
20722072 ax .stairs (yn [::- 1 ]* 3 + 15 , x + 1 , baseline = np .linspace (27 , 25 , len (y )),
2073- color = 'blue' , ls = '--' , lw = 2 , label = "G" , fill = True )
2073+ color = 'blue' , ls = '--' , label = "G" , fill = True )
20742074 ax .stairs (y [:- 1 ][::- 1 ]* 2 + 11 , x [:- 1 ]+ 0.5 , color = 'black' , ls = '--' , lw = 2 ,
20752075 baseline = 12 , hatch = '//' , label = "H" )
20762076 ax .legend (loc = 0 )
@@ -2085,6 +2085,18 @@ def test_stairs_datetime():
20852085 plt .xticks (rotation = 30 )
20862086
20872087
2088+ @check_figures_equal (extensions = ['png' ])
2089+ def test_stairs_edge_handling (fig_test , fig_ref ):
2090+ # Test
2091+ test_ax = fig_test .add_subplot ()
2092+ test_ax .stairs ([1 , 2 , 3 ], color = 'red' , fill = True )
2093+
2094+ # Ref
2095+ ref_ax = fig_ref .add_subplot ()
2096+ st = ref_ax .stairs ([1 , 2 , 3 ], fill = True )
2097+ st .set_color ('red' )
2098+
2099+
20882100def contour_dat ():
20892101 x = np .linspace (- 3 , 5 , 150 )
20902102 y = np .linspace (- 3 , 5 , 120 )
0 commit comments