Merge tag 'v0.1.15' into feature/yiheng/sync-gemini-cli-0.1.15

This commit is contained in:
奕桁
2025-08-01 23:06:11 +08:00
340 changed files with 36528 additions and 22931 deletions

View File

@@ -23,7 +23,8 @@ import {
ToolCallResponseInfo,
ToolCall, // Import from core
Status as ToolCallStatusType,
ApprovalMode, // Import from core
ApprovalMode,
Icon,
} from '@qwen-code/qwen-code-core';
import {
HistoryItemWithoutId,
@@ -56,6 +57,8 @@ const mockTool: Tool = {
name: 'mockTool',
displayName: 'Mock Tool',
description: 'A mock tool for testing',
icon: Icon.Hammer,
toolLocations: vi.fn(),
isOutputMarkdown: false,
canUpdateOutput: false,
schema: {},
@@ -85,6 +88,8 @@ const mockToolRequiresConfirmation: Tool = {
onConfirm: mockOnUserConfirmForToolConfirmation,
fileName: 'mockToolRequiresConfirmation.ts',
fileDiff: 'Mock tool requires confirmation',
originalContent: 'Original content',
newContent: 'New content',
}),
),
};
@@ -336,7 +341,7 @@ describe('useReactToolScheduler', () => {
const schedule = result.current[1];
const request: ToolCallRequestInfo = {
callId: 'call1',
name: 'nonExistentTool',
name: 'nonexistentTool',
args: {},
};
@@ -356,7 +361,7 @@ describe('useReactToolScheduler', () => {
request,
response: expect.objectContaining({
error: expect.objectContaining({
message: 'Tool "nonExistentTool" not found in registry.',
message: 'Tool "nonexistentTool" not found in registry.',
}),
}),
}),
@@ -807,6 +812,8 @@ describe('mapToDisplay', () => {
isOutputMarkdown: false,
canUpdateOutput: false,
schema: {},
icon: Icon.Hammer,
toolLocations: vi.fn(),
validateToolParams: vi.fn(),
execute: vi.fn(),
shouldConfirmExecute: vi.fn(),
@@ -885,6 +892,8 @@ describe('mapToDisplay', () => {
toolDisplayName: 'Test Tool Display',
fileName: 'test.ts',
fileDiff: 'Test diff',
originalContent: 'Original content',
newContent: 'New content',
} as ToolCallConfirmationDetails,
},
expectedStatus: ToolCallStatus.Confirming,