app-cloudep-member-server/pkg/mock/repository/account.go

186 lines
6.6 KiB
Go

// Code generated by MockGen. DO NOT EDIT.
// Source: ./pkg/domain/repository/account.go
//
// Generated by this command:
//
// mockgen -source=./pkg/domain/repository/account.go -destination=./pkg/mock/repository/account.go -package=mock
//
// Package mock is a generated GoMock package.
package mock
import (
entity "app-cloudep-member-server/pkg/domain/entity"
context "context"
reflect "reflect"
mongo "go.mongodb.org/mongo-driver/mongo"
gomock "go.uber.org/mock/gomock"
)
// MockAccountRepository is a mock of AccountRepository interface.
type MockAccountRepository struct {
ctrl *gomock.Controller
recorder *MockAccountRepositoryMockRecorder
isgomock struct{}
}
// MockAccountRepositoryMockRecorder is the mock recorder for MockAccountRepository.
type MockAccountRepositoryMockRecorder struct {
mock *MockAccountRepository
}
// NewMockAccountRepository creates a new mock instance.
func NewMockAccountRepository(ctrl *gomock.Controller) *MockAccountRepository {
mock := &MockAccountRepository{ctrl: ctrl}
mock.recorder = &MockAccountRepositoryMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockAccountRepository) EXPECT() *MockAccountRepositoryMockRecorder {
return m.recorder
}
// Delete mocks base method.
func (m *MockAccountRepository) Delete(ctx context.Context, id string) (int64, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Delete", ctx, id)
ret0, _ := ret[0].(int64)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Delete indicates an expected call of Delete.
func (mr *MockAccountRepositoryMockRecorder) Delete(ctx, id any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Delete", reflect.TypeOf((*MockAccountRepository)(nil).Delete), ctx, id)
}
// FindOne mocks base method.
func (m *MockAccountRepository) FindOne(ctx context.Context, id string) (*entity.Account, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FindOne", ctx, id)
ret0, _ := ret[0].(*entity.Account)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// FindOne indicates an expected call of FindOne.
func (mr *MockAccountRepositoryMockRecorder) FindOne(ctx, id any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOne", reflect.TypeOf((*MockAccountRepository)(nil).FindOne), ctx, id)
}
// FindOneByAccount mocks base method.
func (m *MockAccountRepository) FindOneByAccount(ctx context.Context, loginID string) (*entity.Account, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "FindOneByAccount", ctx, loginID)
ret0, _ := ret[0].(*entity.Account)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// FindOneByAccount indicates an expected call of FindOneByAccount.
func (mr *MockAccountRepositoryMockRecorder) FindOneByAccount(ctx, loginID any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "FindOneByAccount", reflect.TypeOf((*MockAccountRepository)(nil).FindOneByAccount), ctx, loginID)
}
// Index20241226001UP mocks base method.
func (m *MockAccountRepository) Index20241226001UP(ctx context.Context) (*mongo.Cursor, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Index20241226001UP", ctx)
ret0, _ := ret[0].(*mongo.Cursor)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Index20241226001UP indicates an expected call of Index20241226001UP.
func (mr *MockAccountRepositoryMockRecorder) Index20241226001UP(ctx any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Index20241226001UP", reflect.TypeOf((*MockAccountRepository)(nil).Index20241226001UP), ctx)
}
// Insert mocks base method.
func (m *MockAccountRepository) Insert(ctx context.Context, data *entity.Account) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Insert", ctx, data)
ret0, _ := ret[0].(error)
return ret0
}
// Insert indicates an expected call of Insert.
func (mr *MockAccountRepositoryMockRecorder) Insert(ctx, data any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Insert", reflect.TypeOf((*MockAccountRepository)(nil).Insert), ctx, data)
}
// Update mocks base method.
func (m *MockAccountRepository) Update(ctx context.Context, data *entity.Account) (*mongo.UpdateResult, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Update", ctx, data)
ret0, _ := ret[0].(*mongo.UpdateResult)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Update indicates an expected call of Update.
func (mr *MockAccountRepositoryMockRecorder) Update(ctx, data any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Update", reflect.TypeOf((*MockAccountRepository)(nil).Update), ctx, data)
}
// UpdateTokenByLoginID mocks base method.
func (m *MockAccountRepository) UpdateTokenByLoginID(ctx context.Context, account, token string) error {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "UpdateTokenByLoginID", ctx, account, token)
ret0, _ := ret[0].(error)
return ret0
}
// UpdateTokenByLoginID indicates an expected call of UpdateTokenByLoginID.
func (mr *MockAccountRepositoryMockRecorder) UpdateTokenByLoginID(ctx, account, token any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "UpdateTokenByLoginID", reflect.TypeOf((*MockAccountRepository)(nil).UpdateTokenByLoginID), ctx, account, token)
}
// MockAccountIndexUP is a mock of AccountIndexUP interface.
type MockAccountIndexUP struct {
ctrl *gomock.Controller
recorder *MockAccountIndexUPMockRecorder
isgomock struct{}
}
// MockAccountIndexUPMockRecorder is the mock recorder for MockAccountIndexUP.
type MockAccountIndexUPMockRecorder struct {
mock *MockAccountIndexUP
}
// NewMockAccountIndexUP creates a new mock instance.
func NewMockAccountIndexUP(ctrl *gomock.Controller) *MockAccountIndexUP {
mock := &MockAccountIndexUP{ctrl: ctrl}
mock.recorder = &MockAccountIndexUPMockRecorder{mock}
return mock
}
// EXPECT returns an object that allows the caller to indicate expected use.
func (m *MockAccountIndexUP) EXPECT() *MockAccountIndexUPMockRecorder {
return m.recorder
}
// Index20241226001UP mocks base method.
func (m *MockAccountIndexUP) Index20241226001UP(ctx context.Context) (*mongo.Cursor, error) {
m.ctrl.T.Helper()
ret := m.ctrl.Call(m, "Index20241226001UP", ctx)
ret0, _ := ret[0].(*mongo.Cursor)
ret1, _ := ret[1].(error)
return ret0, ret1
}
// Index20241226001UP indicates an expected call of Index20241226001UP.
func (mr *MockAccountIndexUPMockRecorder) Index20241226001UP(ctx any) *gomock.Call {
mr.mock.ctrl.T.Helper()
return mr.mock.ctrl.RecordCallWithMethodType(mr.mock, "Index20241226001UP", reflect.TypeOf((*MockAccountIndexUP)(nil).Index20241226001UP), ctx)
}