mirror of
https://github.com/spoopyghosty0/frameport.git
synced 2026-10-24 05:01:48 +02:00
16 lines
505 B
Python
16 lines
505 B
Python
"""Every bundled catalog file parses (the loader skips broken files silently, so a typo would hide a game)."""
|
|
from pathlib import Path
|
|
|
|
import yaml
|
|
|
|
from frameport.recommend.catalog import CatalogEntry, catalog_dir
|
|
|
|
|
|
def test_every_catalog_file_parses():
|
|
files = sorted((catalog_dir() / "games").glob("*.yaml"))
|
|
assert files
|
|
for f in files:
|
|
d = yaml.safe_load(f.read_text(encoding="utf-8"))
|
|
e = CatalogEntry.from_dict(d, "bundled")
|
|
assert e.package == Path(f).stem, f
|