Skip to content

Commit

Permalink
[CI] Make cypress reporting more resilient (elastic#184397)
Browse files Browse the repository at this point in the history
## Summary
cypress reporter will occasionally get an empty result object - it draws
attention from other error messages in the stream, and allows misleading
conclusions

let's not fail reporting because of that, and hope that the real error
will also surface.


See:
https://buildkite.com/elastic/kibana-pull-request/builds/212655#018fc04b-e385-4760-87db-41b65f86fb40

---------

Co-authored-by: Patryk Kopycinski <[email protected]>
  • Loading branch information
delanni and patrykkopycinski authored May 29, 2024
1 parent d39739e commit 8bbba60
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -493,10 +493,15 @@ ${JSON.stringify(cyCustomEnv, null, 2)}
(runResult) => !failedSpecFilePaths.includes(runResult.spec.absolute)
)
),
...retryResults,
..._.filter(retryResults, (retryResult) => !!retryResult),
] as CypressCommandLine.CypressRunResult[];

renderSummaryTable(finalResults);
try {
renderSummaryTable(finalResults);
} catch (e) {
log.error('Failed to render summary table');
log.error(e);
}

const hasFailedTests = (
runResults: Array<
Expand Down

0 comments on commit 8bbba60

Please sign in to comment.