this repo has no description

fix: update stale markdown tests

- Update test expecting a throw on missing frontmatter to match current
behavior (returns defaults)
- Fix invalid TOML in +++ delimiter test (quote strings and date)

+7 -7
+3 -3
packages/cli/src/lib/markdown.test.ts
··· 28 28 29 29 test("parses TOML frontmatter with +++ delimiters", () => { 30 30 const content = `+++ 31 - title = My Post 32 - description = A description 33 - date = 2024-01-15 31 + title = "My Post" 32 + description = "A description" 33 + date = "2024-01-15" 34 34 +++ 35 35 Body content`; 36 36
+4 -4
packages/cli/test/markdown.test.ts
··· 33 33 expect(body).toBe("Body content here."); 34 34 }); 35 35 36 - it("throws when no frontmatter is present", () => { 36 + it("returns defaults when no frontmatter is present", () => { 37 37 const content = "Just plain content with no frontmatter."; 38 - expect(() => parseFrontmatter(content)).toThrow( 39 - "Could not parse frontmatter", 40 - ); 38 + const { frontmatter, body } = parseFrontmatter(content); 39 + expect(frontmatter.title).toBe(""); 40 + expect(body).toBe(content); 41 41 }); 42 42 }); 43 43