Repair a broken parser test

Before Ia72c960b2c7914342eb4d5e3e63f2d6af14719ad the parser test
framework wasn't setting the user language correctly when a variant
was requested, which meant that the UX text was being selected from
the base language, not the user's preferred variant.

Depends-On: I0c9c9fec920f7cb028d935e552a8f11475a23ba7
Change-Id: I7ab40a1d9adc6478c2fe99f44c8f51cbe4ac23a0
This commit is contained in:
C. Scott Ananian 2023-01-26 14:26:58 -05:00 committed by C. Scott Ananian
parent 8f992cf5ef
commit 3d8bbe8f87

View file

@ -231,13 +231,10 @@ tour=test
<div class="mw-inputbox-centered" style=""><form name="searchbox" class="searchbox" action="/wiki/Special:Search"><input class="mw-inputbox-input mw-searchInput searchboxInput mw-ui-input mw-ui-input-inline" name="search" placeholder="" size="50" dir="ltr" /><input type="hidden" value="test" name="tour" /><br /><input type="submit" name="go" class="mw-ui-button" value="Try exact match" />&#160;<input type="submit" name="fulltext" class="mw-ui-button" value="Search full text" /></form></div>
!! end
# XXX This test is broken: note that the UX text is in sr-Cyrl but the
# variant requested was sr-Latn
!! test
InputBox langconvert
!! options
language=sr variant=sr-Latn
disabled
!! wikitext
<inputbox>
type=create
@ -245,7 +242,7 @@ default=-{sr-Latn: Some latin; sr-Cyrl: Not latin }-
placeholder=-{sr-Latn: Latn; sr-Cyrl: Cyrl}-
</inputbox>
!! html
<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline mw-inputbox-createbox" value="Some latin" placeholder="Latn" required="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive" value="Направи страницу" /></form></div>
<div class="mw-inputbox-centered" style=""><form name="createbox" class="createbox" action="/index.php" method="get"><input type="hidden" value="edit" name="action" /><input name="title" class="mw-inputbox-input mw-ui-input mw-ui-input-inline mw-inputbox-createbox" value="Some latin" placeholder="Latn" required="" size="50" dir="ltr" /><br /><input type="submit" name="create" class="mw-ui-button mw-ui-progressive" value="Napravi stranicu" /></form></div>
!! end
!! test