diff --git a/client/gitlab/client.go b/client/gitlab/client.go index 1fc98e6..fd4c7b8 100644 --- a/client/gitlab/client.go +++ b/client/gitlab/client.go @@ -4,7 +4,7 @@ import ( "encoding/json" "fmt" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" "github.com/mendersoftware/integration-test-runner/logger" ) diff --git a/client/gitlab/mocks/Client.go b/client/gitlab/mocks/Client.go index 2857b1b..0efe247 100644 --- a/client/gitlab/mocks/Client.go +++ b/client/gitlab/mocks/Client.go @@ -4,7 +4,7 @@ package mocks import ( mock "github.com/stretchr/testify/mock" - go_gitlab "github.com/xanzy/go-gitlab" + client_go "gitlab.com/gitlab-org/api/client-go" ) // Client is an autogenerated mock type for the Client type @@ -27,23 +27,23 @@ func (_m *Client) CancelPipelineBuild(path string, id int) error { } // CreatePipeline provides a mock function with given fields: path, options -func (_m *Client) CreatePipeline(path string, options *go_gitlab.CreatePipelineOptions) (*go_gitlab.Pipeline, error) { +func (_m *Client) CreatePipeline(path string, options *client_go.CreatePipelineOptions) (*client_go.Pipeline, error) { ret := _m.Called(path, options) - var r0 *go_gitlab.Pipeline + var r0 *client_go.Pipeline var r1 error - if rf, ok := ret.Get(0).(func(string, *go_gitlab.CreatePipelineOptions) (*go_gitlab.Pipeline, error)); ok { + if rf, ok := ret.Get(0).(func(string, *client_go.CreatePipelineOptions) (*client_go.Pipeline, error)); ok { return rf(path, options) } - if rf, ok := ret.Get(0).(func(string, *go_gitlab.CreatePipelineOptions) *go_gitlab.Pipeline); ok { + if rf, ok := ret.Get(0).(func(string, *client_go.CreatePipelineOptions) *client_go.Pipeline); ok { r0 = rf(path, options) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*go_gitlab.Pipeline) + r0 = ret.Get(0).(*client_go.Pipeline) } } - if rf, ok := ret.Get(1).(func(string, *go_gitlab.CreatePipelineOptions) error); ok { + if rf, ok := ret.Get(1).(func(string, *client_go.CreatePipelineOptions) error); ok { r1 = rf(path, options) } else { r1 = ret.Error(1) @@ -53,19 +53,19 @@ func (_m *Client) CreatePipeline(path string, options *go_gitlab.CreatePipelineO } // GetPipelineVariables provides a mock function with given fields: path, id -func (_m *Client) GetPipelineVariables(path string, id int) ([]*go_gitlab.PipelineVariable, error) { +func (_m *Client) GetPipelineVariables(path string, id int) ([]*client_go.PipelineVariable, error) { ret := _m.Called(path, id) - var r0 []*go_gitlab.PipelineVariable + var r0 []*client_go.PipelineVariable var r1 error - if rf, ok := ret.Get(0).(func(string, int) ([]*go_gitlab.PipelineVariable, error)); ok { + if rf, ok := ret.Get(0).(func(string, int) ([]*client_go.PipelineVariable, error)); ok { return rf(path, id) } - if rf, ok := ret.Get(0).(func(string, int) []*go_gitlab.PipelineVariable); ok { + if rf, ok := ret.Get(0).(func(string, int) []*client_go.PipelineVariable); ok { r0 = rf(path, id) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).([]*go_gitlab.PipelineVariable) + r0 = ret.Get(0).([]*client_go.PipelineVariable) } } @@ -79,23 +79,23 @@ func (_m *Client) GetPipelineVariables(path string, id int) ([]*go_gitlab.Pipeli } // ListProjectPipelines provides a mock function with given fields: path, options -func (_m *Client) ListProjectPipelines(path string, options *go_gitlab.ListProjectPipelinesOptions) ([]*go_gitlab.PipelineInfo, error) { +func (_m *Client) ListProjectPipelines(path string, options *client_go.ListProjectPipelinesOptions) ([]*client_go.PipelineInfo, error) { ret := _m.Called(path, options) - var r0 []*go_gitlab.PipelineInfo + var r0 []*client_go.PipelineInfo var r1 error - if rf, ok := ret.Get(0).(func(string, *go_gitlab.ListProjectPipelinesOptions) ([]*go_gitlab.PipelineInfo, error)); ok { + if rf, ok := ret.Get(0).(func(string, *client_go.ListProjectPipelinesOptions) ([]*client_go.PipelineInfo, error)); ok { return rf(path, options) } - if rf, ok := ret.Get(0).(func(string, *go_gitlab.ListProjectPipelinesOptions) []*go_gitlab.PipelineInfo); ok { + if rf, ok := ret.Get(0).(func(string, *client_go.ListProjectPipelinesOptions) []*client_go.PipelineInfo); ok { r0 = rf(path, options) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).([]*go_gitlab.PipelineInfo) + r0 = ret.Get(0).([]*client_go.PipelineInfo) } } - if rf, ok := ret.Get(1).(func(string, *go_gitlab.ListProjectPipelinesOptions) error); ok { + if rf, ok := ret.Get(1).(func(string, *client_go.ListProjectPipelinesOptions) error); ok { r1 = rf(path, options) } else { r1 = ret.Error(1) diff --git a/go.mod b/go.mod index 10c9f40..2ac120b 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,7 @@ require ( github.com/rogpeppe/go-internal v1.9.0 // indirect github.com/sirupsen/logrus v1.9.3 github.com/stretchr/testify v1.10.0 - github.com/xanzy/go-gitlab v0.114.0 + gitlab.com/gitlab-org/api/client-go v0.116.0 golang.org/x/oauth2 v0.24.0 golang.org/x/sys v0.28.0 gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c // indirect diff --git a/go.sum b/go.sum index a826d37..a0ea3c9 100644 --- a/go.sum +++ b/go.sum @@ -115,9 +115,9 @@ github.com/twitchyliquid64/golang-asm v0.15.1 h1:SU5vSMR7hnwNxj24w34ZyCi/FmDZTkS github.com/twitchyliquid64/golang-asm v0.15.1/go.mod h1:a1lVb/DtPvCB8fslRZhAngC2+aY1QWCk3Cedj/Gdt08= github.com/ugorji/go/codec v1.2.12 h1:9LC83zGrHhuUA9l16C9AHXAqEV/2wBQ4nkvumAE65EE= github.com/ugorji/go/codec v1.2.12/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= -github.com/xanzy/go-gitlab v0.114.0 h1:0wQr/KBckwrZPfEMjRqpUz0HmsKKON9UhCYv9KDy19M= -github.com/xanzy/go-gitlab v0.114.0/go.mod h1:wKNKh3GkYDMOsGmnfuX+ITCmDuSDWFO0G+C4AygL9RY= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= +gitlab.com/gitlab-org/api/client-go v0.116.0 h1:Dy534gtZPMrnm3fAcmQRMadrcoUyFO4FQ4rXlSAdHAw= +gitlab.com/gitlab-org/api/client-go v0.116.0/go.mod h1:B29OfnZklmaoiR7uHANh9jTyfWEgmXvZLVEnosw2Dx0= golang.org/x/arch v0.0.0-20210923205945-b76863e36670/go.mod h1:5om86z9Hs0C8fWVUuoMHwpExlXzs5Tkyp9hOrfG7pp8= golang.org/x/arch v0.8.0 h1:3wRIsP3pM4yUptoR96otTUOXI367OS0+c9eeRi9doIc= golang.org/x/arch v0.8.0/go.mod h1:FEVrYAQjsQXMVJ1nsMoVVXPZg6p2JE2mx8psSWTDQys= diff --git a/menderqa_pipeline.go b/menderqa_pipeline.go index 63686ea..c1cf1b3 100644 --- a/menderqa_pipeline.go +++ b/menderqa_pipeline.go @@ -11,7 +11,7 @@ import ( "github.com/google/go-github/v28/github" "github.com/sirupsen/logrus" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" clientgitlab "github.com/mendersoftware/integration-test-runner/client/gitlab" ) diff --git a/pullreq_pipeline.go b/pullreq_pipeline.go index a305c37..caadb23 100644 --- a/pullreq_pipeline.go +++ b/pullreq_pipeline.go @@ -9,7 +9,7 @@ import ( "github.com/google/go-github/v28/github" "github.com/sirupsen/logrus" - "github.com/xanzy/go-gitlab" + gitlab "gitlab.com/gitlab-org/api/client-go" clientgitlab "github.com/mendersoftware/integration-test-runner/client/gitlab" "github.com/mendersoftware/integration-test-runner/git"