Refactoring Applying the live preview of interface font

We renamed get*font to just *font

Change-Id: Ib6992849a2bf927d2e2d465231df58857e506a62
This commit is contained in:
Niklas Laxström
2013-10-28 12:19:36 +02:00
committed by Amire80
parent b47a8ac5d3
commit 891b6977ce
5 changed files with 18 additions and 19 deletions

View File

@@ -12,8 +12,8 @@ end
Given(/^I set "(.*?)" as the interface language$/) do |language|
code = on(PanelPage).language_to_code(language)
visit(PanelPage, :using_params => {:extra => "setlang=#{code}"})
@original_content_font = on(PanelPage).get_content_font
@original_interface_font = on(PanelPage).get_interface_font
@original_content_font = on(PanelPage).content_font
@original_interface_font = on(PanelPage).interface_font
end
Given(/^I temporarily use "(.*?)" as the interface language$/) do |language|

View File

@@ -12,12 +12,12 @@ end
Then(/^the active content font must be the same as font prior to the preview$/) do
pending('bug #56081') do
on(PanelPage).get_content_font.should == @original_content_font
on(PanelPage).content_font.should == @original_content_font
end
end
Then(/^the active interface font must be the same as font prior to the preview$/) do
on(PanelPage).get_interface_font.should == @original_interface_font
on(PanelPage).interface_font.should == @original_interface_font
end
Then(/^the selected content font must be "(.*?)"$/) do |font|
@@ -31,3 +31,7 @@ Then(/^the selected interface font must be "(.*?)"$/) do |font|
step 'I open fonts panel of language settings'
on(PanelPage).selected_interface_font.should == font
end
Then(/^the interface font must be changed to the "(.*?)" font$/) do |font|
on(PanelPage).interface_font.should match("^#{font}")
end

View File

@@ -46,13 +46,6 @@ end
When(/^I apply the changes$/) do
on(PanelPage).panel_button_apply_element.click
# Leave a little time for the settings to be saved. The settings window closes
# immediately, so it is not enough to wait for it to disappear.
sleep 4
end
Then(/^the interface font must be changed to the "(.*?)" font$/) do |font|
on(PanelPage).get_interface_font.should match("^#{font}")
end
Then(/^I can disable input methods$/) do