diff options
author | Kamil TrzciĆski <ayufan@ayufan.eu> | 2018-05-23 13:23:49 +0200 |
---|---|---|
committer | Dylan Griffith <dyl.griffith@gmail.com> | 2018-05-31 10:56:07 +0200 |
commit | 051f385e7e82130e6978cd3956e5c48fbdc83b2e (patch) | |
tree | 14284bade4be86bb80984127be91c30ada3de633 /spec/features/runners_spec.rb | |
parent | 5c34c3fcd5f100b401b59d5a0f8e4fa0c899c8f5 (diff) | |
download | gitlab-ce-051f385e7e82130e6978cd3956e5c48fbdc83b2e.tar.gz |
Refactor validations and make runner factory by default to be instance-wide runner
Diffstat (limited to 'spec/features/runners_spec.rb')
-rw-r--r-- | spec/features/runners_spec.rb | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/spec/features/runners_spec.rb b/spec/features/runners_spec.rb index f905e6d4f5e..9942de526d8 100644 --- a/spec/features/runners_spec.rb +++ b/spec/features/runners_spec.rb @@ -29,11 +29,7 @@ feature 'Runners' do end context 'when a project_type runner is activated on the project' do - given(:specific_runner) { create(:ci_runner, :project) } - - background do - project.runners << specific_runner - end + given(:specific_runner) { create(:ci_runner, :project, projects: [specific_runner]) } scenario 'user sees the specific runner' do visit project_runners_path(project) @@ -126,11 +122,10 @@ feature 'Runners' do context 'when a specific runner exists in another project' do given(:another_project) { create(:project) } - given(:specific_runner) { create(:ci_runner, :project) } + given(:specific_runner) { create(:ci_runner, :project, projects: [another_project]) } background do another_project.add_master(user) - another_project.runners << specific_runner end scenario 'user enables and disables a specific runner' do |