Skip to content

Commit 11e53cd

Browse files
TrottMylesBorins
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 4a795dd commit 11e53cd

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
@@ -285,7 +285,7 @@ def HasRun(self, output):
285285
if output.UnexpectedOutput():
286286
status_line = 'not ok %i %s' % (self._done, command)
287287
self.severity = 'fail'
288-
self.traceback = output.output.stdout + output.output.stderr
288+
self.traceback = "exit code: " + output.output.exit_code + "\n" + output.output.stdout + output.output.stderr
289289

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

0 commit comments

Comments
 (0)