refactor(cli): drop tmux helpers and update help copy
This commit is contained in:
@@ -6,7 +6,6 @@ const loginWeb = vi.fn();
|
||||
const monitorWebProvider = vi.fn();
|
||||
const logWebSelfId = vi.fn();
|
||||
const waitForever = vi.fn();
|
||||
const spawnRelayTmux = vi.fn().mockResolvedValue("clawdis-relay");
|
||||
const monitorTelegramProvider = vi.fn();
|
||||
|
||||
const runtime = {
|
||||
@@ -31,7 +30,6 @@ vi.mock("./deps.js", () => ({
|
||||
createDefaultDeps: () => ({ waitForever }),
|
||||
logWebSelfId,
|
||||
}));
|
||||
vi.mock("./relay_tmux.js", () => ({ spawnRelayTmux }));
|
||||
|
||||
const { buildProgram } = await import("./program.js");
|
||||
|
||||
@@ -80,16 +78,6 @@ describe("cli program", () => {
|
||||
runtime.exit = originalExit;
|
||||
});
|
||||
|
||||
it("runs relay heartbeat tmux helper", async () => {
|
||||
const program = buildProgram();
|
||||
await program.parseAsync(["relay:heartbeat:tmux"], { from: "user" });
|
||||
const shouldAttach = Boolean(process.stdout.isTTY);
|
||||
expect(spawnRelayTmux).toHaveBeenCalledWith(
|
||||
"pnpm clawdis relay --verbose --heartbeat-now",
|
||||
shouldAttach,
|
||||
);
|
||||
});
|
||||
|
||||
it("runs telegram relay when token set", async () => {
|
||||
const program = buildProgram();
|
||||
const prev = process.env.TELEGRAM_BOT_TOKEN;
|
||||
|
||||
Reference in New Issue
Block a user