@@ -51,9 +51,8 @@ function testCase(name, fn) {
5151}
5252
5353function test ( name , value , ignoreResult , prettyFormatOpts ) {
54- const formatted = testCase (
55- 'prettyFormat() ' ,
56- ( ) => prettyFormat ( value , prettyFormatOpts )
54+ const formatted = testCase ( 'prettyFormat() ' , ( ) =>
55+ prettyFormat ( value , prettyFormatOpts ) ,
5756 ) ;
5857
5958 const inspected = testCase ( 'util.inspect() ' , ( ) => {
@@ -75,7 +74,7 @@ function test(name, value, ignoreResult, prettyFormatOpts) {
7574
7675 results . forEach ( ( item , index ) => {
7776 item . isWinner = index === 0 ;
78- item . isLoser = index === results . length - 1 ;
77+ item . isLoser = index === results . length - 1 ;
7978 } ) ;
8079
8180 function log ( current ) {
@@ -86,8 +85,11 @@ function test(name, value, ignoreResult, prettyFormatOpts) {
8685 }
8786 if ( current . total ) {
8887 message +=
89- ' - ' + ( current . total / NANOSECONDS ) + 's total (' +
90- TIMES_TO_RUN + ' runs)' ;
88+ ' - ' +
89+ current . total / NANOSECONDS +
90+ 's total (' +
91+ TIMES_TO_RUN +
92+ ' runs)' ;
9193 }
9294 if ( current . error ) {
9395 message += ' - Error: ' + current . error . message ;
@@ -103,11 +105,11 @@ function test(name, value, ignoreResult, prettyFormatOpts) {
103105 message = chalk . dim ( message ) ;
104106 }
105107
106- const diff = ( current . time - winner . time ) ;
108+ const diff = current . time - winner . time ;
107109
108- if ( diff > ( winner . time * 0.85 ) ) {
110+ if ( diff > winner . time * 0.85 ) {
109111 message = chalk . bgRed . black ( message ) ;
110- } else if ( diff > ( winner . time * 0.65 ) ) {
112+ } else if ( diff > winner . time * 0.65 ) {
111113 message = chalk . bgYellow . black ( message ) ;
112114 } else if ( ! current . error ) {
113115 message = chalk . bgGreen . black ( message ) ;
@@ -166,7 +168,7 @@ objectWithPropsAndSymbols[Symbol('symbol2')] = 'value3';
166168test ( 'an object with properties and symbols' , objectWithPropsAndSymbols ) ;
167169test ( 'an object with sorted properties' , { a : 2 , b : 1 } ) ;
168170test ( 'regular expressions from constructors' , new RegExp ( 'regexp' ) ) ;
169- test ( 'regular expressions from literals' , / r e g e x p / ig ) ;
171+ test ( 'regular expressions from literals' , / r e g e x p / gi ) ;
170172test ( 'an empty set' , new Set ( ) ) ;
171173const setWithValues = new Set ( ) ;
172174setWithValues . add ( 'value1' ) ;
@@ -199,11 +201,11 @@ const element = React.createElement(
199201 { onClick : ( ) => { } , prop : { a : 1 , b : 2 } } ,
200202 React . createElement ( 'div' , { prop : { a : 1 , b : 2 } } ) ,
201203 React . createElement ( 'div' ) ,
202- React . createElement ( 'div' , { prop : { a : 1 , b : 2 } } ,
203- React . createElement ( 'div' , null ,
204- React . createElement ( 'div' )
205- )
206- )
204+ React . createElement (
205+ 'div' ,
206+ { prop : { a : 1 , b : 2 } } ,
207+ React . createElement ( 'div' , null , React . createElement ( 'div' ) ) ,
208+ ) ,
207209) ;
208210
209211test ( 'react' , ReactTestRenderer . create ( element ) . toJSON ( ) , false , {
0 commit comments