mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-04-22 02:54:31 -07:00
feat(core): Annotate remaining error paths in tools with type. (#6699)
This commit is contained in:
@@ -16,6 +16,7 @@ import * as fs from 'fs/promises';
|
||||
import * as path from 'path';
|
||||
import * as os from 'os';
|
||||
import { ToolConfirmationOutcome } from './tools.js';
|
||||
import { ToolErrorType } from './tool-error.js';
|
||||
|
||||
// Mock dependencies
|
||||
vi.mock(import('fs/promises'), async (importOriginal) => {
|
||||
@@ -287,6 +288,9 @@ describe('MemoryTool', () => {
|
||||
expect(result.returnDisplay).toBe(
|
||||
`Error saving memory: ${underlyingError.message}`,
|
||||
);
|
||||
expect(result.error?.type).toBe(
|
||||
ToolErrorType.MEMORY_TOOL_EXECUTION_ERROR,
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user