Skip to content

Commit c5fc6fd

Browse files
author
Shailesh Pachbhai
committed
feat: fix the test build errors
1 parent 58242ff commit c5fc6fd

File tree

3 files changed

+12
-15
lines changed

3 files changed

+12
-15
lines changed

src/commands/omnistudio/migration/OmnistudioRelatedObjectMigrationFacade.ts

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,15 @@ export default class OmnistudioRelatedObjectMigrationFacade {
3535
this.allversions = allversions;
3636
this.org = org;
3737
}
38+
public static intializeProject(projectPath?: string): string {
39+
if (projectPath) {
40+
sfProject.create(defaultProjectName, projectPath);
41+
return projectPath + '/' + defaultProjectName;
42+
} else {
43+
sfProject.create(defaultProjectName);
44+
return process.cwd() + '/' + defaultProjectName;
45+
}
46+
}
3847
public migrateAll(migrationResult: MigratedObject[], relatedObjects: string[]): any {
3948
// Start the debug timer
4049
DebugTimer.getInstance().start();
@@ -91,14 +100,4 @@ export default class OmnistudioRelatedObjectMigrationFacade {
91100
// Return an instance of ApexClassMigrationTool when implemented
92101
return new ApexMigration(projectPath, this.namespace, this.org);
93102
}
94-
95-
public static intializeProject(projectPath?: string): string {
96-
if (projectPath) {
97-
sfProject.create(defaultProjectName, projectPath);
98-
return projectPath + '/' + defaultProjectName;
99-
} else {
100-
sfProject.create(defaultProjectName);
101-
return process.cwd() + '/' + defaultProjectName;
102-
}
103-
}
104103
}

src/utils/lwcparser/fileutils/FileDiffUtil.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
/* eslint-disable @typescript-eslint/no-unsafe-call */
22
/* eslint-disable @typescript-eslint/no-unsafe-assignment */
33
import { createPatch } from 'diff';
4-
import * as chalk from 'chalk';
4+
import chalk from 'chalk';
55

66
export class FileDiffUtil {
77
public getFileDiff(originalFileContent: string, modifiedFileContent: string): string {

tsconfig.json

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,8 @@
55
"outDir": "lib",
66
"rootDir": "./src",
77
"esModuleInterop": true,
8-
"types": ["node"],
9-
"skipLibCheck": true,
10-
"module": "ESNext", // Or "ES6" depending on setup
11-
"target": "ESNext"
8+
"types": ["node", "mocha"],
9+
"skipLibCheck": true
1210
},
1311
"include": ["./src/**/*.ts"]
1412
}

0 commit comments

Comments
 (0)