summaryrefslogtreecommitdiff
path: root/packages/core/src/tools/glob.test.ts
diff options
context:
space:
mode:
authorTommaso Sciortino <[email protected]>2025-07-07 23:48:44 -0700
committerGitHub <[email protected]>2025-07-08 06:48:44 +0000
commit4dab31f1c8f0f4025c5d6a81c1b64f711e066756 (patch)
tree3db882e191862e4c24e5653167a756145b567759 /packages/core/src/tools/glob.test.ts
parent137ffec3f6fe035b7edcb478e6c44e66fa593839 (diff)
Improve Function Call argument validation and typing (#2881)
Co-authored-by: N. Taylor Mullen <[email protected]>
Diffstat (limited to 'packages/core/src/tools/glob.test.ts')
-rw-r--r--packages/core/src/tools/glob.test.ts12
1 files changed, 6 insertions, 6 deletions
diff --git a/packages/core/src/tools/glob.test.ts b/packages/core/src/tools/glob.test.ts
index a4bc99a9..acda3729 100644
--- a/packages/core/src/tools/glob.test.ts
+++ b/packages/core/src/tools/glob.test.ts
@@ -181,8 +181,8 @@ describe('GlobTool', () => {
// Need to correctly define this as an object without pattern
const params = { path: '.' };
// @ts-expect-error - We're intentionally creating invalid params for testing
- expect(globTool.validateToolParams(params)).toContain(
- 'Parameters failed schema validation',
+ expect(globTool.validateToolParams(params)).toBe(
+ `params must have required property 'pattern'`,
);
});
@@ -206,8 +206,8 @@ describe('GlobTool', () => {
path: 123,
};
// @ts-expect-error - We're intentionally creating invalid params for testing
- expect(globTool.validateToolParams(params)).toContain(
- 'Parameters failed schema validation',
+ expect(globTool.validateToolParams(params)).toBe(
+ 'params/path must be string',
);
});
@@ -217,8 +217,8 @@ describe('GlobTool', () => {
case_sensitive: 'true',
};
// @ts-expect-error - We're intentionally creating invalid params for testing
- expect(globTool.validateToolParams(params)).toContain(
- 'Parameters failed schema validation',
+ expect(globTool.validateToolParams(params)).toBe(
+ 'params/case_sensitive must be boolean',
);
});