mirror of
https://github.com/openclaw/openclaw.git
synced 2026-08-19 09:01:39 -06:00
6c9b38862d
* refactor(plugins): root-owned bundle installation with scoped registry handles * refactor(plugins): root-owned bundle installation with scoped registry handles * test(gateway): expect gateway-binding fact in reload rewarm * fix(agents): reuse gateway prepared runtime generations * test(agents): isolate runtime handle fixtures * test(agents): align runtime owner fixtures * test(cron): mock run-owned registry loading
22 lines
648 B
TypeScript
22 lines
648 B
TypeScript
import type { PluginRegistry } from "../plugins/registry-types.js";
|
|
import "./plugin-node-host.js";
|
|
|
|
type NodeHostPluginTestApi = {
|
|
getNodeHostPluginRegistry(): PluginRegistry | undefined;
|
|
resetNodeHostPluginRegistry(): void;
|
|
};
|
|
|
|
function getTestApi(): NodeHostPluginTestApi {
|
|
return (globalThis as Record<PropertyKey, unknown>)[
|
|
Symbol.for("openclaw.nodeHostPluginTestApi")
|
|
] as NodeHostPluginTestApi;
|
|
}
|
|
|
|
export function getNodeHostPluginRegistry(): PluginRegistry | undefined {
|
|
return getTestApi().getNodeHostPluginRegistry();
|
|
}
|
|
|
|
export function resetNodeHostPluginRegistry(): void {
|
|
getTestApi().resetNodeHostPluginRegistry();
|
|
}
|