diff --git a/scripts/generate_site.py b/scripts/generate_site.py index 6183bcc0..8ccb3123 100644 --- a/scripts/generate_site.py +++ b/scripts/generate_site.py @@ -1187,7 +1187,9 @@ def _browser_title(relative: Path, title: str) -> str: """Return a concise, unique browser/search title for a generated page.""" key = relative.as_posix() index_titles = { - "index.md": SITE_NAME, + # Material appends " - RetroBIOS": the home title says what the site + # is, instead of "RetroBIOS - RetroBIOS". + "index.md": "BIOS and firmware packs for RetroArch, Batocera and more", "platforms/index.md": "Platforms", "systems/index.md": "Systems", "emulators/index.md": "Emulators", diff --git a/tests/test_site_validation.py b/tests/test_site_validation.py index 0ef63412..ab125691 100644 --- a/tests/test_site_validation.py +++ b/tests/test_site_validation.py @@ -232,5 +232,15 @@ class TheSitemapIsAnnouncedWhereCrawlersLook(unittest.TestCase): self.assertNotIn("Sitemap: https://", source) + +class TheHomeTitleSaysWhatTheSiteIs(unittest.TestCase): + def test_not_the_site_name_twice(self): + from generate_site import SITE_NAME, _browser_title + + title = _browser_title(Path("index.md"), SITE_NAME) + self.assertNotEqual(title, SITE_NAME) + self.assertIn("BIOS", title) + + if __name__ == "__main__": unittest.main()