test(subagent): keep scoped fixture config explicit

This commit is contained in:
Dudu-0223
2026-08-27 12:00:02 +08:00
parent bf7020ade2
commit 1c0e46870c
2 changed files with 12 additions and 3 deletions
+1 -2
View File
@@ -696,8 +696,7 @@
"@deepseek-ai/dsh-llm-deepseek",
"@deepseek-ai/dsh-session-checkpoint-policy",
"@deepseek-ai/dsh-session-persistence-jsonl",
"@deepseek-ai/dsh-skill-filesystem",
"@deepseek-ai/dsh-tool-subagent"
"@deepseek-ai/dsh-skill-filesystem"
]
},
"packages/shell/tool-pwsh": {
@@ -14,6 +14,16 @@ export const inject = ['agents', 'subagentModelSelection']
*/
export function apply(ctx: Context, config: Config): void {
ctx.on('agent/created', ({ agent }) => {
agent.ctx.plugin(ToolSubagent, { ...config, modelSelectionSettings: true })
agent.ctx.plugin(ToolSubagent, {
provider: config.provider,
toolName: config.toolName,
modelSelectionSettings: true,
enableRunInBackground: config.enableRunInBackground,
backgroundMode: config.backgroundMode,
agentOptions: config.agentOptions,
persona: config.persona,
toolFilter: config.toolFilter,
maxDepth: config.maxDepth,
})
})
}