Skip to content

Commit 389fdbc

Browse files
committed
Suppress unsubscriptable-object false positive
1 parent 9969936 commit 389fdbc

3 files changed

Lines changed: 6 additions & 0 deletions

File tree

tests/test_checks_glyf.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@ def test_check_nested_components(check):
1818

1919
# We need to create a nested component. "second" has components, so setting
2020
# one of "quotedbl"'s components to "second" should do it.
21+
# pylint: disable=[E1136] # false positive
2122
ttFont["glyf"]["quotedbl"].components[0].glyphName = "second"
23+
# pylint: enable=[E1136]
2224

2325
assert_results_contain(check(ttFont), FAIL, "found-nested-components")

tests/test_checks_opentype_glyf.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,10 @@ def test_check_glyf_non_transformed_duplicate_components(check):
5959
assert_PASS(check(ttFont))
6060

6161
# Set qutodbl's components to have the same x,y values
62+
# pylint: disable=[E1136] # false positive
6263
ttFont["glyf"]["quotedbl"].components[0].x = 0
6364
ttFont["glyf"]["quotedbl"].components[1].x = 0
6465
ttFont["glyf"]["quotedbl"].components[0].y = 0
6566
ttFont["glyf"]["quotedbl"].components[1].y = 0
67+
# pylint: enable=[E1136]
6668
assert_results_contain(check(ttFont), FAIL, "found-duplicates")

tests/test_checks_opentype_post.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,10 +194,12 @@ def test_check_italic_angle(check):
194194

195195
ttFont = TTFont(TEST_FILE("cairo/CairoPlay-Italic.rightslanted.ttf"))
196196
assert_PASS(check(MockFont(ttFont=ttFont, style="Italic")))
197+
# pylint: disable=[E1136] # false positive
197198
ttFont["glyf"]["I"].endPtsOfContours = []
198199
ttFont["glyf"]["I"].coordinates = []
199200
ttFont["glyf"]["I"].flags = []
200201
ttFont["glyf"]["I"].numberOfContours = 0
202+
# pylint: enable=[E1136]
201203
assert_results_contain(
202204
check(MockFont(ttFont=ttFont, style="Italic")), WARN, "empty-glyphs"
203205
)

0 commit comments

Comments
 (0)