fix: launcher test names packages as the scraper

PlatformRecords stripped lr- to compare package records with cores. The scraper now names a libretro package with core_name(), lr-dosbox-pure as dosbox_pure, so the test reads the same function.
This commit is contained in:
Abdessamad Derraz committed 2026-11-06 05:21:55 +01:00
1 parent 305adb288e
commit c6713118bc
1 file changed
+3 -2
+3 -2
View File
@@ -376,8 +376,9 @@ class PlatformRecords(unittest.TestCase):
def test_one_package_record_per_core(self):
packages = [r["package"] for r in self.config["launchers"] if r["kind"] == "package"]
self.assertEqual(len(packages), len(set(packages)))
stripped = {p.removeprefix("lr-") for p in packages}
self.assertEqual(stripped, set(self.config["cores"]))
from scraper.retropie_scraper import core_name # noqa: PLC0415
self.assertEqual({core_name(p) for p in packages}, set(self.config["cores"]))
def test_every_record_belongs_to_a_package(self):
packages = {r["package"] for r in self.config["launchers"] if r["kind"] == "package"}