feat(acp): add session resume support (#18043)

Co-authored-by: Jack Wotherspoon <jackwoth@google.com>
This commit is contained in:
Bryan Morgan
2026-02-01 14:16:57 -05:00
committed by GitHub
parent cb4f0c6fa4
commit 7d36cc004f
6 changed files with 651 additions and 213 deletions

View File

@@ -129,7 +129,7 @@ describe('GeminiAgent', () => {
expect(response.protocolVersion).toBe(acp.PROTOCOL_VERSION);
expect(response.authMethods).toHaveLength(3);
expect(response.agentCapabilities?.loadSession).toBe(false);
expect(response.agentCapabilities?.loadSession).toBe(true);
});
it('should authenticate correctly', async () => {
@@ -273,6 +273,7 @@ describe('Session', () => {
mockChat = {
sendMessageStream: vi.fn(),
addHistory: vi.fn(),
recordCompletedToolCalls: vi.fn(),
} as unknown as Mocked<GeminiChat>;
mockTool = {
kind: 'native',
@@ -293,6 +294,7 @@ describe('Session', () => {
} as unknown as Mocked<MessageBus>;
mockConfig = {
getModel: vi.fn().mockReturnValue('gemini-pro'),
getActiveModel: vi.fn().mockReturnValue('gemini-pro'),
getPreviewFeatures: vi.fn().mockReturnValue({}),
getToolRegistry: vi.fn().mockReturnValue(mockToolRegistry),
getFileService: vi.fn().mockReturnValue({