(fig_test, fig_ref)
| 2697 | |
| 2698 | @check_figures_equal() |
| 2699 | def test_stairs_fill(fig_test, fig_ref): |
| 2700 | h, bins = [1, 2, 3, 4, 2], [0, 1, 2, 3, 4, 5] |
| 2701 | bs = -2 |
| 2702 | # Test |
| 2703 | test_axes = fig_test.subplots(2, 2).flatten() |
| 2704 | test_axes[0].stairs(h, bins, fill=True) |
| 2705 | test_axes[1].stairs(h, bins, orientation='horizontal', fill=True) |
| 2706 | test_axes[2].stairs(h, bins, baseline=bs, fill=True) |
| 2707 | test_axes[3].stairs(h, bins, baseline=bs, orientation='horizontal', |
| 2708 | fill=True) |
| 2709 | |
| 2710 | # # Ref |
| 2711 | ref_axes = fig_ref.subplots(2, 2).flatten() |
| 2712 | ref_axes[0].fill_between(bins, np.append(h, h[-1]), step='post', lw=0) |
| 2713 | ref_axes[0].set_ylim(0, None) |
| 2714 | ref_axes[1].fill_betweenx(bins, np.append(h, h[-1]), step='post', lw=0) |
| 2715 | ref_axes[1].set_xlim(0, None) |
| 2716 | ref_axes[2].fill_between(bins, np.append(h, h[-1]), |
| 2717 | np.ones(len(h)+1)*bs, step='post', lw=0) |
| 2718 | ref_axes[2].set_ylim(bs, None) |
| 2719 | ref_axes[3].fill_betweenx(bins, np.append(h, h[-1]), |
| 2720 | np.ones(len(h)+1)*bs, step='post', lw=0) |
| 2721 | ref_axes[3].set_xlim(bs, None) |
| 2722 | |
| 2723 | |
| 2724 | @check_figures_equal() |
nothing calls this directly
no test coverage detected
searching dependent graphs…