diff options
Diffstat (limited to 'spec/lib/gitlab/ci/config/entry')
-rw-r--r-- | spec/lib/gitlab/ci/config/entry/job_spec.rb | 18 | ||||
-rw-r--r-- | spec/lib/gitlab/ci/config/entry/jobs_spec.rb | 2 | ||||
-rw-r--r-- | spec/lib/gitlab/ci/config/entry/root_spec.rb | 4 |
3 files changed, 3 insertions, 21 deletions
diff --git a/spec/lib/gitlab/ci/config/entry/job_spec.rb b/spec/lib/gitlab/ci/config/entry/job_spec.rb index ca02eaee0a0..ab760b107f8 100644 --- a/spec/lib/gitlab/ci/config/entry/job_spec.rb +++ b/spec/lib/gitlab/ci/config/entry/job_spec.rb @@ -74,16 +74,6 @@ RSpec.describe Gitlab::Ci::Config::Entry::Job do it { is_expected.to be_falsey } end - context 'when config does not contain script' do - let(:name) { :build } - - let(:config) do - { before_script: "cd ${PROJ_DIR} " } - end - - it { is_expected.to be_truthy } - end - context 'when using the default job without script' do let(:name) { :default } let(:config) do @@ -104,14 +94,6 @@ RSpec.describe Gitlab::Ci::Config::Entry::Job do it { is_expected.to be_truthy } end - - context 'there are no shared keys between jobs and bridges' do - subject(:shared_values) do - described_class::ALLOWED_KEYS & Gitlab::Ci::Config::Entry::Bridge::ALLOWED_KEYS - end - - it { is_expected.to be_empty } - end end describe 'validations' do diff --git a/spec/lib/gitlab/ci/config/entry/jobs_spec.rb b/spec/lib/gitlab/ci/config/entry/jobs_spec.rb index 8561bd330b7..ac6b589ec6b 100644 --- a/spec/lib/gitlab/ci/config/entry/jobs_spec.rb +++ b/spec/lib/gitlab/ci/config/entry/jobs_spec.rb @@ -68,7 +68,7 @@ RSpec.describe Gitlab::Ci::Config::Entry::Jobs do let(:config) { { rspec: nil } } it 'reports error' do - expect(entry.errors).to include "jobs config should contain valid jobs" + expect(entry.errors).to include 'jobs rspec config should implement a script: or a trigger: keyword' end end diff --git a/spec/lib/gitlab/ci/config/entry/root_spec.rb b/spec/lib/gitlab/ci/config/entry/root_spec.rb index 140b3c4f55b..252bda6461d 100644 --- a/spec/lib/gitlab/ci/config/entry/root_spec.rb +++ b/spec/lib/gitlab/ci/config/entry/root_spec.rb @@ -344,9 +344,9 @@ RSpec.describe Gitlab::Ci::Config::Entry::Root do end describe '#errors' do - it 'reports errors about missing script' do + it 'reports errors about missing script or trigger' do expect(root.errors) - .to include "root config contains unknown keys: rspec" + .to include 'jobs rspec config should implement a script: or a trigger: keyword' end end end |