Skip to content

The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.

test(swarm): the team machines read check matches machineFacts' filter since #2196 (#2223)

0xken157d7ba7444823
diff --git a/backend/integration/superTabHotReads.test.ts b/backend/integration/superTabHotReads.test.ts
index e12a24930..3353ef9d9 100644
--- a/backend/integration/superTabHotReads.test.ts
+++ b/backend/integration/superTabHotReads.test.ts
@@ -270,7 +270,9 @@ describe('which machines take teammates\' work is read once per 15 s per Swarm',
it('two polls within 15 s read the team machines once; a machine turning team shows 15 s after the read', async () => {
const s = await scene()
const swarmReads = new SwarmReads(store, { now: () => clock })
- const teamReads = (entries: ProfileEntry[]) => reads(entries, 'machines', ['machineId', 'sessionKind'])
+ // The one machine-row read (store.ts machineFacts): the Swarm's machines by id, alive, in its environment. Since #2196 it
+ // takes the account kind and CLI version from the rows it returns, not from its filter.
+ const teamReads = (entries: ProfileEntry[]) => reads(entries, 'machines', ['machineId', 'autonomousEnv', 'deletedAt'])
const teamWork = (read: { derived: { machines: Record<string, { teamWork: unknown }> } }) => read.derived.machines[s.machineId]!.teamWork
clock = Date.now()
const readAt = clock