Skip to content

Autonomous development for real products. Governed agents build from specs you approve, follow the rules you set, and nothing merges until another agent proves it. Your decisions, judgement and taste are the bar that work must clear. Declare your vision and let agents build it.

test(core): target the moved route refusal predicate [M1,M4,B15]

Corey Olsondbcca750083a
diff --git a/test/machine.test.js b/test/machine.test.js
index 6e5d3dd8..48f9b68e 100644
--- a/test/machine.test.js
+++ b/test/machine.test.js
@@ -522,7 +522,7 @@ test('a broken copy of the code fails the check: a refusal added wherever a move
'MOON_PHASE is raised by refreeze but not declared there',
], 'claim and refreeze let a freeze refusal through; submit and verify catch it');
- const inArrow = editedSource('board.js', /^export const canTake = .*$/m, "export const canTake = (agentRoute, itemRoute) => { if (!agentRoute) throw new Refused('NO_ROUTE', 'no route'); return ROUTES.indexOf(itemRoute) <= ROUTES.indexOf(agentRoute); };");
+ const inArrow = editedSource('route-escalation.js', /^export const canTake = .*$/m, "import { Refused } from './refused.js';\nexport const canTake = (agentRoute, itemRoute) => { if (!agentRoute) throw new Refused('NO_ROUTE', 'no route'); return ROUTES.indexOf(itemRoute) <= ROUTES.indexOf(agentRoute); };");
assert.deepEqual(codeProblems(MACHINE, inArrow).sort(), [
'NO_ROUTE is raised by accept and reject but not declared there',
'NO_ROUTE is raised by claim but not declared there',