== packages/business rc=1 ✔ the role file loads and resolves through loadBusiness (4.58349ms) ✔ the shipped file is exactly the approved list (0.560462ms) ✔ the assistant's authority is message.send and record.write within role (1.385474ms) ✔ the assistant talks to the user and the chief of staff only, and no other shipped role is limited (0.46159ms) ✔ a business grant through limits does not widen the role (1.132081ms) ✔ a launch block whose by is the assistant is refused (1.169067ms) ✔ the instance takes no credential references and no tracker (1.758867ms) ✔ an arbiter whose role definition declares messaging lists is refused, for each kind (2.735045ms) ✔ an arbiter without messaging lists is accepted beside the limited assistant (1.495169ms) ✔ the contract passes work to the chief of staff and directs no one (0.487547ms) ✔ REQ-HARN-2: the assistant holds the web grant, and no other role file does (1.05426ms) ✔ record.write is within-role for the eleven approved v2 agents, never gated-only (2.03644ms) ✔ the four shipped version 2 roles load (2.200184ms) ✔ shipped role scopes match addendum B section 2 and the SR runbook (0.668224ms) ✔ shipped authority follows the note's table (1.489595ms) ✔ every role file in roles/ loads through the validator, and a v2 contract exists (0.676013ms) ✔ version 1 files keep loading with no authority (0.705456ms) ✔ the conductor policy isn't a role (0.145303ms) ✔ a missing role file is exit 4, a symbolic link too (0.292516ms) ✔ version 2 refusals (1.360027ms) ✔ authority: closed vocabulary, no gated-only action, no overlap (1.446438ms) ✔ messaging: optional, role definitions and human, never the tester (1.177436ms) ✔ credentials: Gitea scopes (0.593214ms) ✔ credentials: Vikunja scopes are a group-to-verbs map from the grantable list (0.694948ms) ✔ credentials: services (0.401085ms) ✔ contract: a non-empty regular Markdown file beside the role file (0.477107ms) ✖ both definitions load, with a contract file, and are exactly the approved lists (2.202706ms) ✔ security-reviewer has no write or shell tool and classifies only the verdict as its own (3.554ms) ✔ merge-gate's only grant is git.merge.protected cross-role, and it has no write tool (1.312276ms) ✔ neither role can be an arbiter: its messaging lists refuse the business file (row 133) (3.572354ms) ✔ every role contract carries the proactive line in its Authority section (0.525195ms) ✔ pm and chief-of-staff say where a raise goes under REQ-DEC-2 (0.362101ms) ℹ tests 32 ℹ suites 0 ℹ pass 31 ℹ fail 1 ℹ cancelled 0 ℹ skipped 0 ℹ todo 0 ℹ duration_ms 72.671663 ✖ failing tests: test at tests/workflow-roles.test.mjs:50:1 ✖ both definitions load, with a contract file, and are exactly the approved lists (2.202706ms) AssertionError [ERR_ASSERTION]: merge-gate at TestContext. (file:///home/jwoltje/dewey-scratch/r149/packages/business/tests/workflow-roles.test.mjs:59:12) at Test.runInAsyncScope (node:async_hooks:226:14) at Test.run (node:internal/test_runner/test:1402:25) at Test.start (node:internal/test_runner/test:1262:17) at startSubtestAfterBootstrap (node:internal/test_runner/harness:387:17) { generatedMessage: false, code: 'ERR_ASSERTION', actual: "# Merge gate\n\nYou hold a `merge-gate` role instance for one business. You land\nreviewed work on main. You don't write or review code, and you have no\nwrite tools.\n\n## Duties\n\n- Take a task whose latest push the reviewers approved. Check its trail\n with `trail`: the latest push, and an approving verdict for that push\n from each review the task needs.\n- Raise the merge decision yourself with `raise_decision`: action\n `git.merge.protected`, domain `technical`, the task reference as the\n target. Only the instance and thread that raised a decision can use its\n approval, so never land on a decision another role raised.\n- Once the decision is resolved with its approval option, call\n `land_work` with the task reference and the decision id. The host\n checks the decision and the verdicts again, and the full test gate runs.\n The outcome comes to you as a RESULT message: landed, or refused with\n the reason.\n- If the decision is declined, a verdict is missing or stale, or the\n landing is refused, don't land and don't retry around it. The bus keeps\n the refusal on the task's trail with its code; name the code and the\n reason in your answer.\n\n## Authority\n\nWithin your grants, act on what you see without waiting to be asked, and\nraise a decision or send a message for anything outside them.\n\nYour role file grants one action, `git.merge.protected`, as cross-role:\nevery landing needs a decision resolved by the technical arbiter. The\nlaunch record you received shows the resolved list for this business and\nproject, which may be narrower. You can't push, review, send messages or\nchange a task. For anything else, raise a decision and wait for it. Never\nroute around a refusal.\n\n## Protocol\n\n- You act only through the typed tools the broker gives you. You never\n hold a token.\n- You hold no `send_message` grant, so the turn's reply to a message is\n refused. A refusal and a landing are both on the task's trail.\n", expected: /^# Role contract: merge-gate\n/, operator: 'match', diff: 'simple' } == packages/bus rc=0 ✔ each C-suite role file carries the same two lists: human, chief-of-staff, pm, cto (1.282909ms) ✔ chief-executive-officer: messages to and from the user, chief of staff, pm and cto pass (405.190594ms) ✔ chief-executive-officer: a message to or from the coder, reviewer or assistant is refused and logged, and nothing is stored (387.314504ms) ✔ chief-executive-officer: another C-suite role isn't on the lists either (204.650014ms) ✔ chief-financial-officer: messages to and from the user, chief of staff, pm and cto pass (235.034326ms) ✔ chief-financial-officer: a message to or from the coder, reviewer or assistant is refused and logged, and nothing is stored (213.113104ms) ✔ chief-financial-officer: another C-suite role isn't on the lists either (186.854014ms) ✔ chief-information-officer: messages to and from the user, chief of staff, pm and cto pass (225.287977ms) ✔ chief-information-officer: a message to or from the coder, reviewer or assistant is refused and logged, and nothing is stored (211.87913ms) ✔ chief-information-officer: another C-suite role isn't on the lists either (188.925506ms) ✔ chief-information-security-officer: messages to and from the user, chief of staff, pm and cto pass (243.040717ms) ✔ chief-information-security-officer: a message to or from the coder, reviewer or assistant is refused and logged, and nothing is stored (224.968579ms) ✔ chief-information-security-officer: another C-suite role isn't on the lists either (178.766472ms) ✔ chief-marketing-officer: messages to and from the user, chief of staff, pm and cto pass (208.326849ms) ✔ chief-marketing-officer: a message to or from the coder, reviewer or assistant is refused and logged, and nothing is stored (186.958426ms) ✔ chief-marketing-officer: another C-suite role isn't on the lists either (166.415439ms) ✔ merge-gate's technical raise is cross-role, goes to the cto, and only merge-gate can use the approval (210.403795ms) ✔ merge-gate has no message.send, and without a domain its raise goes to the delivery arbiter (211.515815ms) ✔ the cto must be able to message merge-gate, or the technical raise is refused (row 133) (178.592021ms) ✔ security-reviewer answers a review with its verdict alone; it holds no message.send (219.306017ms) ℹ tests 20 ℹ suites 0 ℹ pass 20 ℹ fail 0 ℹ cancelled 0 ℹ skipped 0 ℹ todo 0 ℹ duration_ms 3530.297062 == packages/harness rc=0 ✔ raise_decision offers domain as technical or delivery only, optional, and says where a raise goes (8.39967ms) ✔ raise_decision forwards domain to decision.raise, and a call without it sends none (149.084402ms) ✔ every role sees read_spec, record writer follows its grant, citation schemas stay strict (9.525998ms) ✔ typed socket forwards read content/history and agent record writes, and cannot write a spec (178.772907ms) ✔ the PM gets its task verbs and the reads, and no launch (6.275839ms) ✔ the chief of staff gets launch, send_message, end_run and change_organization, and no task verbs (2.784542ms) ✔ request_staff is the pm's alone: staff.request over message.send, roles and counts bounded (6.771675ms) ✔ end_run sends role and reason, no decision; change_organization sends revision and the organization keys (1.213818ms) ✔ the organization keys change_organization takes are the broker's ORGANIZATION_KEYS (0.075493ms) ✔ a role without role.end or organization.change gets neither tool, and each tool follows its own grant (4.897795ms) ✔ the assistant gets send_message, the reads and the web tools (it holds the web grant), no launch (0.803514ms) ✔ list_requirements reads the requirement ids, for a task.create holder with a tracker (1.528692ms) ✔ a coder gets no launch, no resolve_decision, and no task tools without a tracker (0.748585ms) ✔ a coder with a tracker gets its own task tools and no task_reassign (0.742308ms) ✔ launch only when the business's launch block names the instance as launcher (1.381222ms) ✔ an action outside the instance's authority has no tool (0.841903ms) ✔ the review loop: push_working and request_review for the coder, fetch_review and review_verdict for the reviewer, none for the PM (3.143274ms) ✔ land_work is there only with land, after push_working, with the task and the decision (1.836723ms) ✔ callTool: one JSON line out, the result back, a refusal rejects (7.037056ms) ✔ list_tasks takes the broker's filters and pages; get_task takes a task_ref (1.623214ms) ✔ callTool sends list_tasks done false unless the session names done; other tools as given (1.803537ms) ✔ replyText: compact JSON up to the cap, an error naming the size and the cap over it (0.453924ms) ✔ web_search's query maxLength is the web layer's SEARCH_MAX_QUERY_CHARS (1.941467ms) ℹ tests 23 ℹ suites 0 ℹ pass 23 ℹ fail 0 ℹ cancelled 0 ℹ skipped 0 ℹ todo 0 ℹ duration_ms 266.470677