Skip to content

Commit 1945a98

Browse files
committed
test_runner: undo TypeError
1 parent 8b9dd96 commit 1945a98

1 file changed

Lines changed: 1 addition & 2 deletions

File tree

  • lib/internal/test_runner/reporter

lib/internal/test_runner/reporter/junit.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,8 +103,7 @@ module.exports = async function* junitReporter(source) {
103103
if (currentSuite?.nesting === event.data.nesting) {
104104
currentSuite = currentSuite.parent;
105105
}
106-
const duration = event.data.details?.duration_ms ?? 0;
107-
currentTest.attrs.time = NumberPrototypeToFixed(duration / 1000, 6);
106+
currentTest.attrs.time = NumberPrototypeToFixed(event.data.details.duration_ms / 1000, 6);
108107
const nonCommentChildren = ArrayPrototypeFilter(currentTest.children, (c) => c.comment == null);
109108
if (nonCommentChildren.length > 0) {
110109
currentTest.tag = 'testsuite';

0 commit comments

Comments
 (0)