mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-19 09:33:53 +00:00
Session-Level Conversation History Management (#1113)
This commit is contained in:
@@ -144,30 +144,6 @@ describe('ReadFileTool', () => {
|
||||
).toBe(path.join('sub', 'dir', 'file.txt'));
|
||||
});
|
||||
|
||||
it('should return shortened path when file path is deep', () => {
|
||||
const deepPath = path.join(
|
||||
tempRootDir,
|
||||
'very',
|
||||
'deep',
|
||||
'directory',
|
||||
'structure',
|
||||
'that',
|
||||
'exceeds',
|
||||
'the',
|
||||
'normal',
|
||||
'limit',
|
||||
'file.txt',
|
||||
);
|
||||
const params: ReadFileToolParams = { absolute_path: deepPath };
|
||||
const invocation = tool.build(params);
|
||||
expect(typeof invocation).not.toBe('string');
|
||||
const desc = (
|
||||
invocation as ToolInvocation<ReadFileToolParams, ToolResult>
|
||||
).getDescription();
|
||||
expect(desc).toContain('...');
|
||||
expect(desc).toContain('file.txt');
|
||||
});
|
||||
|
||||
it('should handle non-normalized file paths correctly', () => {
|
||||
const subDir = path.join(tempRootDir, 'sub', 'dir');
|
||||
const params: ReadFileToolParams = {
|
||||
|
||||
Reference in New Issue
Block a user