MCPcopy Create free account
hub / github.com/anus-dev/ANUS / createToolCallErrorMessage

Function createToolCallErrorMessage

integration-tests/test-helper.ts:26–39  ·  view source on GitHub ↗
(
  expectedTools: string | string[],
  foundTools: string[],
  result: string,
)

Source from the content-addressed store, hash-verified

24
25// Helper to create detailed error messages
26export function createToolCallErrorMessage(
27 expectedTools: string | string[],
28 foundTools: string[],
29 result: string,
30) {
31 const expectedStr = Array.isArray(expectedTools)
32 ? expectedTools.join(' or ')
33 : expectedTools;
34 return (
35 `Expected to find ${expectedStr} tool call(s). ` +
36 `Found: ${foundTools.length > 0 ? foundTools.join(', ') : 'none'}. ` +
37 `Output preview: ${result ? result.substring(0, 200) + '...' : 'no output'}`
38 );
39}
40
41// Helper to print debug information when tests fail
42export function printDebugInfo(

Callers 1

write_file.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected