Files
agent-desktop/console/src/utils/sessionRoute.test.ts
T
Pine 9b30f681c6 feat: 智能体控制台前端(console)
- React+antd+zustand,注册表驱动路由/菜单/权限
- Tauri 桌面壳、后端托管 SPA、跨标签页消息队列
2026-08-23 22:43:18 +08:00

15 lines
498 B
TypeScript

import { describe, expect, it } from "vitest";
import { buildSessionPath, getSessionIdFromPath } from "./sessionRoute";
describe("session mode routes", () => {
it("preserves the session id across coding and chat routes", () => {
const sessionId = getSessionIdFromPath("/coding/chat-123");
expect(buildSessionPath("chat", sessionId)).toBe("/chat/chat-123");
expect(
buildSessionPath("coding", getSessionIdFromPath("/chat/chat-123")),
).toBe("/coding/chat-123");
});
});