mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-26 16:25:14 +00:00
test: tighten channel run state assertions
This commit is contained in:
@@ -16,13 +16,11 @@ describe("createRunStateMachine", () => {
|
||||
});
|
||||
machine.onRunStart();
|
||||
machine.onRunEnd();
|
||||
expect(setStatus).toHaveBeenNthCalledWith(
|
||||
2,
|
||||
expect.objectContaining({ activeRuns: 1, busy: true, lastRunActivityAt: 123 }),
|
||||
);
|
||||
expect(setStatus).toHaveBeenLastCalledWith(
|
||||
expect.objectContaining({ activeRuns: 0, busy: false, lastRunActivityAt: 123 }),
|
||||
);
|
||||
expect(setStatus.mock.calls).toEqual([
|
||||
[{ activeRuns: 0, busy: false }],
|
||||
[{ activeRuns: 1, busy: true, lastRunActivityAt: 123 }],
|
||||
[{ activeRuns: 0, busy: false, lastRunActivityAt: 123 }],
|
||||
]);
|
||||
});
|
||||
|
||||
it("stops publishing after lifecycle abort", () => {
|
||||
|
||||
Reference in New Issue
Block a user