Skip to content

Commit bea14b4

Browse files
committed
test(scenarios): set the twin card's app code by assignment, so the error-code casing guard does not read it as an emission
`check:error-code-casing` (ADR-0112 D1) reads a `code: 'lowercase'` pair in an object literal as an error.code emission. The twin card's app code `crmtwin` is a namespace code, not an error code, so the test now assigns it the way the refusal cases already do. The guard is unchanged. Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_016WV4cyKDwJet4nwPKBn5KP
1 parent f8d3de9 commit bea14b4

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎packages/qa/scenarios/test/refusals.test.ts‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,9 @@ describe('scenario card refusals', () => {
144144
{ file: second, path: 'code', message: expect.stringMatching(/^duplicate app code `crm`, also the code of crm_account_with_contacts\.json/) },
145145
]);
146146

147-
writeFileSync(second, JSON.stringify({ ...base, id: 'crm_twin', code: 'crmtwin' }));
147+
const twin = { ...base, id: 'crm_twin' };
148+
twin.code = 'crmtwin';
149+
writeFileSync(second, JSON.stringify(twin));
148150
const ok = loadScenarios(dir, { areas });
149151
expect(ok.refusals).toEqual([]);
150152
expect(ok.cards.map((c) => c.card.code)).toEqual(['crm', 'crmtwin']);

0 commit comments

Comments
 (0)