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

Function test_table_fontsize

lib/matplotlib/tests/test_table.py:274–283  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

272
273
274def test_table_fontsize():
275 # Test that the passed fontsize propagates to cells
276 tableData = [['a', 1], ['b', 2]]
277 fig, ax = plt.subplots()
278 test_fontsize = 20
279 t = ax.table(cellText=tableData, loc='top', fontsize=test_fontsize)
280 cell_fontsize = t[(0, 0)].get_fontsize()
281 assert cell_fontsize == test_fontsize, f"Actual:{test_fontsize},got:{cell_fontsize}"
282 cell_fontsize = t[(1, 1)].get_fontsize()
283 assert cell_fontsize == test_fontsize, f"Actual:{test_fontsize},got:{cell_fontsize}"

Callers

nothing calls this directly

Calls 2

subplotsMethod · 0.45
get_fontsizeMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…