mirror of
https://github.com/Abdess/retroarch_system.git
synced 2026-11-11 12:33:53 -06:00
fix: find the home page when it is MDX
The install demo made the home page index.mdx, and sitepages.require looked for index.md alone: every page test skipped locally and failed in CI, 256 at once.
This commit is contained in:
1 parent
ae7feba539
commit
de431c0d53
1 file changed
+4
-1
+4
-1
@@ -18,7 +18,10 @@ CONTENT = REPO_ROOT / "website" / "src" / "content" / "docs"
|
||||
def require() -> Path:
|
||||
"""The content folder, or a skip when the site was not generated (a
|
||||
failure in CI, which generates it before the suite)."""
|
||||
if not (CONTENT / "index.md").is_file():
|
||||
# The home page is MDX once it holds a component (the install demo):
|
||||
# looking for index.md alone skipped every page test here and failed
|
||||
# them all in CI.
|
||||
if not page("index.md").is_file():
|
||||
if os.environ.get("CI"):
|
||||
raise AssertionError("CI generates the site before the suite")
|
||||
raise unittest.SkipTest("site not generated (python scripts/generate_site.py)")
|
||||
|
||||
Reference in new issue
Block a user