MCPcopy Create free account
hub / github.com/GCWing/BitFun / createSession

Function createSession

src/web-ui/src/flow_chat/utils/sessionOrdering.test.ts:12–37  ·  view source on GitHub ↗
(overrides: Partial<Session> = {})

Source from the content-addressed store, hash-verified

10} from './sessionOrdering';
11
12function createSession(overrides: Partial<Session> = {}): Session {
13 return {
14 sessionId: 'session-1',
15 title: 'Session Title',
16 titleStatus: 'generated',
17 dialogTurns: [],
18 status: 'idle',
19 config: {
20 modelName: 'gpt-test',
21 agentType: 'agentic',
22 },
23 createdAt: 1000,
24 lastActiveAt: undefined,
25 lastFinishedAt: undefined,
26 error: null,
27 todos: [],
28 maxContextTokens: 128128,
29 mode: 'agentic',
30 workspacePath: '/workspace',
31 parentSessionId: undefined,
32 sessionKind: 'normal',
33 btwThreads: [],
34 btwOrigin: undefined,
35 ...overrides,
36 };
37}
38
39describe('sessionOrdering', () => {
40 it('uses lastFinishedAt when available', () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected