Add specific views / selectors for QA runners page
This commit is contained in:
parent
41498864a0
commit
915b554773
2 changed files with 14 additions and 4 deletions
|
@ -8,7 +8,7 @@
|
|||
= (_("(checkout the %{link} for information on how to install it).") % { link: link }).html_safe
|
||||
%li
|
||||
= _("Specify the following URL during the Runner setup:")
|
||||
%code= root_url(only_path: false)
|
||||
%code#coordinator_address= root_url(only_path: false)
|
||||
%li
|
||||
= _("Use the following registration token during setup:")
|
||||
%code#registration_token= registration_token
|
||||
|
|
|
@ -3,14 +3,24 @@ module QA
|
|||
module Project
|
||||
module Settings
|
||||
class Runners < Page::Base
|
||||
view 'app/views/ci/runner/_how_to_setup_runner.html.haml' do
|
||||
element :registration_token, '%code#registration_token'
|
||||
element :coordinator_address, '%code#coordinator_address'
|
||||
end
|
||||
|
||||
##
|
||||
# TODO, phase-out CSS classes from Ruby helpers.
|
||||
#
|
||||
view 'app/helpers/runners_helper.rb' do
|
||||
element :runner_status, 'runner-status-#{status}'
|
||||
end
|
||||
|
||||
def registration_token
|
||||
find('code#registration_token').text
|
||||
end
|
||||
|
||||
def coordinator_address
|
||||
# TODO, this needs a specific ID or QA class
|
||||
#
|
||||
all('code').first.text
|
||||
find('code#coordinator_address').text
|
||||
end
|
||||
|
||||
def has_online_runner?
|
||||
|
|
Loading…
Reference in a new issue