diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-24 21:14:31 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-11-24 21:14:31 +0300 |
commit | 844eb8879aa445d8a5ee0f2ba3ee1ccf18319ef1 (patch) | |
tree | 051c632f870cbffd93efccda0711b3ae3a5885df /workhorse/internal/zipartifacts | |
parent | b8d516a6876de74b68a800c5b69af9448b0de140 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'workhorse/internal/zipartifacts')
4 files changed, 5 insertions, 10 deletions
diff --git a/workhorse/internal/zipartifacts/metadata.go b/workhorse/internal/zipartifacts/metadata.go index 1ecf52deafb..456d2c101cb 100644 --- a/workhorse/internal/zipartifacts/metadata.go +++ b/workhorse/internal/zipartifacts/metadata.go @@ -1,7 +1,6 @@ package zipartifacts import ( - "archive/zip" "compress/gzip" "encoding/binary" "encoding/json" @@ -9,6 +8,8 @@ import ( "path" "sort" "strconv" + + zip "gitlab.com/gitlab-org/golang-archive-zip" ) type metadata struct { diff --git a/workhorse/internal/zipartifacts/metadata_test.go b/workhorse/internal/zipartifacts/metadata_test.go index ffc5f58cb21..353ed4376f6 100644 --- a/workhorse/internal/zipartifacts/metadata_test.go +++ b/workhorse/internal/zipartifacts/metadata_test.go @@ -1,7 +1,6 @@ package zipartifacts_test import ( - "archive/zip" "bytes" "compress/gzip" "context" @@ -12,6 +11,7 @@ import ( "testing" "github.com/stretchr/testify/require" + zip "gitlab.com/gitlab-org/golang-archive-zip" "gitlab.com/gitlab-org/gitlab/workhorse/internal/zipartifacts" ) diff --git a/workhorse/internal/zipartifacts/open_archive.go b/workhorse/internal/zipartifacts/open_archive.go index ec2fd691038..881ef915d75 100644 --- a/workhorse/internal/zipartifacts/open_archive.go +++ b/workhorse/internal/zipartifacts/open_archive.go @@ -1,7 +1,6 @@ package zipartifacts import ( - "archive/zip" "context" "fmt" "io" @@ -12,6 +11,7 @@ import ( "gitlab.com/gitlab-org/gitlab/workhorse/internal/helper/httptransport" "gitlab.com/gitlab-org/gitlab/workhorse/internal/httprs" + zip "gitlab.com/gitlab-org/golang-archive-zip" "gitlab.com/gitlab-org/labkit/mask" ) diff --git a/workhorse/internal/zipartifacts/open_archive_test.go b/workhorse/internal/zipartifacts/open_archive_test.go index ea1fc606784..e339454345b 100644 --- a/workhorse/internal/zipartifacts/open_archive_test.go +++ b/workhorse/internal/zipartifacts/open_archive_test.go @@ -1,7 +1,6 @@ package zipartifacts import ( - "archive/zip" "bytes" "context" "fmt" @@ -10,11 +9,10 @@ import ( "net/http/httptest" "os" "path/filepath" - "runtime" - "strings" "testing" "github.com/stretchr/testify/require" + zip "gitlab.com/gitlab-org/golang-archive-zip" ) func createArchive(t *testing.T, dir string) (map[string][]byte, int64) { @@ -73,10 +71,6 @@ func TestOpenHTTPArchive(t *testing.T) { } func TestMinimalRangeRequests(t *testing.T) { - if strings.HasPrefix(runtime.Version(), "go1.17") { - t.Skipf("skipped for go1.17: https://gitlab.com/gitlab-org/gitlab/-/issues/340778") - } - dir := t.TempDir() entries, archiveSize := createArchive(t, dir) |