@@ -12,14 +12,16 @@ function testRunner(options, runTest) {
1212
1313 let transform = require ( details . transformPath ) ;
1414
15- describe ( details . name , function ( ) {
15+ describe ( details . name , function ( ) {
1616 globby
1717 . sync ( '**/*.input.*' , {
1818 cwd : details . fixtureDir ,
1919 absolute : true ,
2020 } )
21- . map ( entry => entry . slice ( entry . indexOf ( '__testfixtures__' ) + '__testfixtures__' . length + 1 ) )
22- . forEach ( filename => {
21+ . map ( ( entry ) =>
22+ entry . slice ( entry . indexOf ( '__testfixtures__' ) + '__testfixtures__' . length + 1 )
23+ )
24+ . forEach ( ( filename ) => {
2325 let extension = path . extname ( filename ) ;
2426 let testName = filename . replace ( `.input${ extension } ` , '' ) ;
2527 let testInputPath = path . join ( details . fixtureDir , `${ testName } ${ extension } ` ) ;
@@ -28,24 +30,24 @@ function testRunner(options, runTest) {
2830 let optionsPath = path . join ( details . fixtureDir , `${ testName } .options.json` ) ;
2931 let options = fs . pathExistsSync ( optionsPath ) ? fs . readFileSync ( optionsPath ) : '{}' ;
3032
31- describe ( testName , function ( ) {
32- beforeEach ( function ( ) {
33+ describe ( testName , function ( ) {
34+ beforeEach ( function ( ) {
3335 process . env . CODEMOD_CLI_ARGS = options ;
3436 } ) ;
3537
36- afterEach ( function ( ) {
38+ afterEach ( function ( ) {
3739 process . env . CODEMOD_CLI_ARGS = '' ;
3840 } ) ;
3941
40- it ( 'transforms correctly' , function ( ) {
42+ it ( 'transforms correctly' , function ( ) {
4143 runTest (
4244 transform ,
4345 { path : testInputPath , source : fs . readFileSync ( inputPath , 'utf8' ) } ,
4446 fs . readFileSync ( outputPath , 'utf8' )
4547 ) ;
4648 } ) ;
4749
48- it ( 'is idempotent' , function ( ) {
50+ it ( 'is idempotent' , function ( ) {
4951 runTest (
5052 transform ,
5153 { path : testInputPath , source : fs . readFileSync ( outputPath , 'utf8' ) } ,
0 commit comments