11import { ResultStatus , FailedResult } from "../types" ;
2- import { convertConfig , ConvertConfigDependencies } from "./convertConfig " ;
2+ import { convertLintConfig , ConvertLintConfigDependencies } from "./convertLintConfig " ;
33
44const stubSettings = {
55 config : "./eslintrc.js" ,
66} ;
77
88const createStubDependencies = (
9- overrides : Partial < ConvertConfigDependencies > = { } ,
10- ) : ConvertConfigDependencies => ( {
9+ overrides : Partial < ConvertLintConfigDependencies > = { } ,
10+ ) : ConvertLintConfigDependencies => ( {
1111 convertComments : jest . fn ( ) ,
1212 convertRules : jest . fn ( ) ,
1313 findOriginalConfigurations : jest . fn ( ) . mockResolvedValue ( {
@@ -40,7 +40,7 @@ const createStubOriginalConfigurationsData = () => ({
4040 } ,
4141} ) ;
4242
43- describe ( "convertConfig " , ( ) => {
43+ describe ( "convertLintConfig " , ( ) => {
4444 it ( "returns the failure result when finding the original configurations fails" , async ( ) => {
4545 // Arrange
4646 const findError : FailedResult = {
@@ -52,7 +52,7 @@ describe("convertConfig", () => {
5252 } ) ;
5353
5454 // Act
55- const result = await convertConfig ( dependencies , stubSettings ) ;
55+ const result = await convertLintConfig ( dependencies , stubSettings ) ;
5656
5757 // Assert
5858 expect ( result ) . toEqual ( findError ) ;
@@ -66,7 +66,7 @@ describe("convertConfig", () => {
6666 } ) ;
6767
6868 // Act
69- const result = await convertConfig ( dependencies , stubSettings ) ;
69+ const result = await convertLintConfig ( dependencies , stubSettings ) ;
7070
7171 // Assert
7272 expect ( result ) . toEqual ( {
@@ -86,7 +86,7 @@ describe("convertConfig", () => {
8686 } ) ;
8787
8888 // Act
89- const result = await convertConfig ( dependencies , stubSettings ) ;
89+ const result = await convertLintConfig ( dependencies , stubSettings ) ;
9090
9191 // Assert
9292 expect ( result ) . toEqual ( convertCommentsResult ) ;
@@ -102,7 +102,7 @@ describe("convertConfig", () => {
102102 } ) ;
103103
104104 // Act
105- const result = await convertConfig ( dependencies , stubSettings ) ;
105+ const result = await convertLintConfig ( dependencies , stubSettings ) ;
106106
107107 // Assert
108108 expect ( result ) . toEqual ( convertCommentsResult ) ;
0 commit comments