diff options
Diffstat (limited to 'internal/source/gitlab/mock')
-rw-r--r-- | internal/source/gitlab/mock/client_mock.go | 64 | ||||
-rw-r--r-- | internal/source/gitlab/mock/client_stub.go | 8 |
2 files changed, 72 insertions, 0 deletions
diff --git a/internal/source/gitlab/mock/client_mock.go b/internal/source/gitlab/mock/client_mock.go new file mode 100644 index 00000000..6f78b01b --- /dev/null +++ b/internal/source/gitlab/mock/client_mock.go @@ -0,0 +1,64 @@ +// Code generated by MockGen. DO NOT EDIT. +// Source: internal/source/gitlab/mock/client_stub.go + +// Package mock is a generated GoMock package. +package mock + +import ( + context "context" + reflect "reflect" + + gomock "github.com/golang/mock/gomock" + api "gitlab.com/gitlab-org/gitlab-pages/internal/source/gitlab/api" +) + +// MockClientStub is a mock of ClientStub interface. +type MockClientStub struct { + ctrl *gomock.Controller + recorder *MockClientStubMockRecorder +} + +// MockClientStubMockRecorder is the mock recorder for MockClientStub. +type MockClientStubMockRecorder struct { + mock *MockClientStub +} + +// NewMockClientStub creates a new mock instance. +func NewMockClientStub(ctrl *gomock.Controller) *MockClientStub { + mock := &MockClientStub{ctrl: ctrl} + mock.recorder = &MockClientStubMockRecorder{mock} + return mock +} + +// EXPECT returns an object that allows the caller to indicate expected use. +func (m *MockClientStub) EXPECT() *MockClientStubMockRecorder { + return m.recorder +} + +// GetLookup mocks base method. +func (m *MockClientStub) GetLookup(ctx context.Context, domain string) api.Lookup { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "GetLookup", ctx, domain) + ret0, _ := ret[0].(api.Lookup) + return ret0 +} + +// GetLookup indicates an expected call of GetLookup. +func (mr *MockClientStubMockRecorder) GetLookup(ctx, domain interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "GetLookup", reflect.TypeOf((*MockClientStub)(nil).GetLookup), ctx, domain) +} + +// Resolve mocks base method. +func (m *MockClientStub) Resolve(ctx context.Context, domain string) *api.Lookup { + m.ctrl.T.Helper() + ret := m.ctrl.Call(m, "Resolve", ctx, domain) + ret0, _ := ret[0].(*api.Lookup) + return ret0 +} + +// Resolve indicates an expected call of Resolve. +func (mr *MockClientStubMockRecorder) Resolve(ctx, domain interface{}) *gomock.Call { + mr.mock.ctrl.T.Helper() + return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Resolve", reflect.TypeOf((*MockClientStub)(nil).Resolve), ctx, domain) +} diff --git a/internal/source/gitlab/mock/client_stub.go b/internal/source/gitlab/mock/client_stub.go new file mode 100644 index 00000000..5b201da2 --- /dev/null +++ b/internal/source/gitlab/mock/client_stub.go @@ -0,0 +1,8 @@ +package mock + +import "gitlab.com/gitlab-org/gitlab-pages/internal/source/gitlab/api" + +type ClientStub interface { + api.Client + api.Resolver +} |