create(['portal' => Portal::Presseecho, 'is_active' => true]); $category->translations()->create(['locale' => 'de', 'name' => 'Energie', 'slug' => 'energie']); $inactive = Category::factory()->create(['portal' => Portal::Presseecho, 'is_active' => false]); $inactive->translations()->create(['locale' => 'de', 'name' => 'Veraltet', 'slug' => 'veraltet']); $response = $this->get('https://presseecho.test/llms.txt') ->assertSuccessful() ->assertHeader('Content-Type', 'text/plain; charset=UTF-8'); $text = (string) $response->getContent(); expect($text) ->toStartWith("# presseecho\n\n> ") ->toContain('https://presseecho.test/de/press-release/{slug}') ->toContain('https://presseecho.test/sitemap-news.xml') ->toContain('- [Energie](https://presseecho.test/de/category/energie)') ->toContain('- [Impressum](https://presseecho.test/de/impressum)') ->toContain('NewsArticle'); $this->assertStringNotContainsString('veraltet', $text); }); test('the hub serves llms.txt that points to both portals', function () { /** @var TestCase $this */ $text = (string) $this->get('https://pressekonto.test/llms.txt')->assertSuccessful()->getContent(); expect($text) ->toStartWith("# pressekonto\n\n> ") ->toContain('https://presseecho.test/llms.txt') ->toContain('https://businessportal24.test/llms.txt') ->toContain('https://pressekonto.test/docs/api/v1'); $this->assertStringNotContainsString('press-release/{slug}', $text); }); test('llms.txt is part of the public page caches that a content change clears', function () { /** @var TestCase $this */ $this->get('https://presseecho.test/llms.txt')->assertSuccessful(); expect(Cache::has('web.llms.presseecho.test'))->toBeTrue(); WebCaches::forgetPublicPages(); // Umsetzungsaudit 29.09.2026, R-11: sonst bis zu 1 h alte Kategorienliste. expect(Cache::has('web.llms.presseecho.test'))->toBeFalse(); });