File tree Expand file tree Collapse file tree 1 file changed +12
-1
lines changed
Expand file tree Collapse file tree 1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -125,6 +125,17 @@ def test_chart_titles(file):
125125 check_plots (cell .source )
126126
127127
128+ def is_plotly_output (output ):
129+ return "application/vnd.plotly.v1+json" in output .data
130+
131+
132+ def is_text_or_table_output (output ):
133+ return output .output_type in [
134+ "display_data" ,
135+ "execute_result" ,
136+ ] and not is_plotly_output (output )
137+
138+
128139def num_lines (output ):
129140 html = output .data .get ("text/html" )
130141 if html :
@@ -142,7 +153,7 @@ def test_long_outputs_scrolled(file):
142153 for cell in notebook .cells :
143154 if is_python (cell ):
144155 for output in cell .outputs :
145- if output . output_type in [ "display_data" , "execute_result" ] :
156+ if is_text_or_table_output ( output ) :
146157 num_rows = num_lines (output )
147158 if num_rows > 30 :
148159 # if not set, the notebook will automatically scroll
You can’t perform that action at this time.
0 commit comments