Documentation
¶
Index ¶
- type ActivityService
- type ActivityService_Expecter
- type ActivityService_Log_Call
- type CachedRepository
- type CachedRepository_Expecter
- type CachedRepository_GetBySlug_Call
- func (_c *CachedRepository_GetBySlug_Call) Return(_a0 group.Group, _a1 error) *CachedRepository_GetBySlug_Call
- func (_c *CachedRepository_GetBySlug_Call) Run(run func(ctx context.Context, slug string)) *CachedRepository_GetBySlug_Call
- func (_c *CachedRepository_GetBySlug_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *CachedRepository_GetBySlug_Call
- type RelationService
- func (_m *RelationService) CheckPermission(ctx context.Context, usr user.User, resourceNS namespace.Namespace, ...) (bool, error)
- func (_m *RelationService) Create(ctx context.Context, rel relation.RelationV2) (relation.RelationV2, error)
- func (_m *RelationService) Delete(ctx context.Context, rel relation.Relation) error
- func (_m *RelationService) EXPECT() *RelationService_Expecter
- type RelationService_CheckPermission_Call
- func (_c *RelationService_CheckPermission_Call) Return(_a0 bool, _a1 error) *RelationService_CheckPermission_Call
- func (_c *RelationService_CheckPermission_Call) Run(...) *RelationService_CheckPermission_Call
- func (_c *RelationService_CheckPermission_Call) RunAndReturn(...) *RelationService_CheckPermission_Call
- type RelationService_Create_Call
- func (_c *RelationService_Create_Call) Return(_a0 relation.RelationV2, _a1 error) *RelationService_Create_Call
- func (_c *RelationService_Create_Call) Run(run func(ctx context.Context, rel relation.RelationV2)) *RelationService_Create_Call
- func (_c *RelationService_Create_Call) RunAndReturn(run func(context.Context, relation.RelationV2) (relation.RelationV2, error)) *RelationService_Create_Call
- type RelationService_Delete_Call
- func (_c *RelationService_Delete_Call) Return(_a0 error) *RelationService_Delete_Call
- func (_c *RelationService_Delete_Call) Run(run func(ctx context.Context, rel relation.Relation)) *RelationService_Delete_Call
- func (_c *RelationService_Delete_Call) RunAndReturn(run func(context.Context, relation.Relation) error) *RelationService_Delete_Call
- type RelationService_Expecter
- func (_e *RelationService_Expecter) CheckPermission(ctx interface{}, usr interface{}, resourceNS interface{}, ...) *RelationService_CheckPermission_Call
- func (_e *RelationService_Expecter) Create(ctx interface{}, rel interface{}) *RelationService_Create_Call
- func (_e *RelationService_Expecter) Delete(ctx interface{}, rel interface{}) *RelationService_Delete_Call
- type Repository
- func (_m *Repository) Create(ctx context.Context, grp group.Group) (group.Group, error)
- func (_m *Repository) EXPECT() *Repository_Expecter
- func (_m *Repository) GetByID(ctx context.Context, id string) (group.Group, error)
- func (_m *Repository) GetByIDs(ctx context.Context, groupIDs []string) ([]group.Group, error)
- func (_m *Repository) GetBySlug(ctx context.Context, slug string) (group.Group, error)
- func (_m *Repository) List(ctx context.Context, flt group.Filter) ([]group.Group, error)
- func (_m *Repository) ListGroupRelations(ctx context.Context, objectId string, subjectType string, role string) ([]relation.RelationV2, error)
- func (_m *Repository) ListUserGroups(ctx context.Context, userId string, roleId string) ([]group.Group, error)
- func (_m *Repository) UpdateByID(ctx context.Context, toUpdate group.Group) (group.Group, error)
- func (_m *Repository) UpdateBySlug(ctx context.Context, toUpdate group.Group) (group.Group, error)
- type Repository_Create_Call
- func (_c *Repository_Create_Call) Return(_a0 group.Group, _a1 error) *Repository_Create_Call
- func (_c *Repository_Create_Call) Run(run func(ctx context.Context, grp group.Group)) *Repository_Create_Call
- func (_c *Repository_Create_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_Create_Call
- type Repository_Expecter
- func (_e *Repository_Expecter) Create(ctx interface{}, grp interface{}) *Repository_Create_Call
- func (_e *Repository_Expecter) GetByID(ctx interface{}, id interface{}) *Repository_GetByID_Call
- func (_e *Repository_Expecter) GetByIDs(ctx interface{}, groupIDs interface{}) *Repository_GetByIDs_Call
- func (_e *Repository_Expecter) GetBySlug(ctx interface{}, slug interface{}) *Repository_GetBySlug_Call
- func (_e *Repository_Expecter) List(ctx interface{}, flt interface{}) *Repository_List_Call
- func (_e *Repository_Expecter) ListGroupRelations(ctx interface{}, objectId interface{}, subjectType interface{}, ...) *Repository_ListGroupRelations_Call
- func (_e *Repository_Expecter) ListUserGroups(ctx interface{}, userId interface{}, roleId interface{}) *Repository_ListUserGroups_Call
- func (_e *Repository_Expecter) UpdateByID(ctx interface{}, toUpdate interface{}) *Repository_UpdateByID_Call
- func (_e *Repository_Expecter) UpdateBySlug(ctx interface{}, toUpdate interface{}) *Repository_UpdateBySlug_Call
- type Repository_GetByID_Call
- func (_c *Repository_GetByID_Call) Return(_a0 group.Group, _a1 error) *Repository_GetByID_Call
- func (_c *Repository_GetByID_Call) Run(run func(ctx context.Context, id string)) *Repository_GetByID_Call
- func (_c *Repository_GetByID_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *Repository_GetByID_Call
- type Repository_GetByIDs_Call
- func (_c *Repository_GetByIDs_Call) Return(_a0 []group.Group, _a1 error) *Repository_GetByIDs_Call
- func (_c *Repository_GetByIDs_Call) Run(run func(ctx context.Context, groupIDs []string)) *Repository_GetByIDs_Call
- func (_c *Repository_GetByIDs_Call) RunAndReturn(run func(context.Context, []string) ([]group.Group, error)) *Repository_GetByIDs_Call
- type Repository_GetBySlug_Call
- func (_c *Repository_GetBySlug_Call) Return(_a0 group.Group, _a1 error) *Repository_GetBySlug_Call
- func (_c *Repository_GetBySlug_Call) Run(run func(ctx context.Context, slug string)) *Repository_GetBySlug_Call
- func (_c *Repository_GetBySlug_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *Repository_GetBySlug_Call
- type Repository_ListGroupRelations_Call
- func (_c *Repository_ListGroupRelations_Call) Return(_a0 []relation.RelationV2, _a1 error) *Repository_ListGroupRelations_Call
- func (_c *Repository_ListGroupRelations_Call) Run(...) *Repository_ListGroupRelations_Call
- func (_c *Repository_ListGroupRelations_Call) RunAndReturn(...) *Repository_ListGroupRelations_Call
- type Repository_ListUserGroups_Call
- func (_c *Repository_ListUserGroups_Call) Return(_a0 []group.Group, _a1 error) *Repository_ListUserGroups_Call
- func (_c *Repository_ListUserGroups_Call) Run(run func(ctx context.Context, userId string, roleId string)) *Repository_ListUserGroups_Call
- func (_c *Repository_ListUserGroups_Call) RunAndReturn(run func(context.Context, string, string) ([]group.Group, error)) *Repository_ListUserGroups_Call
- type Repository_List_Call
- func (_c *Repository_List_Call) Return(_a0 []group.Group, _a1 error) *Repository_List_Call
- func (_c *Repository_List_Call) Run(run func(ctx context.Context, flt group.Filter)) *Repository_List_Call
- func (_c *Repository_List_Call) RunAndReturn(run func(context.Context, group.Filter) ([]group.Group, error)) *Repository_List_Call
- type Repository_UpdateByID_Call
- func (_c *Repository_UpdateByID_Call) Return(_a0 group.Group, _a1 error) *Repository_UpdateByID_Call
- func (_c *Repository_UpdateByID_Call) Run(run func(ctx context.Context, toUpdate group.Group)) *Repository_UpdateByID_Call
- func (_c *Repository_UpdateByID_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_UpdateByID_Call
- type Repository_UpdateBySlug_Call
- func (_c *Repository_UpdateBySlug_Call) Return(_a0 group.Group, _a1 error) *Repository_UpdateBySlug_Call
- func (_c *Repository_UpdateBySlug_Call) Run(run func(ctx context.Context, toUpdate group.Group)) *Repository_UpdateBySlug_Call
- func (_c *Repository_UpdateBySlug_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_UpdateBySlug_Call
- type UserService
- func (_m *UserService) EXPECT() *UserService_Expecter
- func (_m *UserService) FetchCurrentUser(ctx context.Context) (user.User, error)
- func (_m *UserService) GetByID(ctx context.Context, id string) (user.User, error)
- func (_m *UserService) GetByIDs(ctx context.Context, userIDs []string) ([]user.User, error)
- type UserService_Expecter
- func (_e *UserService_Expecter) FetchCurrentUser(ctx interface{}) *UserService_FetchCurrentUser_Call
- func (_e *UserService_Expecter) GetByID(ctx interface{}, id interface{}) *UserService_GetByID_Call
- func (_e *UserService_Expecter) GetByIDs(ctx interface{}, userIDs interface{}) *UserService_GetByIDs_Call
- type UserService_FetchCurrentUser_Call
- func (_c *UserService_FetchCurrentUser_Call) Return(_a0 user.User, _a1 error) *UserService_FetchCurrentUser_Call
- func (_c *UserService_FetchCurrentUser_Call) Run(run func(ctx context.Context)) *UserService_FetchCurrentUser_Call
- func (_c *UserService_FetchCurrentUser_Call) RunAndReturn(run func(context.Context) (user.User, error)) *UserService_FetchCurrentUser_Call
- type UserService_GetByID_Call
- func (_c *UserService_GetByID_Call) Return(_a0 user.User, _a1 error) *UserService_GetByID_Call
- func (_c *UserService_GetByID_Call) Run(run func(ctx context.Context, id string)) *UserService_GetByID_Call
- func (_c *UserService_GetByID_Call) RunAndReturn(run func(context.Context, string) (user.User, error)) *UserService_GetByID_Call
- type UserService_GetByIDs_Call
- func (_c *UserService_GetByIDs_Call) Return(_a0 []user.User, _a1 error) *UserService_GetByIDs_Call
- func (_c *UserService_GetByIDs_Call) Run(run func(ctx context.Context, userIDs []string)) *UserService_GetByIDs_Call
- func (_c *UserService_GetByIDs_Call) RunAndReturn(run func(context.Context, []string) ([]user.User, error)) *UserService_GetByIDs_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ActivityService ¶
ActivityService is an autogenerated mock type for the ActivityService type
func NewActivityService ¶
func NewActivityService(t interface { mock.TestingT Cleanup(func()) }) *ActivityService
NewActivityService creates a new instance of ActivityService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*ActivityService) EXPECT ¶
func (_m *ActivityService) EXPECT() *ActivityService_Expecter
type ActivityService_Expecter ¶
type ActivityService_Expecter struct {
// contains filtered or unexported fields
}
func (*ActivityService_Expecter) Log ¶
func (_e *ActivityService_Expecter) Log(ctx interface{}, action interface{}, actor interface{}, data interface{}) *ActivityService_Log_Call
Log is a helper method to define mock.On call
- ctx context.Context
- action string
- actor activity.Actor
- data interface{}
type ActivityService_Log_Call ¶
ActivityService_Log_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Log'
func (*ActivityService_Log_Call) Return ¶
func (_c *ActivityService_Log_Call) Return(_a0 error) *ActivityService_Log_Call
func (*ActivityService_Log_Call) Run ¶
func (_c *ActivityService_Log_Call) Run(run func(ctx context.Context, action string, actor activity.Actor, data interface{})) *ActivityService_Log_Call
func (*ActivityService_Log_Call) RunAndReturn ¶
func (_c *ActivityService_Log_Call) RunAndReturn(run func(context.Context, string, activity.Actor, interface{}) error) *ActivityService_Log_Call
type CachedRepository ¶
CachedRepository is an autogenerated mock type for the CachedRepository type
func NewCachedRepository ¶
func NewCachedRepository(t interface { mock.TestingT Cleanup(func()) }) *CachedRepository
NewCachedRepository creates a new instance of CachedRepository. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*CachedRepository) EXPECT ¶
func (_m *CachedRepository) EXPECT() *CachedRepository_Expecter
type CachedRepository_Expecter ¶
type CachedRepository_Expecter struct {
// contains filtered or unexported fields
}
func (*CachedRepository_Expecter) GetBySlug ¶
func (_e *CachedRepository_Expecter) GetBySlug(ctx interface{}, slug interface{}) *CachedRepository_GetBySlug_Call
GetBySlug is a helper method to define mock.On call
- ctx context.Context
- slug string
type CachedRepository_GetBySlug_Call ¶
CachedRepository_GetBySlug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetBySlug'
func (*CachedRepository_GetBySlug_Call) Return ¶
func (_c *CachedRepository_GetBySlug_Call) Return(_a0 group.Group, _a1 error) *CachedRepository_GetBySlug_Call
func (*CachedRepository_GetBySlug_Call) Run ¶
func (_c *CachedRepository_GetBySlug_Call) Run(run func(ctx context.Context, slug string)) *CachedRepository_GetBySlug_Call
func (*CachedRepository_GetBySlug_Call) RunAndReturn ¶
func (_c *CachedRepository_GetBySlug_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *CachedRepository_GetBySlug_Call
type RelationService ¶
RelationService is an autogenerated mock type for the RelationService type
func NewRelationService ¶
func NewRelationService(t interface { mock.TestingT Cleanup(func()) }) *RelationService
NewRelationService creates a new instance of RelationService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*RelationService) CheckPermission ¶
func (_m *RelationService) CheckPermission(ctx context.Context, usr user.User, resourceNS namespace.Namespace, resourceIdxa string, _a4 action.Action) (bool, error)
CheckPermission provides a mock function with given fields: ctx, usr, resourceNS, resourceIdxa, _a4
func (*RelationService) Create ¶
func (_m *RelationService) Create(ctx context.Context, rel relation.RelationV2) (relation.RelationV2, error)
Create provides a mock function with given fields: ctx, rel
func (*RelationService) EXPECT ¶
func (_m *RelationService) EXPECT() *RelationService_Expecter
type RelationService_CheckPermission_Call ¶
RelationService_CheckPermission_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CheckPermission'
func (*RelationService_CheckPermission_Call) Return ¶
func (_c *RelationService_CheckPermission_Call) Return(_a0 bool, _a1 error) *RelationService_CheckPermission_Call
func (*RelationService_CheckPermission_Call) RunAndReturn ¶
type RelationService_Create_Call ¶
RelationService_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*RelationService_Create_Call) Return ¶
func (_c *RelationService_Create_Call) Return(_a0 relation.RelationV2, _a1 error) *RelationService_Create_Call
func (*RelationService_Create_Call) Run ¶
func (_c *RelationService_Create_Call) Run(run func(ctx context.Context, rel relation.RelationV2)) *RelationService_Create_Call
func (*RelationService_Create_Call) RunAndReturn ¶
func (_c *RelationService_Create_Call) RunAndReturn(run func(context.Context, relation.RelationV2) (relation.RelationV2, error)) *RelationService_Create_Call
type RelationService_Delete_Call ¶
RelationService_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*RelationService_Delete_Call) Return ¶
func (_c *RelationService_Delete_Call) Return(_a0 error) *RelationService_Delete_Call
func (*RelationService_Delete_Call) Run ¶
func (_c *RelationService_Delete_Call) Run(run func(ctx context.Context, rel relation.Relation)) *RelationService_Delete_Call
func (*RelationService_Delete_Call) RunAndReturn ¶
func (_c *RelationService_Delete_Call) RunAndReturn(run func(context.Context, relation.Relation) error) *RelationService_Delete_Call
type RelationService_Expecter ¶
type RelationService_Expecter struct {
// contains filtered or unexported fields
}
func (*RelationService_Expecter) CheckPermission ¶
func (_e *RelationService_Expecter) CheckPermission(ctx interface{}, usr interface{}, resourceNS interface{}, resourceIdxa interface{}, _a4 interface{}) *RelationService_CheckPermission_Call
CheckPermission is a helper method to define mock.On call
- ctx context.Context
- usr user.User
- resourceNS namespace.Namespace
- resourceIdxa string
- _a4 action.Action
func (*RelationService_Expecter) Create ¶
func (_e *RelationService_Expecter) Create(ctx interface{}, rel interface{}) *RelationService_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- rel relation.RelationV2
func (*RelationService_Expecter) Delete ¶
func (_e *RelationService_Expecter) Delete(ctx interface{}, rel interface{}) *RelationService_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- rel relation.Relation
type Repository ¶
Repository is an autogenerated mock type for the Repository type
func NewRepository ¶
func NewRepository(t interface { mock.TestingT Cleanup(func()) }) *Repository
NewRepository creates a new instance of Repository. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*Repository) EXPECT ¶
func (_m *Repository) EXPECT() *Repository_Expecter
func (*Repository) ListGroupRelations ¶
func (_m *Repository) ListGroupRelations(ctx context.Context, objectId string, subjectType string, role string) ([]relation.RelationV2, error)
ListGroupRelations provides a mock function with given fields: ctx, objectId, subjectType, role
func (*Repository) ListUserGroups ¶
func (_m *Repository) ListUserGroups(ctx context.Context, userId string, roleId string) ([]group.Group, error)
ListUserGroups provides a mock function with given fields: ctx, userId, roleId
func (*Repository) UpdateByID ¶
UpdateByID provides a mock function with given fields: ctx, toUpdate
func (*Repository) UpdateBySlug ¶
UpdateBySlug provides a mock function with given fields: ctx, toUpdate
type Repository_Create_Call ¶
Repository_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*Repository_Create_Call) Return ¶
func (_c *Repository_Create_Call) Return(_a0 group.Group, _a1 error) *Repository_Create_Call
func (*Repository_Create_Call) Run ¶
func (_c *Repository_Create_Call) Run(run func(ctx context.Context, grp group.Group)) *Repository_Create_Call
func (*Repository_Create_Call) RunAndReturn ¶
func (_c *Repository_Create_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_Create_Call
type Repository_Expecter ¶
type Repository_Expecter struct {
// contains filtered or unexported fields
}
func (*Repository_Expecter) Create ¶
func (_e *Repository_Expecter) Create(ctx interface{}, grp interface{}) *Repository_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- grp group.Group
func (*Repository_Expecter) GetByID ¶
func (_e *Repository_Expecter) GetByID(ctx interface{}, id interface{}) *Repository_GetByID_Call
GetByID is a helper method to define mock.On call
- ctx context.Context
- id string
func (*Repository_Expecter) GetByIDs ¶
func (_e *Repository_Expecter) GetByIDs(ctx interface{}, groupIDs interface{}) *Repository_GetByIDs_Call
GetByIDs is a helper method to define mock.On call
- ctx context.Context
- groupIDs []string
func (*Repository_Expecter) GetBySlug ¶
func (_e *Repository_Expecter) GetBySlug(ctx interface{}, slug interface{}) *Repository_GetBySlug_Call
GetBySlug is a helper method to define mock.On call
- ctx context.Context
- slug string
func (*Repository_Expecter) List ¶
func (_e *Repository_Expecter) List(ctx interface{}, flt interface{}) *Repository_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- flt group.Filter
func (*Repository_Expecter) ListGroupRelations ¶
func (_e *Repository_Expecter) ListGroupRelations(ctx interface{}, objectId interface{}, subjectType interface{}, role interface{}) *Repository_ListGroupRelations_Call
ListGroupRelations is a helper method to define mock.On call
- ctx context.Context
- objectId string
- subjectType string
- role string
func (*Repository_Expecter) ListUserGroups ¶
func (_e *Repository_Expecter) ListUserGroups(ctx interface{}, userId interface{}, roleId interface{}) *Repository_ListUserGroups_Call
ListUserGroups is a helper method to define mock.On call
- ctx context.Context
- userId string
- roleId string
func (*Repository_Expecter) UpdateByID ¶
func (_e *Repository_Expecter) UpdateByID(ctx interface{}, toUpdate interface{}) *Repository_UpdateByID_Call
UpdateByID is a helper method to define mock.On call
- ctx context.Context
- toUpdate group.Group
func (*Repository_Expecter) UpdateBySlug ¶
func (_e *Repository_Expecter) UpdateBySlug(ctx interface{}, toUpdate interface{}) *Repository_UpdateBySlug_Call
UpdateBySlug is a helper method to define mock.On call
- ctx context.Context
- toUpdate group.Group
type Repository_GetByID_Call ¶
Repository_GetByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByID'
func (*Repository_GetByID_Call) Return ¶
func (_c *Repository_GetByID_Call) Return(_a0 group.Group, _a1 error) *Repository_GetByID_Call
func (*Repository_GetByID_Call) Run ¶
func (_c *Repository_GetByID_Call) Run(run func(ctx context.Context, id string)) *Repository_GetByID_Call
func (*Repository_GetByID_Call) RunAndReturn ¶
func (_c *Repository_GetByID_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *Repository_GetByID_Call
type Repository_GetByIDs_Call ¶
Repository_GetByIDs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByIDs'
func (*Repository_GetByIDs_Call) Return ¶
func (_c *Repository_GetByIDs_Call) Return(_a0 []group.Group, _a1 error) *Repository_GetByIDs_Call
func (*Repository_GetByIDs_Call) Run ¶
func (_c *Repository_GetByIDs_Call) Run(run func(ctx context.Context, groupIDs []string)) *Repository_GetByIDs_Call
func (*Repository_GetByIDs_Call) RunAndReturn ¶
func (_c *Repository_GetByIDs_Call) RunAndReturn(run func(context.Context, []string) ([]group.Group, error)) *Repository_GetByIDs_Call
type Repository_GetBySlug_Call ¶
Repository_GetBySlug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetBySlug'
func (*Repository_GetBySlug_Call) Return ¶
func (_c *Repository_GetBySlug_Call) Return(_a0 group.Group, _a1 error) *Repository_GetBySlug_Call
func (*Repository_GetBySlug_Call) Run ¶
func (_c *Repository_GetBySlug_Call) Run(run func(ctx context.Context, slug string)) *Repository_GetBySlug_Call
func (*Repository_GetBySlug_Call) RunAndReturn ¶
func (_c *Repository_GetBySlug_Call) RunAndReturn(run func(context.Context, string) (group.Group, error)) *Repository_GetBySlug_Call
type Repository_ListGroupRelations_Call ¶
Repository_ListGroupRelations_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListGroupRelations'
func (*Repository_ListGroupRelations_Call) Return ¶
func (_c *Repository_ListGroupRelations_Call) Return(_a0 []relation.RelationV2, _a1 error) *Repository_ListGroupRelations_Call
func (*Repository_ListGroupRelations_Call) Run ¶
func (_c *Repository_ListGroupRelations_Call) Run(run func(ctx context.Context, objectId string, subjectType string, role string)) *Repository_ListGroupRelations_Call
func (*Repository_ListGroupRelations_Call) RunAndReturn ¶
func (_c *Repository_ListGroupRelations_Call) RunAndReturn(run func(context.Context, string, string, string) ([]relation.RelationV2, error)) *Repository_ListGroupRelations_Call
type Repository_ListUserGroups_Call ¶
Repository_ListUserGroups_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ListUserGroups'
func (*Repository_ListUserGroups_Call) Return ¶
func (_c *Repository_ListUserGroups_Call) Return(_a0 []group.Group, _a1 error) *Repository_ListUserGroups_Call
func (*Repository_ListUserGroups_Call) Run ¶
func (_c *Repository_ListUserGroups_Call) Run(run func(ctx context.Context, userId string, roleId string)) *Repository_ListUserGroups_Call
func (*Repository_ListUserGroups_Call) RunAndReturn ¶
func (_c *Repository_ListUserGroups_Call) RunAndReturn(run func(context.Context, string, string) ([]group.Group, error)) *Repository_ListUserGroups_Call
type Repository_List_Call ¶
Repository_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*Repository_List_Call) Return ¶
func (_c *Repository_List_Call) Return(_a0 []group.Group, _a1 error) *Repository_List_Call
func (*Repository_List_Call) Run ¶
func (_c *Repository_List_Call) Run(run func(ctx context.Context, flt group.Filter)) *Repository_List_Call
func (*Repository_List_Call) RunAndReturn ¶
func (_c *Repository_List_Call) RunAndReturn(run func(context.Context, group.Filter) ([]group.Group, error)) *Repository_List_Call
type Repository_UpdateByID_Call ¶
Repository_UpdateByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateByID'
func (*Repository_UpdateByID_Call) Return ¶
func (_c *Repository_UpdateByID_Call) Return(_a0 group.Group, _a1 error) *Repository_UpdateByID_Call
func (*Repository_UpdateByID_Call) Run ¶
func (_c *Repository_UpdateByID_Call) Run(run func(ctx context.Context, toUpdate group.Group)) *Repository_UpdateByID_Call
func (*Repository_UpdateByID_Call) RunAndReturn ¶
func (_c *Repository_UpdateByID_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_UpdateByID_Call
type Repository_UpdateBySlug_Call ¶
Repository_UpdateBySlug_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateBySlug'
func (*Repository_UpdateBySlug_Call) Return ¶
func (_c *Repository_UpdateBySlug_Call) Return(_a0 group.Group, _a1 error) *Repository_UpdateBySlug_Call
func (*Repository_UpdateBySlug_Call) Run ¶
func (_c *Repository_UpdateBySlug_Call) Run(run func(ctx context.Context, toUpdate group.Group)) *Repository_UpdateBySlug_Call
func (*Repository_UpdateBySlug_Call) RunAndReturn ¶
func (_c *Repository_UpdateBySlug_Call) RunAndReturn(run func(context.Context, group.Group) (group.Group, error)) *Repository_UpdateBySlug_Call
type UserService ¶
UserService is an autogenerated mock type for the UserService type
func NewUserService ¶
func NewUserService(t interface { mock.TestingT Cleanup(func()) }) *UserService
NewUserService creates a new instance of UserService. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations. The first argument is typically a *testing.T value.
func (*UserService) EXPECT ¶
func (_m *UserService) EXPECT() *UserService_Expecter
func (*UserService) FetchCurrentUser ¶
FetchCurrentUser provides a mock function with given fields: ctx
type UserService_Expecter ¶
type UserService_Expecter struct {
// contains filtered or unexported fields
}
func (*UserService_Expecter) FetchCurrentUser ¶
func (_e *UserService_Expecter) FetchCurrentUser(ctx interface{}) *UserService_FetchCurrentUser_Call
FetchCurrentUser is a helper method to define mock.On call
- ctx context.Context
func (*UserService_Expecter) GetByID ¶
func (_e *UserService_Expecter) GetByID(ctx interface{}, id interface{}) *UserService_GetByID_Call
GetByID is a helper method to define mock.On call
- ctx context.Context
- id string
func (*UserService_Expecter) GetByIDs ¶
func (_e *UserService_Expecter) GetByIDs(ctx interface{}, userIDs interface{}) *UserService_GetByIDs_Call
GetByIDs is a helper method to define mock.On call
- ctx context.Context
- userIDs []string
type UserService_FetchCurrentUser_Call ¶
UserService_FetchCurrentUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FetchCurrentUser'
func (*UserService_FetchCurrentUser_Call) Return ¶
func (_c *UserService_FetchCurrentUser_Call) Return(_a0 user.User, _a1 error) *UserService_FetchCurrentUser_Call
func (*UserService_FetchCurrentUser_Call) Run ¶
func (_c *UserService_FetchCurrentUser_Call) Run(run func(ctx context.Context)) *UserService_FetchCurrentUser_Call
func (*UserService_FetchCurrentUser_Call) RunAndReturn ¶
func (_c *UserService_FetchCurrentUser_Call) RunAndReturn(run func(context.Context) (user.User, error)) *UserService_FetchCurrentUser_Call
type UserService_GetByID_Call ¶
UserService_GetByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByID'
func (*UserService_GetByID_Call) Return ¶
func (_c *UserService_GetByID_Call) Return(_a0 user.User, _a1 error) *UserService_GetByID_Call
func (*UserService_GetByID_Call) Run ¶
func (_c *UserService_GetByID_Call) Run(run func(ctx context.Context, id string)) *UserService_GetByID_Call
func (*UserService_GetByID_Call) RunAndReturn ¶
func (_c *UserService_GetByID_Call) RunAndReturn(run func(context.Context, string) (user.User, error)) *UserService_GetByID_Call
type UserService_GetByIDs_Call ¶
UserService_GetByIDs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByIDs'
func (*UserService_GetByIDs_Call) Return ¶
func (_c *UserService_GetByIDs_Call) Return(_a0 []user.User, _a1 error) *UserService_GetByIDs_Call
func (*UserService_GetByIDs_Call) Run ¶
func (_c *UserService_GetByIDs_Call) Run(run func(ctx context.Context, userIDs []string)) *UserService_GetByIDs_Call
func (*UserService_GetByIDs_Call) RunAndReturn ¶
func (_c *UserService_GetByIDs_Call) RunAndReturn(run func(context.Context, []string) ([]user.User, error)) *UserService_GetByIDs_Call