Menu search test follows the localized labels

The exact-label ranking case now queries in Chinese, and a new case
pins English reachability through the leaf id.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QKxGW1raAWaqeU8WdHsMsp
This commit is contained in:
2026-08-25 10:37:59 -04:00
co-authored by Claude Fable 5
parent f182234796
commit b7dd8c7125
+5 -1
View File
@@ -152,9 +152,13 @@ assert(
'menu ranks an app matching the query as a whole word above exact-labeled menu entries'
)
assert(
rankScore('style.font', 'font') < rankScore('apps.fontforge', 'font'),
rankScore('style.font', '字体') < rankScore('apps.fontforge', '字体'),
'menu keeps a better-matching menu entry above a weaker app match'
)
assert(
rankScore('style.font', 'font') < rankScore('style.background', 'font'),
'menu still reaches localized entries through their English leaf id'
)
// Routing: htop ships `Keywords=system;...`, which app rows carry as aliases.
// An installed app must never capture a menu route (SUPER+ESCAPE opens the