diff --git a/tests/unit/compliancePages.test.js b/tests/unit/compliancePages.test.js index 19285cf..071fa51 100644 --- a/tests/unit/compliancePages.test.js +++ b/tests/unit/compliancePages.test.js @@ -159,11 +159,15 @@ describe('S2 — seed articles + Ghost runbook', () => { 'content/articles/how-streaks-lie.md', ]; - it.each(ARTICLES)('%s exists with draft front matter', (rel) => { + // Truth-Everywhere Part 2 (item 8) — these 5 are now PUBLISHED to /blog with + // real dates (was draft/unwired). Lock the published shape: title + a real + // date + published status (drafts would be filtered out of the public index). + it.each(ARTICLES)('%s is published with a real date', (rel) => { const src = readRoot(rel); expect(src.startsWith('---')).toBe(true); expect(src).toContain('title:'); - expect(src).toContain('status: draft'); + expect(src).toContain('status: published'); + expect(src).toMatch(/date:\s*'?\d{4}-\d{2}-\d{2}'?/); }); it.each(ARTICLES)('%s obeys VOICE v1.1 — zero exclamation points', (rel) => {