mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-01-31 06:42:03 +00:00
fix: use browser history in web mode for proper URL routing
The router was using memory history with initial entry "/" which caused all routes to render the index component regardless of the browser URL. Changes: - Use browser history when not in Electron (for e2e tests and dev) - Use memory history only in Electron environment - Update test utilities to use persist version 2 to match app store This fixes e2e tests that navigate directly to /board, /context, /spec 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -333,7 +333,7 @@ export async function setupProjectWithPath(page: Page, projectPath: string): Pro
|
||||
},
|
||||
worktreesByProject: {},
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
|
||||
localStorage.setItem("automaker-storage", JSON.stringify(mockState));
|
||||
@@ -346,7 +346,7 @@ export async function setupProjectWithPath(page: Page, projectPath: string): Pro
|
||||
currentStep: "complete",
|
||||
skipClaudeSetup: false,
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
localStorage.setItem("automaker-setup", JSON.stringify(setupState));
|
||||
}, projectPath);
|
||||
@@ -381,7 +381,7 @@ export async function setupProjectWithPathNoWorktrees(page: Page, projectPath: s
|
||||
currentWorktreeByProject: {},
|
||||
worktreesByProject: {},
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
|
||||
localStorage.setItem("automaker-storage", JSON.stringify(mockState));
|
||||
@@ -394,7 +394,7 @@ export async function setupProjectWithPathNoWorktrees(page: Page, projectPath: s
|
||||
currentStep: "complete",
|
||||
skipClaudeSetup: false,
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
localStorage.setItem("automaker-setup", JSON.stringify(setupState));
|
||||
}, projectPath);
|
||||
@@ -433,7 +433,7 @@ export async function setupProjectWithStaleWorktree(page: Page, projectPath: str
|
||||
},
|
||||
worktreesByProject: {},
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
|
||||
localStorage.setItem("automaker-storage", JSON.stringify(mockState));
|
||||
@@ -446,7 +446,7 @@ export async function setupProjectWithStaleWorktree(page: Page, projectPath: str
|
||||
currentStep: "complete",
|
||||
skipClaudeSetup: false,
|
||||
},
|
||||
version: 0,
|
||||
version: 2, // Must match app-store.ts persist version
|
||||
};
|
||||
localStorage.setItem("automaker-setup", JSON.stringify(setupState));
|
||||
}, projectPath);
|
||||
|
||||
Reference in New Issue
Block a user