Skip to content

Commit 6d6a6ca

Browse files
committed
chore: additional clean up
1 parent c08ca9f commit 6d6a6ca

File tree

3 files changed

+11
-11
lines changed

3 files changed

+11
-11
lines changed

packages/core/update/Update.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ export async function updateWorkspace(rootPath: string): Promise<boolean> {
119119
// For React and WebComponents projects without explicit workspaces,
120120
// check for common project patterns like projects/* in addition to src/
121121
workspaces.push(path.join(rootPath, "src"));
122-
122+
123123
// Check for projects/* pattern common in React demo/example repositories
124124
// Only check if projects directory exists to avoid unnecessary glob calls
125125
const projectsDir = path.join(rootPath, "projects");

spec/unit/packageManager-spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -479,35 +479,35 @@ describe("Unit - Package Manager", () => {
479479
// spyOn(require("module"), "_load").and.returnValue(mockRequire);
480480
spyOn(Util, "log");
481481
spyOn(App.container, "get").and.returnValue(mockFs);
482-
482+
483483
const createMockChild = (exitCode: number, stdoutData: string, stderrData: string) => {
484484
const mockChild = {
485485
stdout: { on: jasmine.createSpy() },
486486
stderr: { on: jasmine.createSpy() },
487487
on: jasmine.createSpy()
488488
};
489-
489+
490490
// Setup stdout data handler
491491
mockChild.stdout.on.and.callFake((event: string, handler: any) => {
492492
if (event === 'data') {
493493
setTimeout(() => handler(Buffer.from(stdoutData)), 10);
494494
}
495495
});
496-
496+
497497
// Setup stderr data handler
498498
mockChild.stderr.on.and.callFake((event: string, handler: any) => {
499499
if (event === 'data') {
500500
setTimeout(() => handler(Buffer.from(stderrData)), 10);
501501
}
502502
});
503-
503+
504504
// Setup close handler
505505
mockChild.on.and.callFake((event: string, handler: any) => {
506506
if (event === 'close') {
507507
setTimeout(() => handler(exitCode), 20);
508508
}
509509
});
510-
510+
511511
return mockChild;
512512
};
513513

spec/unit/update-spec.ts

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -804,7 +804,7 @@ export default function Home() {
804804
(fsSpy.directoryExists as jasmine.Spy).and.callFake((dirPath: string) => {
805805
return dirPath.includes("projects/charts") || dirPath.includes("projects") || dirPath.endsWith("/src");
806806
});
807-
807+
808808
// Mock glob to simulate finding workspace directories and files
809809
(fsSpy.glob as jasmine.Spy).and.callFake((dirPath: string, pattern: string) => {
810810
if (pattern === "projects/*") {
@@ -826,7 +826,7 @@ export default function Home() {
826826
}
827827
return [];
828828
});
829-
829+
830830
(fsSpy.readFile as jasmine.Spy).and.callFake((filePath: string) => {
831831
if (filePath.indexOf("package.json") < 0) {
832832
return;
@@ -842,7 +842,7 @@ export default function Home() {
842842
for (const fileEntry of mockFileArray) {
843843
expect((fsSpy.writeFile as jasmine.Spy)).toHaveBeenCalledWith(fileEntry.path, fileEntry.expected);
844844
}
845-
// Expect: 1 for projects/*, 1 for package.json files at root, 1 for logic files, 1 for style files, 1 for package.json in workspace, 1 for vite.config.ts
845+
// Expect: 1 for projects/*, 1 for package.json files at root, 1 for logic files, 1 for style files, 1 for package.json in workspace, 1 for vite.config.ts
846846
expect(fsSpy.glob).toHaveBeenCalledTimes(7);
847847
});
848848

@@ -996,7 +996,7 @@ export const GridComponent = () => {
996996
(fsSpy.directoryExists as jasmine.Spy).and.callFake((dirPath: string) => {
997997
return dirPath === "projects" || dirPath.endsWith("/projects") || dirPath.includes("projects/") || dirPath === "src" || dirPath.endsWith("/src");
998998
});
999-
999+
10001000
// Mock glob to simulate finding projects directories and files
10011001
(fsSpy.glob as jasmine.Spy).and.callFake((dirPath: string, pattern: string) => {
10021002
if (pattern === "package.json") {
@@ -1021,7 +1021,7 @@ export const GridComponent = () => {
10211021
}
10221022
return [];
10231023
});
1024-
1024+
10251025
(fsSpy.readFile as jasmine.Spy).and.callFake((filePath: string) => {
10261026
if (filePath.indexOf("package.json") > -1) {
10271027
return mockFileArray.find(entry => entry.path === "package.json").content;

0 commit comments

Comments
 (0)