Skip to content

Commit 114ba67

Browse files
Trottjasnell
authored andcommitted
tools: include exit code in test failures
Include the exit code in test failures. This will give us more information during the currently-puzzling failures that provide no information in CI such as: ``` 03:10:10 not ok 563 parallel/test-fs-truncate 03:10:10 --- 03:10:10 duration_ms: 1.119 03:10:10 severity: fail 03:10:10 stack: |- 03:10:10 ... ``` PR-URL: #19855 Reviewed-By: Sakthipriyan Vairamani <[email protected]> Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: Gibson Fahnestock <[email protected]> Reviewed-By: Rod Vagg <[email protected]>
1 parent 0a553d5 commit 114ba67

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tools/test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,7 @@ def HasRun(self, output):
284284
if output.UnexpectedOutput():
285285
status_line = 'not ok %i %s' % (self._done, command)
286286
self.severity = 'fail'
287-
self.traceback = output.output.stdout + output.output.stderr
287+
self.traceback = "exit code: " + output.output.exit_code + "\n" + output.output.stdout + output.output.stderr
288288

289289
if FLAKY in output.test.outcomes and self.flaky_tests_mode == DONTCARE:
290290
status_line = status_line + ' # TODO : Fix flaky test'

0 commit comments

Comments
 (0)