fix(scum): gate plugin features by companion support

This commit is contained in:
npc0-hue
2026-07-29 11:28:19 +08:00
parent 63022baa18
commit 47738acfd6
8 changed files with 38 additions and 25 deletions
@@ -35,8 +35,8 @@ const plugin: GamePluginResponse = {
title: "文件与配置",
path: "/files-config",
bundleKey: "scum-server-plugin",
bundleVersion: "1.0.0",
bundleIntegritySha256: "sha256:8a4216107e1d7773d42a7e13b6466fd4fcf6e6bb2dc5f5af398fb7f4ea4f623b",
bundleVersion: "1.0.1",
bundleIntegritySha256: "sha256:8de5ec67248be72a6fa47df5e6f8c98e10092ade99e6fc066ceeba678b119c64",
permissions: ["server.game-client.read", "server.game-client.command", "server.logs.read"],
bridgeActions: ["server.instances.read", "logs.query"]
}],
@@ -79,7 +79,7 @@ describe("PluginPageHostPage", () => {
const html = renderToStaticMarkup(<PluginPageHostPage {...props()} initialPlugin={plugin} />);
expect(html).toContain("文件与配置");
expect(html).toContain("平台托管上下文");
expect(html).toContain("scum-server-plugin@1.0.0");
expect(html).toContain("scum-server-plugin@1.0.1");
expect(html).toContain("完整性");
expect(html).toContain("返回服务器");
expect(html).not.toMatch(/sessionToken|componentKey|hostPath|dsn|runSocket|credential/i);