Fix the Autonym tests after the removal of the 'end' class

The end class was removed at
https://github.com/wikimedia/jquery.uls/pull/122

Change-Id: I548df1f14025cac0c4a89401474171d0558ff8b1
This commit is contained in:
Amir E. Aharoni
2013-12-31 12:03:22 +02:00
parent 34eee436bb
commit e9c4e63bc5
2 changed files with 5 additions and 3 deletions

View File

@@ -73,7 +73,7 @@ When(/^I switch to Input panel of language settings/) do
end
Then(/^the language list of ULS should use Autonym font$/) do
on(PanelPage).autonym_element.style("font-family").should == "'Autonym',sans-serif"
on(PanelPage).uls_language_name_item("en").style("font-family").should == "'Autonym',sans-serif"
end
Then(/^I should see (.*) as the selected input language$/) do |language|

View File

@@ -17,8 +17,6 @@ class PanelPage
div(:panel_side_display, id: "display-panel-trigger")
div(:panel_side_input, id: "input-panel-trigger")
ul(:autonym, class: "three columns end")
span(:panel_button_close, id: "languagesettings-close")
button(:panel_button_apply, class: "uls-settings-apply")
button(:panel_button_cancel, class: "uls-settings-cancel")
@@ -48,6 +46,10 @@ class PanelPage
# Is there way to access the html element?
div(:interface, id: "footer")
def uls_language_name_item(language)
@browser.element(css: ".uls-language-block li[lang=#{language}] a")
end
def content_font
font("#mw-content-text")
end