test(cli): import the MCP schema validator from source

CI runs vitest from the repo root, where @claude-flow/mcp is not
resolvable as a package, so the import failed and the file counted as a
new failure in the test ratchet.

Co-Authored-By: RuFlo <ruv@ruv.net>
This commit is contained in:
randRuFlo committed 2026-11-09 12:14:59 -05:00
1 parent 550691ab7c
commit ffb8cb6f90
1 file changed
+1 -1
@@ -141,7 +141,7 @@ describe('#4887 hooks_post-task identifiers', () => {
});
it(`${field} agrees with the runtime validator the HTTP transport applies`, async () => {
const { validateSchema } = await import('@claude-flow/mcp');
const { validateSchema } = await import('../../mcp/src/schema-validator.js');
const handlerAccepts = (v: string) => (field === 'agent' && v === '') || validateIdentifier(v, field).valid;
// validateSchema ignores `not`, so reserved names are left to the handler.
const reserved = new Set(['__proto__', 'constructor', 'prototype']);