From 07f7a01b4da02533c417fa636f004fedf3c4c661 Mon Sep 17 00:00:00 2001 From: Shinya Maeda Date: Thu, 31 Aug 2017 18:28:29 +0900 Subject: Improve spec. Add validation for accel_level on runner. --- spec/services/ci/register_job_service_spec.rb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'spec/services/ci/register_job_service_spec.rb') diff --git a/spec/services/ci/register_job_service_spec.rb b/spec/services/ci/register_job_service_spec.rb index e9bcb41c5f5..6f8ebf5d3ba 100644 --- a/spec/services/ci/register_job_service_spec.rb +++ b/spec/services/ci/register_job_service_spec.rb @@ -215,7 +215,9 @@ module Ci end end - context 'when a runner is not_protected' do + context 'when access_level of runner is not_protected' do + let!(:specific_runner) { create(:ci_runner, :not_protected, :specific) } + context 'when a job is protected' do let!(:pending_build) { create(:ci_build, :protected, pipeline: pipeline) } @@ -233,7 +235,7 @@ module Ci end end - context 'when a runner is ref_protected' do + context 'when access_level of runner is ref_protected' do let!(:specific_runner) { create(:ci_runner, :ref_protected, :specific) } context 'when a job is protected' do -- cgit v1.2.1