diff options
author | Alexis Reigel <alexis.reigel.ext@siemens.com> | 2017-10-05 15:25:31 +0300 |
---|---|---|
committer | Alexis Reigel <alexis.reigel.ext@siemens.com> | 2018-04-23 10:21:49 +0300 |
commit | 6077c569a6cc323c5eab09486e5254c5f96ce601 (patch) | |
tree | 5353abb0b3ada5e2decaf194f4f12211607acaa6 /spec/features/admin | |
parent | a5f5a27df5d3055612fc8c2686ef3b9ab20bd85e (diff) |
denote group runners on admin runners page
Diffstat (limited to 'spec/features/admin')
-rw-r--r-- | spec/features/admin/admin_runners_spec.rb | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/spec/features/admin/admin_runners_spec.rb b/spec/features/admin/admin_runners_spec.rb index 8de2e3d199b..b0aa2e8b588 100644 --- a/spec/features/admin/admin_runners_spec.rb +++ b/spec/features/admin/admin_runners_spec.rb @@ -59,6 +59,47 @@ describe "Admin Runners" do expect(page).to have_text 'No runners found' end end + + context 'group runner' do + it 'shows the label and does not show the project count' do + group = create :group + runner = create :ci_runner, groups: [group] + + visit admin_runners_path + + within "#runner_#{runner.id}" do + expect(page).to have_selector '.label', text: 'group' + expect(page).to have_text 'n/a' + end + end + end + + context 'shared runner' do + it 'shows the label and does not show the project count' do + runner = create :ci_runner, :shared + + visit admin_runners_path + + within "#runner_#{runner.id}" do + expect(page).to have_selector '.label', text: 'shared' + expect(page).to have_text 'n/a' + end + end + end + + context 'specific runner' do + it 'shows the label and the project count' do + project = create :project + runner = create :ci_runner, projects: [project] + + visit admin_runners_path + + within "#runner_#{runner.id}" do + expect(page).to have_selector '.label', text: 'specific' + expect(page).to have_text '1' + end + end + end end describe "Runner show page" do |