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

Function test_ft2font_features

lib/matplotlib/tests/test_ft2font.py:255–265  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

253
254
255def test_ft2font_features():
256 # Smoke test that these are accepted as intended.
257 file = fm.findfont('DejaVu Sans')
258 font = ft2font.FT2Font(file)
259 font.set_text('foo', features=None) # unset
260 font.set_text('foo', features=['calt', 'dlig']) # list
261 font.set_text('foo', features=('calt', 'dlig')) # tuple
262 with pytest.raises(TypeError):
263 font.set_text('foo', features=123)
264 with pytest.raises(TypeError):
265 font.set_text('foo', features=[123, 456])
266
267
268def test_ft2font_charmaps():

Callers

nothing calls this directly

Calls 2

findfontMethod · 0.80
set_textMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…