test(examples): include task controls in CLI composition

This commit is contained in:
Tianyi Cui
2026-07-15 22:58:44 +08:00
parent cc7642ab66
commit fb7fa980b8

View File

@@ -89,7 +89,14 @@ describe('dsh-cli-demo app composition', () => {
ctx.tools.register({ name, description: name, parameters: {}, execute: async () => [] })
}
expect(JSON.stringify(await composePrefix(ctx))).toContain('- `cli-skill`: CLI...')
expect((await ctx.systemPrompt.assemble()).tools.map(tool => tool.name)).toEqual(['zulu', 'alpha', 'skill'])
expect((await ctx.systemPrompt.assemble()).tools.map(tool => tool.name)).toEqual([
'zulu',
'alpha',
'skill',
'task_kill',
'task_list',
'task_output',
])
})
it('exposes the Loader-safe namespace plugin shape and schema', () => {