forAppliesTo('wiki'); // Phase 3 ships at least the two demo templates (decision-record, // weekly-status). Asserting on count keeps this honest if either gets // removed. $this->assertGreaterThanOrEqual(2, count($wikiTemplates)); $this->assertArrayHasKey('decision-record', $wikiTemplates); $this->assertArrayHasKey('weekly-status', $wikiTemplates); } public function test_built_in_wiki_template_has_single_article_with_html_content(): void { $registry = new ContentTemplateRegistry; $tpl = $registry->get('wiki', 'decision-record'); $this->assertNotNull($tpl); $this->assertSame('wiki', $tpl->appliesTo); $articles = $tpl->payload['articles'] ?? []; $this->assertNotEmpty($articles); $this->assertIsArray($articles[0]); // The wiki Templates partial maps payload.articles[0].content into the // legacy Template->content field. HTML body, not markdown. $this->assertNotEmpty($articles[0]['content'] ?? ''); $this->assertStringContainsString('