diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-12-19 00:08:01 +0000 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-12-19 00:08:01 +0000 |
commit | 1caa60060b2f9e3417ab335e2f1dea1064163434 (patch) | |
tree | 01c0d5825bd345ee625bb70b7433c6e10307fcce /spec/models/ci | |
parent | 7f8330873c1a5860b8a9a52d111083a65d210249 (diff) | |
download | gitlab-ce-1caa60060b2f9e3417ab335e2f1dea1064163434.tar.gz |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/models/ci')
-rw-r--r-- | spec/models/ci/build_spec.rb | 3 | ||||
-rw-r--r-- | spec/models/ci/runner_spec.rb | 2 | ||||
-rw-r--r-- | spec/models/ci/stage_spec.rb | 1 |
3 files changed, 6 insertions, 0 deletions
diff --git a/spec/models/ci/build_spec.rb b/spec/models/ci/build_spec.rb index 20915e6d3b1..d813a88c809 100644 --- a/spec/models/ci/build_spec.rb +++ b/spec/models/ci/build_spec.rb @@ -610,6 +610,7 @@ describe Ci::Build do context 'artifacts archive is a zip file and metadata exists' do let(:build) { create(:ci_build, :artifacts) } + it { is_expected.to be_truthy } end end @@ -1408,6 +1409,7 @@ describe Ci::Build do describe '#erased?' do let!(:build) { create(:ci_build, :trace_artifact, :success, :artifacts) } + subject { build.erased? } context 'job has not been erased' do @@ -1469,6 +1471,7 @@ describe Ci::Build do describe '#first_pending' do let!(:first) { create(:ci_build, pipeline: pipeline, status: 'pending', created_at: Date.yesterday) } let!(:second) { create(:ci_build, pipeline: pipeline, status: 'pending') } + subject { described_class.first_pending } it { is_expected.to be_a(described_class) } diff --git a/spec/models/ci/runner_spec.rb b/spec/models/ci/runner_spec.rb index ac438f7d473..5c9a03a26ec 100644 --- a/spec/models/ci/runner_spec.rb +++ b/spec/models/ci/runner_spec.rb @@ -755,11 +755,13 @@ describe Ci::Runner do context 'when group runner' do let(:runner) { create(:ci_runner, :group, description: 'Group runner', groups: [group]) } let(:group) { create(:group) } + it { is_expected.to be_falsey } end context 'when shared runner' do let(:runner) { create(:ci_runner, :instance, description: 'Shared runner') } + it { is_expected.to be_falsey } end diff --git a/spec/models/ci/stage_spec.rb b/spec/models/ci/stage_spec.rb index c997f1ef405..b65c11f837c 100644 --- a/spec/models/ci/stage_spec.rb +++ b/spec/models/ci/stage_spec.rb @@ -146,6 +146,7 @@ describe Ci::Stage, :models do let(:user) { create(:user) } let(:stage) { create(:ci_stage_entity, status: :created) } + subject { stage.detailed_status(user) } where(:statuses, :label) do |