| 253 | |
| 254 | |
| 255 | def 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 | |
| 268 | def test_ft2font_charmaps(): |