MCPcopy Create free account
hub / github.com/tiann/hapi / makeLegacySession

Function makeLegacySession

hub/src/sync/syncEngineAutoMigrate.test.ts:38–55  ·  view source on GitHub ↗
(overrides: Partial<Session['metadata']> = {})

Source from the content-addressed store, hash-verified

36 let originalHapiHome: string | undefined
37
38 function makeLegacySession(overrides: Partial<Session['metadata']> = {}): Session {
39 return {
40 id: 'session-auto-migrate-test',
41 machineId: 'machine-x',
42 createdAt: 1000,
43 updatedAt: 1000,
44 active: false,
45 model: null,
46 metadata: {
47 path: '/tmp/proj',
48 host: 'localhost',
49 flavor: 'cursor',
50 cursorSessionId: 'cursor-uuid-123',
51 cursorSessionProtocol: 'stream-json',
52 ...overrides
53 }
54 } as unknown as Session
55 }
56
57 beforeEach(() => {
58 store = new Store(':memory:')

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected