docs: name launcher records among removal proofs

tools.md listed what keeps a platform entry out of removal_candidates
without the platform's launchers: records, which candidates.py checks
right after a path (_PROOF_ORDER).
This commit is contained in:
Abdessamad Derraz committed 2026-11-06 04:07:55 +01:00
1 parent 548a1bc636
commit 302f2a1df9
2 files changed
+25 -3

No files matched your search

+20
View File
@@ -1922,6 +1922,26 @@ class TheInstallerSamplesTravelWithTheManifests(unittest.TestCase):
self.assertTrue(any(autorun.path_matches(p, path) for p in patterns))
class TheRemovalProofsAreTheExportersOwn(unittest.TestCase):
"""tools.md listed the proofs that keep an entry out of
removal_candidates without the platform's launcher records, which
candidates.py checks right after a path."""
WORDS = {"path": "`path:`", "launcher": "`launchers:`", "name": "by name or alias",
"hash": "by any hash", "directory": "`type: directory`",
"data_directory": "a data directory"}
def test_the_page_names_each_proof_in_order(self):
from exporter.candidates import _PROOF_ORDER # noqa: PLC0415
page = (WIKI / "tools.md").read_text(encoding="utf-8")
start = page.index("No entry the platform declares is removed.")
section = page[start:page.index("removal_candidates", start)]
self.assertEqual(set(self.WORDS), set(_PROOF_ORDER))
positions = [section.index(self.WORDS[kind]) for kind in _PROOF_ORDER]
self.assertEqual(positions, sorted(positions))
class APlatformListIsDescribedNotJudged(unittest.TestCase):
"""adding-a-platform opened on files a platform's own list "leaves out",
read first by the maintainer of that platform: "does not name" says the
+5 -3
View File
@@ -359,9 +359,11 @@ test reads the original and the updated System.dat and es_bios.xml back to
check that the list is the diff.
No entry the platform declares is removed. One the truth does not pair is
looked for in the profiles of every core the platform runs: by name or
alias, by the basename or tail of a `path:`, by any hash (archive members
included), under a `type: directory` entry or a data directory. An entry
looked for, in this order: by the tail of a `path:` in the profiles of every
core the platform runs, by a name the platform's own launch code reads (its
`launchers:` records, such as the 22 names Batocera's DuckStation generator
tries), then in those profiles by name or alias, by any hash (archive
members included), under a `type: directory` entry or a data directory. An entry
none of them answers is written to `exports/<platform>.json` under
`removal_candidates`, with the cores examined for its system and a reason.
The verdict is `undetermined` when a core the platform names has no