Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-05-06 09:41:51 +0300
committerGrzegorz Bizon <grzesiek.bizon@gmail.com>2016-05-19 23:01:53 +0300
commit2ee24bd9ece394269c006f9762d3fa5e16876949 (patch)
treea3ae07164453a03060258bacb65cd7adaf4e6a0e /spec
parentdd8e9e2d7acf05b837a3bacd1258e9f3df4254a6 (diff)
Update specs to be valid only for tagged runner
Diffstat (limited to 'spec')
-rw-r--r--spec/features/runners_spec.rb22
1 files changed, 13 insertions, 9 deletions
diff --git a/spec/features/runners_spec.rb b/spec/features/runners_spec.rb
index 4f942c3ab1c..2c9c12b4dfa 100644
--- a/spec/features/runners_spec.rb
+++ b/spec/features/runners_spec.rb
@@ -126,17 +126,21 @@ describe "Runners" do
expect(page).to have_content 'Can run untagged jobs Yes'
end
- scenario 'user want to prevent runner from running untagged job' do
- visit runners_path(project)
- page.within('.activated-specific-runners') do
- first('small > a').click
- end
+ context 'when runner has tags' do
+ before { runner.update_attribute(:tag_list, ['tag']) }
- uncheck 'runner_run_untagged'
- click_button 'Save changes'
+ scenario 'user want to prevent runner from running untagged job' do
+ visit runners_path(project)
+ page.within('.activated-specific-runners') do
+ first('small > a').click
+ end
- expect(page).to have_content 'Can run untagged jobs No'
- expect(runner.reload.run_untagged?).to eq false
+ uncheck 'runner_run_untagged'
+ click_button 'Save changes'
+
+ expect(page).to have_content 'Can run untagged jobs No'
+ expect(runner.reload.run_untagged?).to eq false
+ end
end
end
end