From d0fc479073b029c400d5ebb0225cd76d604bf84e Mon Sep 17 00:00:00 2001 From: garrytan Date: Sat, 3 Oct 2026 01:17:49 +0000 Subject: [PATCH] test(W7c): check the codex boundary on meaning and its path list W7c conversion (t02 #14, W7a host-config.test.ts:565). The boundaryInstruction bytes sent to Codex are unchanged; only the test loosens. Removed assertion group (invariant -> remaining protection): - toContain('Do NOT read') (caps fragment): Codex must not read or execute Claude skill definitions -> kept free: /do not read or execute any files under/i plus each excluded path ('~/.claude/', '~/.agents/', '.claude/skills/', 'agents/'), which is the actual contract. Mutation pass (scratch worktree, hosts/codex.ts): 3/3 as expected; replacing the prohibition or dropping an excluded path goes red; lowering IMPORTANT/NOT stays green. Log: .context/mutation-host-config.md. --- test/host-config.test.ts | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/test/host-config.test.ts b/test/host-config.test.ts index 71433d27e..ccda86b60 100644 --- a/test/host-config.test.ts +++ b/test/host-config.test.ts @@ -562,7 +562,10 @@ describe('host config correctness', () => { test('codex has boundary instruction', () => { expect(codex.boundaryInstruction).toBeDefined(); - expect(codex.boundaryInstruction).toContain('Do NOT read'); + expect(codex.boundaryInstruction).toMatch(/do not read or execute any files under/i); + for (const glob of ['~/.claude/', '~/.agents/', '.claude/skills/', 'agents/']) { + expect(codex.boundaryInstruction).toContain(glob); + } }); test('openclaw has tool rewrites for exec/read/write', () => {