Skip to content

Commit 17ee79a

Browse files
fix(e2e): add type guard for appName to resolve TypeScript error
Add explicit type guard after expect(appName).toBeDefined() to narrow the type from string | undefined to string, resolving TypeScript errors at lines 452 and 457. Co-authored-by: Lars Gyrup Brink Nielsen <[email protected]>
1 parent 460c588 commit 17ee79a

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

packages/workspace-e2e/src/workspace.suite.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -443,6 +443,7 @@ export function useCalculator() {
443443
const workspaceName = sharedWorkspace.name;
444444

445445
expect(appName).toBeDefined();
446+
if (!appName) return;
446447

447448
// Add helper.ts to app with exported function
448449
const helperContent = `export function formatMessage(message: string): string {

0 commit comments

Comments
 (0)