Regression: Using [...] to change language does not activate apply button

Bug: 53736
Change-Id: If52beb73f9f3f74cde63bd846974540682066ab6
This commit is contained in:
Niklas Laxström
2013-09-04 06:53:35 +00:00
committed by Nemo bis
parent ba065b586c
commit e36d9b1cc3
3 changed files with 30 additions and 8 deletions

View File

@@ -31,6 +31,15 @@ Given(/^the content language is "(.*?)"$/) do |language|
actual.should == code
end
Given(/^the interface language is "(.*?)"$/) do |language|
# phantomjs needs little bit time because it executes the script before
# the page is fully loaded
sleep 0.5;
code = language_to_code(language)
actual = @browser.execute_script( "return mw.config.get( 'wgUserLanguage' )" )
actual.should == code
end
def language_to_code(language)
case language
when 'German'

View File

@@ -63,3 +63,13 @@ Feature: ULS settings panel
Given I temporarily use "Finnish" as the interface language
When I open "Language" panel of language settings
Then I see "English (sama kuin sisällön)" as the name of the content language
@login @reset-preferences-after
Scenario: Selecting language via [...] button
Given I am logged in
When I open "Language" panel of language settings
And I click the button with the ellipsis
And I use the panel to change my interface language to "German"
And I apply the changes
Then the interface language is "German"