From de5119dcb689ef818a6aa1e2ac18c33280197981 Mon Sep 17 00:00:00 2001 From: affaan-m <124439313+affaan-m@users.noreply.github.com> Date: Mon, 28 Sep 2026 05:11:01 -0400 Subject: [PATCH] fix(locale): reject missing canonical agent declarations Preserve contributor history while applying the exact reviewed current-main repair. Source-PR: https://github.com/affaan-m/ECC/pull/2879 Source-Parent: cc9914ce772a82449dacbfe3f12a493f14a9424a Review-Manifest-SHA256: d561b12170431bc2f5ec9baa80548a656fca9e55b4bb6b11bd756be4e6cab199 --- tests/ci/locale-agent-frontmatter.test.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/ci/locale-agent-frontmatter.test.js b/tests/ci/locale-agent-frontmatter.test.js index 83ba42ec3..caca19cb1 100644 --- a/tests/ci/locale-agent-frontmatter.test.js +++ b/tests/ci/locale-agent-frontmatter.test.js @@ -138,7 +138,7 @@ function main() { const fields = frontmatter(filePath); if (!fields) continue; const want = canonical.get(file).model; - if (want !== undefined && fields.model !== undefined && fields.model !== want) { + if (want !== undefined && fields.model !== want) { drift.push(`${rel(filePath)}: ${fields.model} != ${want}`); } } @@ -156,9 +156,9 @@ function main() { if (!fields) continue; const want = toolSet(canonical.get(file).tools); const have = toolSet(fields.tools); - if (want === null || have === null) continue; + if (want === null) continue; if (!sameSet(want, have)) { - drift.push(`${rel(filePath)}: [${[...have]}] != [${[...want]}]`); + drift.push(`${rel(filePath)}: ${have === null ? '' : `[${[...have]}]`} != [${[...want]}]`); } } assert.deepStrictEqual(