summaryrefslogtreecommitdiff
path: root/spec/lib
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2019-12-05 09:07:27 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2019-12-05 09:07:27 +0000
commit8f764d21b0011056e1492d92afe3bd40b847b9f7 (patch)
treec1b5bc3eed8ac4d4b458466a9e4a548d94f389d9 /spec/lib
parentf7ead77657cd7dc539319624301c22bf91b986e4 (diff)
downloadgitlab-ce-8f764d21b0011056e1492d92afe3bd40b847b9f7.tar.gz
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/lib')
-rw-r--r--spec/lib/gitlab/data_builder/build_spec.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/spec/lib/gitlab/data_builder/build_spec.rb b/spec/lib/gitlab/data_builder/build_spec.rb
index b170ef788d9..fdb855de786 100644
--- a/spec/lib/gitlab/data_builder/build_spec.rb
+++ b/spec/lib/gitlab/data_builder/build_spec.rb
@@ -3,7 +3,8 @@
require 'spec_helper'
describe Gitlab::DataBuilder::Build do
- let(:build) { create(:ci_build) }
+ let(:runner) { create(:ci_runner, :instance) }
+ let(:build) { create(:ci_build, :running, runner: runner) }
describe '.build' do
let(:data) do
@@ -20,6 +21,10 @@ describe Gitlab::DataBuilder::Build do
it { expect(data[:build_failure_reason]).to eq(build.failure_reason) }
it { expect(data[:project_id]).to eq(build.project.id) }
it { expect(data[:project_name]).to eq(build.project.full_name) }
+ it { expect(data[:pipeline_id]).to eq(build.pipeline.id) }
+ it { expect(data[:commit][:id]).to eq(build.pipeline.id) }
+ it { expect(data[:runner][:id]).to eq(build.runner.id) }
+ it { expect(data[:runner][:description]).to eq(build.runner.description) }
context 'commit author_url' do
context 'when no commit present' do