test(policy): cover AP Jira key title validation

This commit is contained in:
Adam Moussa 2026-08-10 16:47:37 -04:00
parent fec0d6c5f0
commit 0d802eae33
No known key found for this signature in database

View file

@ -179,6 +179,10 @@ describe('validateTitle', () => {
assert.deepEqual(v.validateTitle('docs: add runbook (SEC-7)', false), []);
});
it('accepts AP Jira keys', () => {
assert.deepEqual(v.validateTitle('feat(frontend): scaffold vite spa and ci (AP-4)', false), []);
});
it('rejects inactive Jira projects (INFRA)', () => {
const errs = v.validateTitle('fix: patch (INFRA-1)', false);
assert.ok(errs.length > 0, 'INFRA is inactive and should fail');