File tree Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Expand file tree Collapse file tree 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -9,8 +9,8 @@ function getIcon(passed: boolean) {
99function * formatTestCase ( testCase : TestCase ) {
1010 const passed = testCase . ok ( ) ;
1111 const diagnostics = testCase . diagnostic ( ) ;
12- const durationStr = ! Number . isNaN ( diagnostics ?. duration )
13- ? ` <code>${ diagnostics ! . duration . toFixed ( 0 ) } ms</code>`
12+ const durationStr = diagnostics && testCase . result ( ) . state !== 'skipped'
13+ ? ` <code>${ diagnostics . duration . toFixed ( 0 ) } ms</code>`
1414 : '' ;
1515
1616 yield `${ getIcon ( passed ) } ${ testCase . name } ${ durationStr } ` ;
@@ -26,7 +26,7 @@ function* formatTestSuite(suite: TestSuite): Generator<string> {
2626 const suiteName = suite . name ;
2727 const passed = suite . ok ( ) ;
2828
29- yield `${ passed ? '✅' : '❌' } ${ suiteName } <ul>` ;
29+ yield `${ getIcon ( passed ) } ${ suiteName } <ul>` ;
3030
3131 for ( const child of suite . children ) {
3232 if ( child . type === 'suite' ) {
You can’t perform that action at this time.
0 commit comments