blob: bc29efb64c0fd632a7d764902526680ced235317 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
# frozen_string_literal: true
module QA
module Page
module Admin
module Settings
module Component
class PerformanceBar < Page::Base
view 'app/views/admin/application_settings/_performance_bar.html.haml' do
element :enable_performance_bar_checkbox
element :save_changes_button
end
def enable_performance_bar
click_element :enable_performance_bar_checkbox
Capybara.current_session.driver.browser.manage.add_cookie(name: 'perf_bar_enabled', value: 'true')
end
def save_settings
click_element :save_changes_button
end
end
end
end
end
end
end
|