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
path: root/spec
diff options
context:
space:
mode:
authorGrzegorz Bizon <grzegorz@gitlab.com>2017-10-21 21:26:31 +0300
committerWinnie Hellmann <winnie@gitlab.com>2017-10-21 22:16:58 +0300
commit8adaa54afa277f24ecae59f1c8c0feb94bd38c03 (patch)
tree0cd16faf3298d1176f7a385c4ffba9b4efa7b0af /spec
parent954c116f0d153828f975c9a2269ced5de094b8f2 (diff)
Merge branch '39189-online-view-of-html-artifacts-is-broken' into 'master'
Resolve "Online view of HTML artifacts is broken?" Closes #39189 See merge request gitlab-org/gitlab-ce!14977 (cherry picked from commit cfd97f7ebedec56ccf979e21997dfa19e0807205) 3c0be3cd Fix the external URLs generated for online view of HTML artifacts
Diffstat (limited to 'spec')
-rw-r--r--spec/models/ci/artifact_blob_spec.rb7
1 files changed, 3 insertions, 4 deletions
diff --git a/spec/models/ci/artifact_blob_spec.rb b/spec/models/ci/artifact_blob_spec.rb
index d5ba088af53..4e72d9d748e 100644
--- a/spec/models/ci/artifact_blob_spec.rb
+++ b/spec/models/ci/artifact_blob_spec.rb
@@ -56,15 +56,14 @@ describe Ci::ArtifactBlob do
end
context 'txt extensions' do
- let(:entry) { build.artifacts_metadata_entry('other_artifacts_0.1.2/doc_sample.txt') }
+ let(:path) { 'other_artifacts_0.1.2/doc_sample.txt' }
+ let(:entry) { build.artifacts_metadata_entry(path) }
it 'returns a URL' do
url = subject.external_url(build.project, build)
expect(url).not_to be_nil
- expect(url).to start_with("http")
- expect(url).to match Gitlab.config.pages.host
- expect(url).to end_with(entry.path)
+ expect(url).to eq("http://#{project.namespace.path}.#{Gitlab.config.pages.host}/-/#{project.path}/-/jobs/#{build.id}/artifacts/#{path}")
end
end
end