@@ -183,9 +183,10 @@ def _run_test(self, test: TestCase,
183183 gen_trace_file .close ()
184184 os .remove (trace_path )
185185
186+ print_trace_path = gen_trace_file and self .config .keep_input
186187 run_str = self ._process_test_result (result , trace_path ,
187188 extension_descriptor_paths ,
188- trace_descriptor_path )
189+ trace_descriptor_path , print_trace_path )
189190 return test .name , run_str , result
190191
191192 def _process_test_result (
@@ -194,6 +195,7 @@ def _process_test_result(
194195 trace_path : str ,
195196 extension_descriptor_paths : List [str ],
196197 trace_descriptor_path : str ,
198+ print_trace_path : bool ,
197199 ) -> str :
198200 colors = ColorFormatter (self .config .no_colors )
199201
@@ -219,6 +221,7 @@ def write_cmdlines() -> str:
219221 return res
220222
221223 run_str = f"{ colors .yellow ('[ RUN ]' )} { result .test .name } \n "
224+ run_diagnostics = [f"trace_path: { trace_path } " ] if print_trace_path else []
222225 if result .exit_code != 0 or not result .passed :
223226 result .passed = False
224227 run_str += result .stderr
@@ -230,13 +233,15 @@ def write_cmdlines() -> str:
230233 else :
231234 run_str += write_cmdlines ()
232235
233- run_str += (f"{ colors .red ('[ FAILED ]' )} { result .test .name } \n " )
236+ run_str += (f"{ colors .red ('[ FAILED ]' )} { result .test .name } " )
234237 else :
235238 assert result .perf_result
236- run_str += (
237- f"{ colors .green ('[ OK ]' )} { result .test .name } "
238- f"(ingest: { result .perf_result .ingest_time_ns / 1000000 :.2f} ms "
239- f"query: { result .perf_result .real_time_ns / 1000000 :.2f} ms)\n " )
239+ run_str += f"{ colors .green ('[ OK ]' )} { result .test .name } "
240+ run_diagnostics .append (
241+ f"ingest: { result .perf_result .ingest_time_ns / 1000000 :.2f} ms" )
242+ run_diagnostics .append (
243+ f"query: { result .perf_result .real_time_ns / 1000000 :.2f} ms" )
244+ run_str += f" ({ ' ' .join (run_diagnostics )} )\n " if run_diagnostics else "\n "
240245 return run_str
241246
242247 def _get_build_config (self ) -> Set [str ]:
0 commit comments