()
| 6241 | @image_comparison(['twin_spines_on_top.png', 'twin_spines_on_top.png'], |
| 6242 | remove_text=True, style='_classic_test') |
| 6243 | def test_twin_spines_on_top(): |
| 6244 | matplotlib.rcParams['axes.linewidth'] = 48.0 |
| 6245 | matplotlib.rcParams['lines.linewidth'] = 48.0 |
| 6246 | |
| 6247 | fig = plt.figure() |
| 6248 | ax1 = fig.add_subplot(1, 1, 1) |
| 6249 | |
| 6250 | data = np.array([[1000, 1100, 1200, 1250], |
| 6251 | [310, 301, 360, 400]]) |
| 6252 | |
| 6253 | ax2 = ax1.twinx() |
| 6254 | |
| 6255 | ax1.plot(data[0], data[1]/1E3, color='#BEAED4') |
| 6256 | ax1.fill_between(data[0], data[1]/1E3, color='#BEAED4', alpha=.8) |
| 6257 | |
| 6258 | ax2.plot(data[0], data[1]/1E3, color='#7FC97F') |
| 6259 | ax2.fill_between(data[0], data[1]/1E3, color='#7FC97F', alpha=.5) |
| 6260 | |
| 6261 | # Reuse testcase from above for a labeled data test |
| 6262 | data = {"i": data[0], "j": data[1]/1E3} |
| 6263 | fig = plt.figure() |
| 6264 | ax1 = fig.add_subplot(1, 1, 1) |
| 6265 | ax2 = ax1.twinx() |
| 6266 | ax1.plot("i", "j", color='#BEAED4', data=data) |
| 6267 | ax1.fill_between("i", "j", color='#BEAED4', alpha=.8, data=data) |
| 6268 | ax2.plot("i", "j", color='#7FC97F', data=data) |
| 6269 | ax2.fill_between("i", "j", color='#7FC97F', alpha=.5, data=data) |
| 6270 | |
| 6271 | |
| 6272 | @pytest.mark.parametrize("grid_which, major_visible, minor_visible", [ |
nothing calls this directly
no test coverage detected
searching dependent graphs…