diff options
Diffstat (limited to 'spec/lib/gitlab/ci/yaml_processor/dag_spec.rb')
-rw-r--r-- | spec/lib/gitlab/ci/yaml_processor/dag_spec.rb | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/spec/lib/gitlab/ci/yaml_processor/dag_spec.rb b/spec/lib/gitlab/ci/yaml_processor/dag_spec.rb index af1b43f6b01..f815f56543c 100644 --- a/spec/lib/gitlab/ci/yaml_processor/dag_spec.rb +++ b/spec/lib/gitlab/ci/yaml_processor/dag_spec.rb @@ -27,15 +27,13 @@ RSpec.describe Gitlab::Ci::YamlProcessor::Dag do end end - context 'when there is a missing job' do + context 'when there are some missing jobs' do let(:nodes) do - { 'job_a' => %w(job_d), 'job_b' => %w(job_a) } + { 'job_a' => %w(job_d job_f), 'job_b' => %w(job_a job_c job_e) } end - it 'raises MissingNodeError' do - expect { result }.to raise_error( - Gitlab::Ci::YamlProcessor::Dag::MissingNodeError, 'node job_d is missing' - ) + it 'ignores the missing ones and returns in a valid order' do + expect(result).to eq(%w(job_d job_f job_a job_c job_e job_b)) end end end |