File tree 2 files changed +6
-2
lines changed
2 files changed +6
-2
lines changed Original file line number Diff line number Diff line change @@ -91,6 +91,8 @@ var createReporter = function createReporter() {
91
91
var compared = ( 0 , _diff . diffJson ) ( diag . actual , diag . expected ) . map ( writeDiff ) . join ( '' ) ;
92
92
93
93
println ( compared , 4 ) ;
94
+ } else if ( diag . expected === 'undefined' && diag . actual === 'undefined' ) {
95
+ ;
94
96
} else if ( typeof diag . expected === 'string' ) {
95
97
var compared = ( 0 , _diff . diffWords ) ( diag . actual , diag . expected ) . map ( writeDiff ) . join ( '' ) ;
96
98
@@ -110,7 +112,7 @@ var createReporter = function createReporter() {
110
112
if ( result . ok ) {
111
113
println ( _chalk2 [ 'default' ] . green ( 'All of ' + result . count + ' tests passed!' ) ) ;
112
114
} else {
113
- println ( _chalk2 [ 'default' ] . red ( result . fail + ' of ' + result . count + ' tests failed.' ) ) ;
115
+ println ( _chalk2 [ 'default' ] . red ( ( result . fail || 0 ) + ' of ' + result . count + ' tests failed.' ) ) ;
114
116
stream . isFailed = true ;
115
117
}
116
118
Original file line number Diff line number Diff line change @@ -60,6 +60,8 @@ const createReporter = () => {
60
60
. join ( '' ) ;
61
61
62
62
println ( compared , 4 ) ;
63
+ } else if ( diag . expected === 'undefined' && diag . actual === 'undefined' ) {
64
+ ;
63
65
} else if ( typeof diag . expected === 'string' ) {
64
66
const compared = diffWords ( diag . actual , diag . expected )
65
67
. map ( writeDiff )
@@ -89,7 +91,7 @@ const createReporter = () => {
89
91
if ( result . ok ) {
90
92
println ( chalk . green ( `All of ${ result . count } tests passed!` ) ) ;
91
93
} else {
92
- println ( chalk . red ( `${ result . fail } of ${ result . count } tests failed.` ) ) ;
94
+ println ( chalk . red ( `${ result . fail || 0 } of ${ result . count } tests failed.` ) ) ;
93
95
stream . isFailed = true ;
94
96
}
95
97
You can’t perform that action at this time.
0 commit comments