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:
authorJames Ramsay <james@jramsay.com.au>2018-02-19 23:41:04 +0300
committerJames Ramsay <james@jramsay.com.au>2018-04-06 15:45:17 +0300
commit07f517d441ab8782286b4a59d56a630393d75e16 (patch)
treed388461feb28fbed2b5c6f52303c7eb7b0f633e3 /spec/lib/gitlab/workhorse_spec.rb
parent0b1b9c409d3adbf4517351dbb9037ed053f73e67 (diff)
Add new repository archive route
Repository archives are always named `<project>-<ref>-<sha>` even if the ref is a commit. A consequence of always including the sha even for tags is that packaging a release is more difficult because both the ref and sha must be known by the packager. - add `<project>/-/archive/<ref>/<filename>.<format>` route using the `-` separator to prevent namespace collisions. If the filename is `<project>-<ref>` or the ref is a sha, the sha will be omitted, otherwise the default filename will be used. - deprecate previous archive route `repository/<ref>/archive`
Diffstat (limited to 'spec/lib/gitlab/workhorse_spec.rb')
-rw-r--r--spec/lib/gitlab/workhorse_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/lib/gitlab/workhorse_spec.rb b/spec/lib/gitlab/workhorse_spec.rb
index 2b3ffb2d7c0..d64ea72e346 100644
--- a/spec/lib/gitlab/workhorse_spec.rb
+++ b/spec/lib/gitlab/workhorse_spec.rb
@@ -16,7 +16,7 @@ describe Gitlab::Workhorse do
let(:ref) { 'master' }
let(:format) { 'zip' }
let(:storage_path) { Gitlab.config.gitlab.repository_downloads_path }
- let(:base_params) { repository.archive_metadata(ref, storage_path, format) }
+ let(:base_params) { repository.archive_metadata(ref, storage_path, format, append_sha: nil) }
let(:gitaly_params) do
base_params.merge(
'GitalyServer' => {
@@ -29,7 +29,7 @@ describe Gitlab::Workhorse do
let(:cache_disabled) { false }
subject do
- described_class.send_git_archive(repository, ref: ref, format: format)
+ described_class.send_git_archive(repository, ref: ref, format: format, append_sha: nil)
end
before do