Added a null juggle check

This commit is contained in:
Pierre-Luc Champigny 2022-09-08 13:14:54 -04:00 committed by GitHub
parent 0d9714ddc7
commit dfee6fb104
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -34,7 +34,7 @@ export class JestJunitParser implements TestParser {
private getTestRunResult(path: string, junit: JunitReport): TestRunResult {
const suites =
junit.testsuites.testsuite === undefined
junit.testsuites?.testsuite == null
? []
: junit.testsuites.testsuite.map(ts => {
const name = ts.$.name.trim()