diff options
author | Grzegorz Bizon <grzegorz@gitlab.com> | 2019-01-11 13:56:24 +0000 |
---|---|---|
committer | Grzegorz Bizon <grzegorz@gitlab.com> | 2019-01-11 13:56:24 +0000 |
commit | 6b2f81f6078e96f081154c50dc25e54fe7c09d6f (patch) | |
tree | 42f66c20d02b7ccbfa8031c95236e3cd5ba0770e /spec/models | |
parent | 249607c0ca6a77db5c45a79f5df8152d78c04bfc (diff) | |
parent | ab6b9a1c4350bbaf8b907efb28fbe456e4fe09d5 (diff) | |
download | gitlab-ce-6b2f81f6078e96f081154c50dc25e54fe7c09d6f.tar.gz |
Merge branch 'remove-get-builds-method' into 'master'
Remove get_build method for find_by_id
See merge request gitlab-org/gitlab-ce!24271
Diffstat (limited to 'spec/models')
-rw-r--r-- | spec/models/project_spec.rb | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb index 64fbc49913e..397b4d7c61f 100644 --- a/spec/models/project_spec.rb +++ b/spec/models/project_spec.rb @@ -2044,29 +2044,6 @@ describe Project do end end - describe '#get_build' do - let(:project) { create(:project, :repository) } - let(:ci_pipeline) { create(:ci_pipeline, project: project) } - - context 'when build exists' do - context 'build is associated with project' do - let(:build) { create(:ci_build, :success, pipeline: ci_pipeline) } - - it { expect(project.get_build(build.id)).to eq(build) } - end - - context 'build is not associated with project' do - let(:build) { create(:ci_build, :success) } - - it { expect(project.get_build(build.id)).to be_nil } - end - end - - context 'build does not exists' do - it { expect(project.get_build(rand 100)).to be_nil } - end - end - describe '#import_status' do context 'with import_state' do it 'returns the right status' do |