Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzegorz@gitlab.com>2017-12-05 17:31:33 +0300
committerKamil TrzciƄski <ayufan@ayufan.eu>2018-02-28 22:44:09 +0300
commit6ca02a41500790b3e9061dd8836540955b9aaf7c (patch)
tree5c66c4826cafa2657fe25d85eb9e189b5f290f32 /spec/requests/api/v3
parentec72abf53fd82ca3e7f126536a83b27b368696ec (diff)
Merge branch 'zj-multiple-artifacts-ee' into 'master'
Multiple artifacts ee See merge request gitlab-org/gitlab-ee!3276
Diffstat (limited to 'spec/requests/api/v3')
-rw-r--r--spec/requests/api/v3/builds_spec.rb16
1 files changed, 13 insertions, 3 deletions
diff --git a/spec/requests/api/v3/builds_spec.rb b/spec/requests/api/v3/builds_spec.rb
index 266ae654227..862bf7e540d 100644
--- a/spec/requests/api/v3/builds_spec.rb
+++ b/spec/requests/api/v3/builds_spec.rb
@@ -215,10 +215,13 @@ describe API::V3::Builds do
end
context 'when artifacts are stored remotely' do
- let(:build) { create(:ci_build, :artifacts, :remote_store, pipeline: pipeline) }
+ let(:build) { create(:ci_build, pipeline: pipeline) }
+ let!(:artifact) { create(:ci_job_artifact, :archive, :remote_store, job: build) }
it 'returns location redirect' do
- expect(response).to have_http_status(302)
+ get v3_api("/projects/#{project.id}/builds/#{build.id}/artifacts", api_user)
+
+ expect(response).to have_gitlab_http_status(302)
end
end
@@ -309,7 +312,14 @@ describe API::V3::Builds do
end
context 'when artifacts are stored remotely' do
- let(:build) { create(:ci_build, :artifacts, :remote_store, pipeline: pipeline) }
+ let(:build) { create(:ci_build, pipeline: pipeline) }
+ let!(:artifact) { create(:ci_job_artifact, :archive, :remote_store, job: build) }
+
+ before do
+ build.reload
+
+ get v3_api("/projects/#{project.id}/builds/#{build.id}/artifacts", api_user)
+ end
it 'returns location redirect' do
expect(response).to have_http_status(302)