Changeset View
Changeset View
Standalone View
Standalone View
src/unit/parser/ArcanistPhpunitTestResultParser.php
Context not available. | |||||
idx($trace, 'line')); | idx($trace, 'line')); | ||||
} | } | ||||
} else if ('error' == idx($event, 'status')) { | } else if ('error' == idx($event, 'status')) { | ||||
if (strpos(idx($event, 'message'), 'Skipped Test') !== false) { | if (@strpos(idx($event, 'message'), 'Skipped Test') !== false) { | ||||
$status = ArcanistUnitTestResult::RESULT_SKIP; | $status = ArcanistUnitTestResult::RESULT_SKIP; | ||||
$user_data .= idx($event, 'message'); | $user_data .= idx($event, 'message'); | ||||
} else if (strpos( | } else if (@strpos( | ||||
idx($event, 'message'), | idx($event, 'message'), | ||||
'Incomplete Test') !== false) { | 'Incomplete Test') !== false) { | ||||
$status = ArcanistUnitTestResult::RESULT_SKIP; | $status = ArcanistUnitTestResult::RESULT_SKIP; | ||||
Context not available. | |||||
// when the file wasn't actually part of the test. This filters out files | // when the file wasn't actually part of the test. This filters out files | ||||
// with no coverage which helps give more accurate overall results. | // with no coverage which helps give more accurate overall results. | ||||
if ($any_line_covered) { | if ($any_line_covered) { | ||||
$len = strlen($this->projectRoot.DIRECTORY_SEPARATOR); | $len = @strlen($this->projectRoot.DIRECTORY_SEPARATOR); | ||||
$class_path = substr($class_path, $len); | $class_path = @substr($class_path, $len); | ||||
$reports[$class_path] = $coverage; | $reports[$class_path] = $coverage; | ||||
} | } | ||||
} | } | ||||
Context not available. |
Content licensed under Creative Commons Attribution-ShareAlike 4.0 (CC-BY-SA) unless otherwise noted; code licensed under Apache 2.0 or other open source licenses. · CC BY-SA 4.0 · Apache 2.0