fix: keep install lists unfiltered on --target

This commit is contained in:
Abdessamad Derraz committed 2026-11-05 11:41:34 +01:00
1 parent d38cd58036
commit e54d146954
2 files changed
+25 -2

No files matched your search

+3 -2
View File
@@ -1008,8 +1008,9 @@ def main() -> None:
# Step 2 refreshed the trees once: refreshing again here let the
# pack and the manifest describe two revisions of a moving tree.
manifest_cmd.append("--no-refresh-data")
if args.target:
manifest_cmd.extend(["--target", args.target])
# No --target here: install/ holds the published lists, and every
# reader (site picker, release check, record) takes each file there
# as a whole platform. The per-target core lists are step 4c.
ok, _ = run(manifest_cmd, STEP_LABELS["generate_manifests"])
results["generate_manifests"] = ok
all_ok = all_ok and ok
+22
View File
@@ -194,3 +194,25 @@ class ASingleTargetFiltersNothing(unittest.TestCase):
if __name__ == "__main__":
unittest.main()
class PublishedListsAreNotNarrowed(unittest.TestCase):
"""pipeline --target switch wrote install/retroarch_nintendoswitch.json
next to the published lists; the site picker then replaced RetroArch's
file list with the Switch one and check_release asked for it as an asset."""
def test_pipeline_writes_install_unfiltered(self):
pipeline = (REPO_ROOT / "scripts" / "pipeline.py").read_text()
self.assertNotIn('manifest_cmd.extend(["--target"', pipeline)
def test_every_install_list_is_a_whole_platform(self):
import json # noqa: PLC0415
for path in sorted((REPO_ROOT / "install").glob("*.json")):
data = json.loads(path.read_text(encoding="utf-8"))
with self.subTest(path=path.name):
self.assertEqual(path.stem, data["platform"])
self.assertNotIn("target", data)
self.assertNotIn("no_game_data", data)
self.assertEqual(data["source"], "full")
self.assertEqual(data["regions"], [])