



























@@ -96,6 +96,30 @@ function createManifestRegistryFixture() {
9696providers: ["demo-provider"],
9797cliBackends: ["demo-cli"],
9898},
99+{
100+id: "anthropic",
101+channels: [],
102+origin: "bundled",
103+enabledByDefault: true,
104+providers: ["anthropic"],
105+cliBackends: ["claude-cli"],
106+},
107+{
108+id: "openai",
109+channels: [],
110+origin: "bundled",
111+enabledByDefault: true,
112+providers: ["openai", "openai-codex"],
113+cliBackends: ["codex-cli"],
114+},
115+{
116+id: "google",
117+channels: [],
118+origin: "bundled",
119+enabledByDefault: true,
120+providers: ["google", "google-gemini-cli"],
121+cliBackends: ["google-gemini-cli"],
122+},
99123{
100124id: "codex",
101125channels: [],
@@ -672,6 +696,52 @@ describe("resolveGatewayStartupPluginIds", () => {
672696});
673697});
674698699+it("includes required CLI backend owner plugins when the default runtime is forced", () => {
700+expectStartupPluginIdsCase({
701+config: createStartupConfig({
702+agentRuntimeId: "demo-cli",
703+enabledPluginIds: ["demo-provider-plugin"],
704+}),
705+expected: ["demo-channel", "browser", "demo-provider-plugin"],
706+});
707+});
708+709+it.each([
710+["claude-cli", "anthropic"],
711+["codex-cli", "openai"],
712+["google-gemini-cli", "google"],
713+] as const)("includes the bundled %s CLI backend owner at startup", (runtime, pluginId) => {
714+expectStartupPluginIdsCase({
715+config: createStartupConfig({
716+agentRuntimeId: runtime,
717+}),
718+expected: ["demo-channel", "browser", pluginId],
719+});
720+});
721+722+it("does not include required CLI backend owner plugins when they are explicitly disabled", () => {
723+expectStartupPluginIdsCase({
724+config: {
725+agents: {
726+defaults: {
727+agentRuntime: {
728+id: "demo-cli",
729+fallback: "none",
730+},
731+},
732+},
733+plugins: {
734+entries: {
735+"demo-provider-plugin": {
736+enabled: false,
737+},
738+},
739+},
740+} as OpenClawConfig,
741+expected: ["demo-channel", "browser"],
742+});
743+});
744+675745it("does not include required agent harness owner plugins when they are explicitly disabled", () => {
676746expectStartupPluginIdsCase({
677747config: {
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。