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

Function test_annotation_update

lib/matplotlib/tests/test_text.py:657–665  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

655
656
657def test_annotation_update():
658 fig, ax = plt.subplots(1, 1)
659 an = ax.annotate('annotation', xy=(0.5, 0.5))
660 extent1 = an.get_window_extent(fig.canvas.get_renderer())
661 fig.tight_layout()
662 extent2 = an.get_window_extent(fig.canvas.get_renderer())
663
664 assert not np.allclose(extent1.get_points(), extent2.get_points(),
665 rtol=1e-6)
666
667
668@check_figures_equal()

Callers

nothing calls this directly

Calls 7

annotateMethod · 0.80
allcloseMethod · 0.80
subplotsMethod · 0.45
get_window_extentMethod · 0.45
get_rendererMethod · 0.45
tight_layoutMethod · 0.45
get_pointsMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…