@@ -139,7 +139,8 @@ def test_multiline():
139139 ax .set_yticks ([])
140140
141141
142- @image_comparison (['multiline2' ], style = 'mpl20' )
142+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
143+ @image_comparison (['multiline2' ], style = 'mpl20' , tol = 0.05 )
143144def test_multiline2 ():
144145 # Remove this line when this test image is regenerated.
145146 plt .rcParams ['text.kerning_factor' ] = 6
@@ -210,7 +211,8 @@ def test_antialiasing():
210211 mpl .rcParams ['text.antialiased' ] = False # Should not affect existing text.
211212
212213
213- @image_comparison (['text_contains.png' ])
214+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
215+ @image_comparison (['text_contains.png' ], tol = 0.05 )
214216def test_contains ():
215217 fig = plt .figure ()
216218 ax = plt .axes ()
@@ -279,7 +281,8 @@ def test_titles():
279281 ax .set_yticks ([])
280282
281283
282- @image_comparison (['text_alignment' ], style = 'mpl20' )
284+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
285+ @image_comparison (['text_alignment' ], style = 'mpl20' , tol = 0.08 )
283286def test_alignment ():
284287 plt .figure ()
285288 ax = plt .subplot (1 , 1 , 1 )
@@ -1132,8 +1135,9 @@ def test_empty_annotation_get_window_extent():
11321135 assert points [0 , 1 ] == 50.0
11331136
11341137
1138+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
11351139@image_comparison (baseline_images = ['basictext_wrap' ],
1136- extensions = ['png' ])
1140+ extensions = ['png' ], tol = 0.3 )
11371141def test_basic_wrap ():
11381142 fig = plt .figure ()
11391143 plt .axis ([0 , 10 , 0 , 10 ])
@@ -1149,8 +1153,9 @@ def test_basic_wrap():
11491153 plt .text (- 1 , 0 , t , ha = 'left' , rotation = - 15 , wrap = True )
11501154
11511155
1156+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
11521157@image_comparison (baseline_images = ['fonttext_wrap' ],
1153- extensions = ['png' ])
1158+ extensions = ['png' ], tol = 0.3 )
11541159def test_font_wrap ():
11551160 fig = plt .figure ()
11561161 plt .axis ([0 , 10 , 0 , 10 ])
@@ -1182,8 +1187,9 @@ def test_va_for_angle():
11821187 assert alignment in ['center' , 'top' , 'baseline' ]
11831188
11841189
1190+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
11851191@image_comparison (baseline_images = ['xtick_rotation_mode' ],
1186- remove_text = False , extensions = ['png' ], style = 'mpl20' )
1192+ remove_text = False , extensions = ['png' ], style = 'mpl20' , tol = 0.3 )
11871193def test_xtick_rotation_mode ():
11881194 fig , ax = plt .subplots (figsize = (12 , 1 ))
11891195 ax .set_yticks ([])
@@ -1202,8 +1208,9 @@ def test_xtick_rotation_mode():
12021208 plt .subplots_adjust (left = 0.01 , right = 0.99 , top = .6 , bottom = .4 )
12031209
12041210
1211+ # TODO: tighten tolerance after baseline image is regenerated for text overhaul
12051212@image_comparison (baseline_images = ['ytick_rotation_mode' ],
1206- remove_text = False , extensions = ['png' ], style = 'mpl20' )
1213+ remove_text = False , extensions = ['png' ], style = 'mpl20' , tol = 0.3 )
12071214def test_ytick_rotation_mode ():
12081215 fig , ax = plt .subplots (figsize = (1 , 12 ))
12091216 ax .set_xticks ([])
0 commit comments