File tree Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Expand file tree Collapse file tree 2 files changed +18
-1
lines changed Original file line number Diff line number Diff line change @@ -129,4 +129,21 @@ describe("runCli", () => {
129129 expect ( status ) . toBe ( ResultStatus . Succeeded ) ;
130130 expectEqualWrites ( dependencies . logger . stdout . write , "✅ All is well! ✅" ) ;
131131 } ) ;
132+
133+ it ( "default output should be .eslintrc.js" , async ( ) => {
134+ let defaultConfig ;
135+ const dependencies = createStubRunCliDependencies ( {
136+ convertConfig : parsedArgs => {
137+ defaultConfig = parsedArgs . config ;
138+ return Promise . resolve ( {
139+ status : ResultStatus . Succeeded ,
140+ } ) ;
141+ } ,
142+ } ) ;
143+
144+ const status = await runCli ( dependencies , createStubArgv ( ) ) ;
145+
146+ expect ( status ) . toBe ( ResultStatus . Succeeded ) ;
147+ expect ( defaultConfig ) . toEqual ( "./.eslintrc.js" ) ;
148+ } ) ;
132149} ) ;
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ export const runCli = async (
2727 . option ( "-V --version" , "output the package version" ) ;
2828
2929 const parsedArgv = {
30- config : "./eslintrc.js" ,
30+ config : "./. eslintrc.js" ,
3131 ...( command . parse ( rawArgv ) as Partial < TSLintToESLintSettings > ) ,
3232 } ;
3333
You can’t perform that action at this time.
0 commit comments