( initial?: Array<UIMessage> | null, )
| 20 | * methods via the returned object's `.mock*` helpers for async/error scenarios. |
| 21 | */ |
| 22 | export function createMockPersistence( |
| 23 | initial?: Array<UIMessage> | null, |
| 24 | ): ChatClientPersistence { |
| 25 | return { |
| 26 | getItem: vi.fn(() => initial), |
| 27 | setItem: vi.fn(), |
| 28 | removeItem: vi.fn(), |
| 29 | } |
| 30 | } |
| 31 | /** |
| 32 | * Options for creating a mock connection adapter |
| 33 | */ |
no outgoing calls
no test coverage detected