website: the language switch becomes a globe like the dashboard's (Magyar / English list, current marked, no JS); site.css v3; gate 13 checks the globe from one LANGS list; 5 decoys
gates / gates (push) Successful in 3m54s
gates / gates (push) Successful in 3m54s
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_012qRErfCoiTkvDK9N5XHbzb
This commit is contained in:
@@ -514,10 +514,24 @@ decoy("site/hreflang-wrong", "site_gates.py",
|
||||
replace_in(_EN("faq.html"), '<link rel="alternate" hreflang="en" href="https://felhom.eu/en/faq">',
|
||||
'<link rel="alternate" hreflang="en" href="https://felhom.eu/en/apps">'),
|
||||
must="en/faq.html: hreflang alternates")
|
||||
decoy("site/switch-wrong-twin", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), '<a href="/alkalmazasok" lang="hu" hreflang="hu" class="lang-switch">',
|
||||
'<a href="/" lang="hu" hreflang="hu" class="lang-switch">'),
|
||||
must="en/apps.html: the language switch points at")
|
||||
# the language globe (2026-10-08): a wrong target, two current items, a missing language, the wrong order, a leftover text switch
|
||||
_GHU = '<a href="/alkalmazasok" lang="hu" hreflang="hu" class="lang-globe-item">Magyar</a>'
|
||||
_GEN = '<a href="/en/apps" lang="en" hreflang="en" class="lang-globe-item current" aria-current="true">English</a>'
|
||||
decoy("site/globe-wrong-page", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), _GHU, _GHU.replace('href="/alkalmazasok"', 'href="/"')),
|
||||
must="en/apps.html: the globe's hu item points at '/' — its twin is '/alkalmazasok'")
|
||||
decoy("site/globe-two-current", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), _GHU, _GHU.replace('class="lang-globe-item">', 'class="lang-globe-item current" aria-current="true">')),
|
||||
must="en/apps.html: the globe marks 'hu' as current")
|
||||
decoy("site/globe-missing-language", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), "<li>" + _GHU + "</li>", ""),
|
||||
must="en/apps.html: the globe lists [('en', 'English')]")
|
||||
decoy("site/globe-wrong-order", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), "<li>" + _GHU + "</li><li>" + _GEN + "</li>", "<li>" + _GEN + "</li><li>" + _GHU + "</li>"),
|
||||
must="en/apps.html: the globe lists [('en', 'English'), ('hu', 'Magyar')]")
|
||||
decoy("site/leftover-text-switch", "site_gates.py",
|
||||
replace_in(_EN("apps.html"), '<li class="lang-globe-li">', '<li><a href="/alkalmazasok" lang="hu" hreflang="hu" class="lang-switch">Magyar</a></li><li class="lang-globe-li">'),
|
||||
must='en/apps.html: a leftover text language switch')
|
||||
decoy("site/lang-attr", "site_gates.py",
|
||||
replace_in(_EN("backups.html"), '<html lang="en">', '<html lang="hu">'),
|
||||
must="the English set needs lang='en'")
|
||||
|
||||
Reference in New Issue
Block a user