diff --git a/js-karma/src/js_reporter/karma-intellij/lib/intellijReporter.js b/js-karma/src/js_reporter/karma-intellij/lib/intellijReporter.js index 078ef1ad8d4..80eb5821408 100644 --- a/js-karma/src/js_reporter/karma-intellij/lib/intellijReporter.js +++ b/js-karma/src/js_reporter/karma-intellij/lib/intellijReporter.js @@ -214,6 +214,11 @@ function IntellijReporter(config, fileList, formatError, globalEmitter, injector if (specName == null) { return; } + if (tree == null) { + // workaround for https://github.com/karma-runner/karma/issues/1292 + process.stdout.write('Test "' + suiteNames.concat(specName).join('.') + '" skipped\n'); + return; + } var browserNode = getOrCreateBrowserNode(tree, browser); if (typeof browserNode.checkedForTotalTestCount === 'undefined') { browserNode.checkedForTotalTestCount = true;