command: ["node", "--test", "/home/jwoltje/.t3/worktrees/mosaic-stack/magica-row329/packages/bus/tests/agents.test.mjs"]
TMPDIR: /mnt/storage/scratch/tmp/oEntjx
launch nice: 19
✔ agents: a held role with nothing on the bus is idle; a role session gets the claim rows unchanged (25.614659ms)
✔ agents: working counts what the holder received and has not read; routed alone is not working (24.589808ms)
✔ agents: input needed is the role's open decisions routed to the human, gated first, then oldest (41.7694ms)
✔ agents: working wins over waiting, and Input needed still shows (19.359692ms)
✔ agents: a new holder doesn't inherit what the last one left unread; decisions stay with the role (20.995853ms)
✔ agents: state reads only its own business, even for a run name both use (19.57121ms)
✔ agents: a message the holder released unread is stranded; the next holder gets nothing and cannot read it (24.000886ms)
✔ agents: a message the holder read is not stranded; one the current holder has not read is not listed (20.170242ms)
✔ agents: stranded is oldest first and capped at 50 for a role (89.978335ms)
✔ agents: stranded is per role and per business (37.663031ms)
✔ agents: a message routed to a held role and not yet received is not stranded (14.590846ms)
ℹ tests 11
ℹ suites 0
ℹ pass 11
ℹ fail 0
ℹ cancelled 0
ℹ skipped 0
ℹ todo 0
ℹ duration_ms 436.258985
