diff options
author | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-06-02 15:55:38 +0200 |
---|---|---|
committer | Grzegorz Bizon <grzesiek.bizon@gmail.com> | 2016-06-03 11:34:36 +0200 |
commit | 07af37a243ea0d6b5741754ea116044ee46614b3 (patch) | |
tree | d0fe16b71a7837fe9927c541cb9d3286845d235f /spec/services/ci | |
parent | 53fe06efde46acd2df62f818c421ecf3a0b971c9 (diff) | |
download | gitlab-ce-07af37a243ea0d6b5741754ea116044ee46614b3.tar.gz |
Do not create pipeline objects when no builds
Diffstat (limited to 'spec/services/ci')
-rw-r--r-- | spec/services/ci/create_builds_service_spec.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/spec/services/ci/create_builds_service_spec.rb b/spec/services/ci/create_builds_service_spec.rb index ecc3a88a262..8e737fd44f9 100644 --- a/spec/services/ci/create_builds_service_spec.rb +++ b/spec/services/ci/create_builds_service_spec.rb @@ -9,7 +9,7 @@ describe Ci::CreateBuildsService, services: true do # subject do - described_class.new(commit).execute(commit, nil, user, status) + described_class.new(commit).execute('test', user, status, nil) end context 'next builds available' do @@ -17,6 +17,10 @@ describe Ci::CreateBuildsService, services: true do it { is_expected.to be_an_instance_of Array } it { is_expected.to all(be_an_instance_of Ci::Build) } + + it 'does not persist created builds' do + expect(subject.first).not_to be_persisted + end end context 'builds skipped' do |