MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / test_axline_transaxes

Function test_axline_transaxes

lib/matplotlib/tests/test_axes.py:5703–5716  ·  view source on GitHub ↗
(fig_test, fig_ref)

Source from the content-addressed store, hash-verified

5701
5702@check_figures_equal()
5703def test_axline_transaxes(fig_test, fig_ref):
5704 ax = fig_test.subplots()
5705 ax.set(xlim=(-1, 1), ylim=(-1, 1))
5706 ax.axline((0, 0), slope=1, transform=ax.transAxes)
5707 ax.axline((1, 0.5), slope=1, color='C1', transform=ax.transAxes)
5708 ax.axline((0.5, 0.5), slope=0, color='C2', transform=ax.transAxes)
5709 ax.axline((0.5, 0), (0.5, 1), color='C3', transform=ax.transAxes)
5710
5711 ax = fig_ref.subplots()
5712 ax.set(xlim=(-1, 1), ylim=(-1, 1))
5713 ax.plot([-1, 1], [-1, 1])
5714 ax.plot([0, 1], [-1, 0], color='C1')
5715 ax.plot([-1, 1], [0, 0], color='C2')
5716 ax.plot([0, 0], [-1, 1], color='C3')
5717
5718
5719@check_figures_equal()

Callers

nothing calls this directly

Calls 4

axlineMethod · 0.80
subplotsMethod · 0.45
setMethod · 0.45
plotMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…