perf(plugins): reuse persisted registry fallback read · openclaw/openclaw@9eb071c
vincentkoc
·
2026-04-27
·
via Recent Commits to openclaw:main
| Original file line number | Diff line number | Diff line change |
|---|
@@ -309,6 +309,13 @@ describe("plugin registry facade", () => {
|
309 | 309 | policyHash: resolveInstalledPluginIndexPolicyHash({ |
310 | 310 | plugins: { entries: { persisted: { enabled: true } } }, |
311 | 311 | }), |
| 312 | +installRecords: { |
| 313 | +persisted: { |
| 314 | +source: "npm", |
| 315 | +spec: "persisted-plugin@1.0.0", |
| 316 | +installPath: path.join(stateDir, "plugins", "persisted"), |
| 317 | +}, |
| 318 | +}, |
312 | 319 | }), |
313 | 320 | { stateDir }, |
314 | 321 | ); |
@@ -329,6 +336,12 @@ describe("plugin registry facade", () => {
|
329 | 336 | expect(listPluginRecords({ index: result.snapshot }).map((plugin) => plugin.pluginId)).toEqual([ |
330 | 337 | "demo", |
331 | 338 | ]); |
| 339 | +expect(result.snapshot.installRecords).toMatchObject({ |
| 340 | +persisted: { |
| 341 | +source: "npm", |
| 342 | +spec: "persisted-plugin@1.0.0", |
| 343 | +}, |
| 344 | +}); |
332 | 345 | }); |
333 | 346 | |
334 | 347 | it("falls back to the derived registry when the persisted registry is missing", () => { |
|
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。