mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-10 03:52:42 +00:00
chore: update molt.bot domains
This commit is contained in:
@@ -83,6 +83,26 @@ describe("lobster plugin tool", () => {
|
||||
expect(res.details).toMatchObject({ ok: true, status: "ok" });
|
||||
});
|
||||
|
||||
it("tolerates noisy stdout before the JSON envelope", async () => {
|
||||
const payload = { ok: true, status: "ok", output: [], requiresApproval: null };
|
||||
const { binPath } = await writeFakeLobsterScript(
|
||||
`const payload = ${JSON.stringify(payload)};\n` +
|
||||
`console.log("noise before json");\n` +
|
||||
`process.stdout.write(JSON.stringify(payload));\n`,
|
||||
"clawdbot-lobster-plugin-noisy-",
|
||||
);
|
||||
|
||||
const tool = createLobsterTool(fakeApi());
|
||||
const res = await tool.execute("call-noisy", {
|
||||
action: "run",
|
||||
pipeline: "noop",
|
||||
lobsterPath: binPath,
|
||||
timeoutMs: 1000,
|
||||
});
|
||||
|
||||
expect(res.details).toMatchObject({ ok: true, status: "ok" });
|
||||
});
|
||||
|
||||
it("requires absolute lobsterPath when provided", async () => {
|
||||
const tool = createLobsterTool(fakeApi());
|
||||
await expect(
|
||||
|
||||
Reference in New Issue
Block a user