fix(ce-release-notes): backtick-wrap <skill-name> token in description (#603)
Some checks failed
CI / pr-title (push) Has been cancelled
CI / test (push) Has been cancelled
Release PR / release-pr (push) Has been cancelled
Release PR / publish-cli (push) Has been cancelled

This commit is contained in:
Trevin Chow
2026-04-19 00:38:15 -07:00
committed by GitHub
parent b575e49c29
commit 2aee4d4203
3 changed files with 13 additions and 1 deletions

View File

@@ -72,6 +72,17 @@ describe("frontmatter YAML validity", () => {
test(`${pluginRoot}/${rel} has valid strict YAML frontmatter`, () => {
expect(() => load(yaml)).not.toThrow()
})
test(`${pluginRoot}/${rel} description has no unwrapped angle-bracket tokens`, () => {
const parsed = load(yaml) as Record<string, unknown> | null
const description = parsed && typeof parsed.description === "string" ? parsed.description : ""
// Strip backtick-delimited spans; what remains must not contain a bare <tag>.
// Cowork's plugin validator parses descriptions as HTML and rejects
// unknown tags with a silent "Plugin validation failed" banner. See issue #602.
const stripped = description.replace(/`[^`]*`/g, "")
const bareTag = stripped.match(/<[A-Za-z][\w-]*>/)
expect(bareTag, `Backtick-wrap or rephrase: ${bareTag?.[0] ?? ""}`).toBeNull()
})
}
}
})