Documentation
¶
Index ¶
- type AuditRecordRepository
- type AuditRecordRepository_Create_Call
- func (_c *AuditRecordRepository_Create_Call) Return(_a0 models.AuditRecord, _a1 error) *AuditRecordRepository_Create_Call
- func (_c *AuditRecordRepository_Create_Call) Run(run func(ctx context.Context, auditRecord models.AuditRecord)) *AuditRecordRepository_Create_Call
- func (_c *AuditRecordRepository_Create_Call) RunAndReturn(run func(context.Context, models.AuditRecord) (models.AuditRecord, error)) *AuditRecordRepository_Create_Call
- type AuditRecordRepository_Expecter
- type OrganizationService
- type OrganizationService_Expecter
- type OrganizationService_GetRaw_Call
- func (_c *OrganizationService_GetRaw_Call) Return(_a0 organization.Organization, _a1 error) *OrganizationService_GetRaw_Call
- func (_c *OrganizationService_GetRaw_Call) Run(run func(ctx context.Context, id string)) *OrganizationService_GetRaw_Call
- func (_c *OrganizationService_GetRaw_Call) RunAndReturn(run func(context.Context, string) (organization.Organization, error)) *OrganizationService_GetRaw_Call
- type PolicyService
- func (_m *PolicyService) Create(ctx context.Context, pol policy.Policy) (policy.Policy, error)
- func (_m *PolicyService) Delete(ctx context.Context, id string) error
- func (_m *PolicyService) EXPECT() *PolicyService_Expecter
- func (_m *PolicyService) List(ctx context.Context, flt policy.Filter) ([]policy.Policy, error)
- type PolicyService_Create_Call
- func (_c *PolicyService_Create_Call) Return(_a0 policy.Policy, _a1 error) *PolicyService_Create_Call
- func (_c *PolicyService_Create_Call) Run(run func(ctx context.Context, pol policy.Policy)) *PolicyService_Create_Call
- func (_c *PolicyService_Create_Call) RunAndReturn(run func(context.Context, policy.Policy) (policy.Policy, error)) *PolicyService_Create_Call
- type PolicyService_Delete_Call
- func (_c *PolicyService_Delete_Call) Return(_a0 error) *PolicyService_Delete_Call
- func (_c *PolicyService_Delete_Call) Run(run func(ctx context.Context, id string)) *PolicyService_Delete_Call
- func (_c *PolicyService_Delete_Call) RunAndReturn(run func(context.Context, string) error) *PolicyService_Delete_Call
- type PolicyService_Expecter
- func (_e *PolicyService_Expecter) Create(ctx interface{}, pol interface{}) *PolicyService_Create_Call
- func (_e *PolicyService_Expecter) Delete(ctx interface{}, id interface{}) *PolicyService_Delete_Call
- func (_e *PolicyService_Expecter) List(ctx interface{}, flt interface{}) *PolicyService_List_Call
- type PolicyService_List_Call
- func (_c *PolicyService_List_Call) Return(_a0 []policy.Policy, _a1 error) *PolicyService_List_Call
- func (_c *PolicyService_List_Call) Run(run func(ctx context.Context, flt policy.Filter)) *PolicyService_List_Call
- func (_c *PolicyService_List_Call) RunAndReturn(run func(context.Context, policy.Filter) ([]policy.Policy, error)) *PolicyService_List_Call
- type Repository
- func (_m *Repository) CountActive(ctx context.Context, userID string, orgID string) (int64, error)
- func (_m *Repository) Create(ctx context.Context, pat models.PAT) (models.PAT, error)
- func (_m *Repository) Delete(ctx context.Context, id string) error
- func (_m *Repository) EXPECT() *Repository_Expecter
- func (_m *Repository) GetByID(ctx context.Context, id string) (models.PAT, error)
- func (_m *Repository) GetBySecretHash(ctx context.Context, secretHash string) (models.PAT, error)
- func (_m *Repository) IsTitleAvailable(ctx context.Context, userID string, orgID string, title string) (bool, error)
- func (_m *Repository) List(ctx context.Context, userID string, orgID string, query *rql.Query) (models.PATList, error)
- func (_m *Repository) Regenerate(ctx context.Context, id string, secretHash string, expiresAt time.Time) (models.PAT, error)
- func (_m *Repository) Update(ctx context.Context, pat models.PAT) (models.PAT, error)
- func (_m *Repository) UpdateLastUsedAt(ctx context.Context, id string, at time.Time) error
- type Repository_CountActive_Call
- func (_c *Repository_CountActive_Call) Return(_a0 int64, _a1 error) *Repository_CountActive_Call
- func (_c *Repository_CountActive_Call) Run(run func(ctx context.Context, userID string, orgID string)) *Repository_CountActive_Call
- func (_c *Repository_CountActive_Call) RunAndReturn(run func(context.Context, string, string) (int64, error)) *Repository_CountActive_Call
- type Repository_Create_Call
- func (_c *Repository_Create_Call) Return(_a0 models.PAT, _a1 error) *Repository_Create_Call
- func (_c *Repository_Create_Call) Run(run func(ctx context.Context, pat models.PAT)) *Repository_Create_Call
- func (_c *Repository_Create_Call) RunAndReturn(run func(context.Context, models.PAT) (models.PAT, error)) *Repository_Create_Call
- type Repository_Delete_Call
- type Repository_Expecter
- func (_e *Repository_Expecter) CountActive(ctx interface{}, userID interface{}, orgID interface{}) *Repository_CountActive_Call
- func (_e *Repository_Expecter) Create(ctx interface{}, pat interface{}) *Repository_Create_Call
- func (_e *Repository_Expecter) Delete(ctx interface{}, id interface{}) *Repository_Delete_Call
- func (_e *Repository_Expecter) GetByID(ctx interface{}, id interface{}) *Repository_GetByID_Call
- func (_e *Repository_Expecter) GetBySecretHash(ctx interface{}, secretHash interface{}) *Repository_GetBySecretHash_Call
- func (_e *Repository_Expecter) IsTitleAvailable(ctx interface{}, userID interface{}, orgID interface{}, title interface{}) *Repository_IsTitleAvailable_Call
- func (_e *Repository_Expecter) List(ctx interface{}, userID interface{}, orgID interface{}, query interface{}) *Repository_List_Call
- func (_e *Repository_Expecter) Regenerate(ctx interface{}, id interface{}, secretHash interface{}, expiresAt interface{}) *Repository_Regenerate_Call
- func (_e *Repository_Expecter) Update(ctx interface{}, pat interface{}) *Repository_Update_Call
- func (_e *Repository_Expecter) UpdateLastUsedAt(ctx interface{}, id interface{}, at interface{}) *Repository_UpdateLastUsedAt_Call
- type Repository_GetByID_Call
- func (_c *Repository_GetByID_Call) Return(_a0 models.PAT, _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) (models.PAT, error)) *Repository_GetByID_Call
- type Repository_GetBySecretHash_Call
- func (_c *Repository_GetBySecretHash_Call) Return(_a0 models.PAT, _a1 error) *Repository_GetBySecretHash_Call
- func (_c *Repository_GetBySecretHash_Call) Run(run func(ctx context.Context, secretHash string)) *Repository_GetBySecretHash_Call
- func (_c *Repository_GetBySecretHash_Call) RunAndReturn(run func(context.Context, string) (models.PAT, error)) *Repository_GetBySecretHash_Call
- type Repository_IsTitleAvailable_Call
- func (_c *Repository_IsTitleAvailable_Call) Return(_a0 bool, _a1 error) *Repository_IsTitleAvailable_Call
- func (_c *Repository_IsTitleAvailable_Call) Run(run func(ctx context.Context, userID string, orgID string, title string)) *Repository_IsTitleAvailable_Call
- func (_c *Repository_IsTitleAvailable_Call) RunAndReturn(run func(context.Context, string, string, string) (bool, error)) *Repository_IsTitleAvailable_Call
- type Repository_List_Call
- func (_c *Repository_List_Call) Return(_a0 models.PATList, _a1 error) *Repository_List_Call
- func (_c *Repository_List_Call) Run(run func(ctx context.Context, userID string, orgID string, query *rql.Query)) *Repository_List_Call
- func (_c *Repository_List_Call) RunAndReturn(run func(context.Context, string, string, *rql.Query) (models.PATList, error)) *Repository_List_Call
- type Repository_Regenerate_Call
- func (_c *Repository_Regenerate_Call) Return(_a0 models.PAT, _a1 error) *Repository_Regenerate_Call
- func (_c *Repository_Regenerate_Call) Run(...) *Repository_Regenerate_Call
- func (_c *Repository_Regenerate_Call) RunAndReturn(run func(context.Context, string, string, time.Time) (models.PAT, error)) *Repository_Regenerate_Call
- type Repository_UpdateLastUsedAt_Call
- func (_c *Repository_UpdateLastUsedAt_Call) Return(_a0 error) *Repository_UpdateLastUsedAt_Call
- func (_c *Repository_UpdateLastUsedAt_Call) Run(run func(ctx context.Context, id string, at time.Time)) *Repository_UpdateLastUsedAt_Call
- func (_c *Repository_UpdateLastUsedAt_Call) RunAndReturn(run func(context.Context, string, time.Time) error) *Repository_UpdateLastUsedAt_Call
- type Repository_Update_Call
- func (_c *Repository_Update_Call) Return(_a0 models.PAT, _a1 error) *Repository_Update_Call
- func (_c *Repository_Update_Call) Run(run func(ctx context.Context, pat models.PAT)) *Repository_Update_Call
- func (_c *Repository_Update_Call) RunAndReturn(run func(context.Context, models.PAT) (models.PAT, error)) *Repository_Update_Call
- type RoleService
- type RoleService_Expecter
- type RoleService_Get_Call
- func (_c *RoleService_Get_Call) Return(_a0 role.Role, _a1 error) *RoleService_Get_Call
- func (_c *RoleService_Get_Call) Run(run func(ctx context.Context, id string)) *RoleService_Get_Call
- func (_c *RoleService_Get_Call) RunAndReturn(run func(context.Context, string) (role.Role, error)) *RoleService_Get_Call
- type RoleService_List_Call
- func (_c *RoleService_List_Call) Return(_a0 []role.Role, _a1 error) *RoleService_List_Call
- func (_c *RoleService_List_Call) Run(run func(ctx context.Context, f role.Filter)) *RoleService_List_Call
- func (_c *RoleService_List_Call) RunAndReturn(run func(context.Context, role.Filter) ([]role.Role, error)) *RoleService_List_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuditRecordRepository ¶
AuditRecordRepository is an autogenerated mock type for the AuditRecordRepository type
func NewAuditRecordRepository ¶
func NewAuditRecordRepository(t interface {
mock.TestingT
Cleanup(func())
}) *AuditRecordRepository
NewAuditRecordRepository creates a new instance of AuditRecordRepository. 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 (*AuditRecordRepository) Create ¶
func (_m *AuditRecordRepository) Create(ctx context.Context, auditRecord models.AuditRecord) (models.AuditRecord, error)
Create provides a mock function with given fields: ctx, auditRecord
func (*AuditRecordRepository) EXPECT ¶
func (_m *AuditRecordRepository) EXPECT() *AuditRecordRepository_Expecter
type AuditRecordRepository_Create_Call ¶
AuditRecordRepository_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*AuditRecordRepository_Create_Call) Return ¶
func (_c *AuditRecordRepository_Create_Call) Return(_a0 models.AuditRecord, _a1 error) *AuditRecordRepository_Create_Call
func (*AuditRecordRepository_Create_Call) Run ¶
func (_c *AuditRecordRepository_Create_Call) Run(run func(ctx context.Context, auditRecord models.AuditRecord)) *AuditRecordRepository_Create_Call
func (*AuditRecordRepository_Create_Call) RunAndReturn ¶
func (_c *AuditRecordRepository_Create_Call) RunAndReturn(run func(context.Context, models.AuditRecord) (models.AuditRecord, error)) *AuditRecordRepository_Create_Call
type AuditRecordRepository_Expecter ¶
type AuditRecordRepository_Expecter struct {
// contains filtered or unexported fields
}
func (*AuditRecordRepository_Expecter) Create ¶
func (_e *AuditRecordRepository_Expecter) Create(ctx interface{}, auditRecord interface{}) *AuditRecordRepository_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- auditRecord models.AuditRecord
type OrganizationService ¶
OrganizationService is an autogenerated mock type for the OrganizationService type
func NewOrganizationService ¶
func NewOrganizationService(t interface {
mock.TestingT
Cleanup(func())
}) *OrganizationService
NewOrganizationService creates a new instance of OrganizationService. 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 (*OrganizationService) EXPECT ¶
func (_m *OrganizationService) EXPECT() *OrganizationService_Expecter
func (*OrganizationService) GetRaw ¶
func (_m *OrganizationService) GetRaw(ctx context.Context, id string) (organization.Organization, error)
GetRaw provides a mock function with given fields: ctx, id
type OrganizationService_Expecter ¶
type OrganizationService_Expecter struct {
// contains filtered or unexported fields
}
func (*OrganizationService_Expecter) GetRaw ¶
func (_e *OrganizationService_Expecter) GetRaw(ctx interface{}, id interface{}) *OrganizationService_GetRaw_Call
GetRaw is a helper method to define mock.On call
- ctx context.Context
- id string
type OrganizationService_GetRaw_Call ¶
OrganizationService_GetRaw_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetRaw'
func (*OrganizationService_GetRaw_Call) Return ¶
func (_c *OrganizationService_GetRaw_Call) Return(_a0 organization.Organization, _a1 error) *OrganizationService_GetRaw_Call
func (*OrganizationService_GetRaw_Call) Run ¶
func (_c *OrganizationService_GetRaw_Call) Run(run func(ctx context.Context, id string)) *OrganizationService_GetRaw_Call
func (*OrganizationService_GetRaw_Call) RunAndReturn ¶
func (_c *OrganizationService_GetRaw_Call) RunAndReturn(run func(context.Context, string) (organization.Organization, error)) *OrganizationService_GetRaw_Call
type PolicyService ¶
PolicyService is an autogenerated mock type for the PolicyService type
func NewPolicyService ¶
func NewPolicyService(t interface {
mock.TestingT
Cleanup(func())
}) *PolicyService
NewPolicyService creates a new instance of PolicyService. 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 (*PolicyService) Delete ¶ added in v0.94.0
func (_m *PolicyService) Delete(ctx context.Context, id string) error
Delete provides a mock function with given fields: ctx, id
func (*PolicyService) EXPECT ¶
func (_m *PolicyService) EXPECT() *PolicyService_Expecter
type PolicyService_Create_Call ¶
PolicyService_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*PolicyService_Create_Call) Return ¶
func (_c *PolicyService_Create_Call) Return(_a0 policy.Policy, _a1 error) *PolicyService_Create_Call
func (*PolicyService_Create_Call) Run ¶
func (_c *PolicyService_Create_Call) Run(run func(ctx context.Context, pol policy.Policy)) *PolicyService_Create_Call
func (*PolicyService_Create_Call) RunAndReturn ¶
func (_c *PolicyService_Create_Call) RunAndReturn(run func(context.Context, policy.Policy) (policy.Policy, error)) *PolicyService_Create_Call
type PolicyService_Delete_Call ¶ added in v0.94.0
PolicyService_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*PolicyService_Delete_Call) Return ¶ added in v0.94.0
func (_c *PolicyService_Delete_Call) Return(_a0 error) *PolicyService_Delete_Call
func (*PolicyService_Delete_Call) Run ¶ added in v0.94.0
func (_c *PolicyService_Delete_Call) Run(run func(ctx context.Context, id string)) *PolicyService_Delete_Call
func (*PolicyService_Delete_Call) RunAndReturn ¶ added in v0.94.0
func (_c *PolicyService_Delete_Call) RunAndReturn(run func(context.Context, string) error) *PolicyService_Delete_Call
type PolicyService_Expecter ¶
type PolicyService_Expecter struct {
// contains filtered or unexported fields
}
func (*PolicyService_Expecter) Create ¶
func (_e *PolicyService_Expecter) Create(ctx interface{}, pol interface{}) *PolicyService_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- pol policy.Policy
func (*PolicyService_Expecter) Delete ¶ added in v0.94.0
func (_e *PolicyService_Expecter) Delete(ctx interface{}, id interface{}) *PolicyService_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- id string
func (*PolicyService_Expecter) List ¶ added in v0.94.0
func (_e *PolicyService_Expecter) List(ctx interface{}, flt interface{}) *PolicyService_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- flt policy.Filter
type PolicyService_List_Call ¶ added in v0.94.0
PolicyService_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*PolicyService_List_Call) Return ¶ added in v0.94.0
func (_c *PolicyService_List_Call) Return(_a0 []policy.Policy, _a1 error) *PolicyService_List_Call
func (*PolicyService_List_Call) Run ¶ added in v0.94.0
func (_c *PolicyService_List_Call) Run(run func(ctx context.Context, flt policy.Filter)) *PolicyService_List_Call
func (*PolicyService_List_Call) RunAndReturn ¶ added in v0.94.0
func (_c *PolicyService_List_Call) RunAndReturn(run func(context.Context, policy.Filter) ([]policy.Policy, error)) *PolicyService_List_Call
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) CountActive ¶
CountActive provides a mock function with given fields: ctx, userID, orgID
func (*Repository) Delete ¶ added in v0.94.0
func (_m *Repository) Delete(ctx context.Context, id string) error
Delete provides a mock function with given fields: ctx, id
func (*Repository) EXPECT ¶
func (_m *Repository) EXPECT() *Repository_Expecter
func (*Repository) GetByID ¶ added in v0.93.2
GetByID provides a mock function with given fields: ctx, id
func (*Repository) GetBySecretHash ¶ added in v0.93.2
GetBySecretHash provides a mock function with given fields: ctx, secretHash
func (*Repository) IsTitleAvailable ¶ added in v0.94.0
func (_m *Repository) IsTitleAvailable(ctx context.Context, userID string, orgID string, title string) (bool, error)
IsTitleAvailable provides a mock function with given fields: ctx, userID, orgID, title
func (*Repository) List ¶ added in v0.94.0
func (_m *Repository) List(ctx context.Context, userID string, orgID string, query *rql.Query) (models.PATList, error)
List provides a mock function with given fields: ctx, userID, orgID, query
func (*Repository) Regenerate ¶ added in v0.94.0
func (_m *Repository) Regenerate(ctx context.Context, id string, secretHash string, expiresAt time.Time) (models.PAT, error)
Regenerate provides a mock function with given fields: ctx, id, secretHash, expiresAt
func (*Repository) Update ¶ added in v0.94.0
Update provides a mock function with given fields: ctx, pat
func (*Repository) UpdateLastUsedAt ¶ added in v0.93.2
UpdateLastUsedAt provides a mock function with given fields: ctx, id, at
type Repository_CountActive_Call ¶
Repository_CountActive_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CountActive'
func (*Repository_CountActive_Call) Return ¶
func (_c *Repository_CountActive_Call) Return(_a0 int64, _a1 error) *Repository_CountActive_Call
func (*Repository_CountActive_Call) Run ¶
func (_c *Repository_CountActive_Call) Run(run func(ctx context.Context, userID string, orgID string)) *Repository_CountActive_Call
func (*Repository_CountActive_Call) RunAndReturn ¶
func (_c *Repository_CountActive_Call) RunAndReturn(run func(context.Context, string, string) (int64, error)) *Repository_CountActive_Call
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 models.PAT, _a1 error) *Repository_Create_Call
func (*Repository_Create_Call) Run ¶
func (_c *Repository_Create_Call) Run(run func(ctx context.Context, pat models.PAT)) *Repository_Create_Call
func (*Repository_Create_Call) RunAndReturn ¶
func (_c *Repository_Create_Call) RunAndReturn(run func(context.Context, models.PAT) (models.PAT, error)) *Repository_Create_Call
type Repository_Delete_Call ¶ added in v0.94.0
Repository_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'
func (*Repository_Delete_Call) Return ¶ added in v0.94.0
func (_c *Repository_Delete_Call) Return(_a0 error) *Repository_Delete_Call
func (*Repository_Delete_Call) Run ¶ added in v0.94.0
func (_c *Repository_Delete_Call) Run(run func(ctx context.Context, id string)) *Repository_Delete_Call
func (*Repository_Delete_Call) RunAndReturn ¶ added in v0.94.0
func (_c *Repository_Delete_Call) RunAndReturn(run func(context.Context, string) error) *Repository_Delete_Call
type Repository_Expecter ¶
type Repository_Expecter struct {
// contains filtered or unexported fields
}
func (*Repository_Expecter) CountActive ¶
func (_e *Repository_Expecter) CountActive(ctx interface{}, userID interface{}, orgID interface{}) *Repository_CountActive_Call
CountActive is a helper method to define mock.On call
- ctx context.Context
- userID string
- orgID string
func (*Repository_Expecter) Create ¶
func (_e *Repository_Expecter) Create(ctx interface{}, pat interface{}) *Repository_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- pat models.PAT
func (*Repository_Expecter) Delete ¶ added in v0.94.0
func (_e *Repository_Expecter) Delete(ctx interface{}, id interface{}) *Repository_Delete_Call
Delete is a helper method to define mock.On call
- ctx context.Context
- id string
func (*Repository_Expecter) GetByID ¶ added in v0.93.2
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) GetBySecretHash ¶ added in v0.93.2
func (_e *Repository_Expecter) GetBySecretHash(ctx interface{}, secretHash interface{}) *Repository_GetBySecretHash_Call
GetBySecretHash is a helper method to define mock.On call
- ctx context.Context
- secretHash string
func (*Repository_Expecter) IsTitleAvailable ¶ added in v0.94.0
func (_e *Repository_Expecter) IsTitleAvailable(ctx interface{}, userID interface{}, orgID interface{}, title interface{}) *Repository_IsTitleAvailable_Call
IsTitleAvailable is a helper method to define mock.On call
- ctx context.Context
- userID string
- orgID string
- title string
func (*Repository_Expecter) List ¶ added in v0.94.0
func (_e *Repository_Expecter) List(ctx interface{}, userID interface{}, orgID interface{}, query interface{}) *Repository_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- userID string
- orgID string
- query *rql.Query
func (*Repository_Expecter) Regenerate ¶ added in v0.94.0
func (_e *Repository_Expecter) Regenerate(ctx interface{}, id interface{}, secretHash interface{}, expiresAt interface{}) *Repository_Regenerate_Call
Regenerate is a helper method to define mock.On call
- ctx context.Context
- id string
- secretHash string
- expiresAt time.Time
func (*Repository_Expecter) Update ¶ added in v0.94.0
func (_e *Repository_Expecter) Update(ctx interface{}, pat interface{}) *Repository_Update_Call
Update is a helper method to define mock.On call
- ctx context.Context
- pat models.PAT
func (*Repository_Expecter) UpdateLastUsedAt ¶ added in v0.93.2
func (_e *Repository_Expecter) UpdateLastUsedAt(ctx interface{}, id interface{}, at interface{}) *Repository_UpdateLastUsedAt_Call
UpdateLastUsedAt is a helper method to define mock.On call
- ctx context.Context
- id string
- at time.Time
type Repository_GetByID_Call ¶ added in v0.93.2
Repository_GetByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetByID'
func (*Repository_GetByID_Call) Return ¶ added in v0.93.2
func (_c *Repository_GetByID_Call) Return(_a0 models.PAT, _a1 error) *Repository_GetByID_Call
func (*Repository_GetByID_Call) Run ¶ added in v0.93.2
func (_c *Repository_GetByID_Call) Run(run func(ctx context.Context, id string)) *Repository_GetByID_Call
func (*Repository_GetByID_Call) RunAndReturn ¶ added in v0.93.2
func (_c *Repository_GetByID_Call) RunAndReturn(run func(context.Context, string) (models.PAT, error)) *Repository_GetByID_Call
type Repository_GetBySecretHash_Call ¶ added in v0.93.2
Repository_GetBySecretHash_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetBySecretHash'
func (*Repository_GetBySecretHash_Call) Return ¶ added in v0.93.2
func (_c *Repository_GetBySecretHash_Call) Return(_a0 models.PAT, _a1 error) *Repository_GetBySecretHash_Call
func (*Repository_GetBySecretHash_Call) Run ¶ added in v0.93.2
func (_c *Repository_GetBySecretHash_Call) Run(run func(ctx context.Context, secretHash string)) *Repository_GetBySecretHash_Call
func (*Repository_GetBySecretHash_Call) RunAndReturn ¶ added in v0.93.2
func (_c *Repository_GetBySecretHash_Call) RunAndReturn(run func(context.Context, string) (models.PAT, error)) *Repository_GetBySecretHash_Call
type Repository_IsTitleAvailable_Call ¶ added in v0.94.0
Repository_IsTitleAvailable_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'IsTitleAvailable'
func (*Repository_IsTitleAvailable_Call) Return ¶ added in v0.94.0
func (_c *Repository_IsTitleAvailable_Call) Return(_a0 bool, _a1 error) *Repository_IsTitleAvailable_Call
func (*Repository_IsTitleAvailable_Call) Run ¶ added in v0.94.0
func (_c *Repository_IsTitleAvailable_Call) Run(run func(ctx context.Context, userID string, orgID string, title string)) *Repository_IsTitleAvailable_Call
func (*Repository_IsTitleAvailable_Call) RunAndReturn ¶ added in v0.94.0
func (_c *Repository_IsTitleAvailable_Call) RunAndReturn(run func(context.Context, string, string, string) (bool, error)) *Repository_IsTitleAvailable_Call
type Repository_List_Call ¶ added in v0.94.0
Repository_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*Repository_List_Call) Return ¶ added in v0.94.0
func (_c *Repository_List_Call) Return(_a0 models.PATList, _a1 error) *Repository_List_Call
func (*Repository_List_Call) Run ¶ added in v0.94.0
func (_c *Repository_List_Call) Run(run func(ctx context.Context, userID string, orgID string, query *rql.Query)) *Repository_List_Call
func (*Repository_List_Call) RunAndReturn ¶ added in v0.94.0
type Repository_Regenerate_Call ¶ added in v0.94.0
Repository_Regenerate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Regenerate'
func (*Repository_Regenerate_Call) Return ¶ added in v0.94.0
func (_c *Repository_Regenerate_Call) Return(_a0 models.PAT, _a1 error) *Repository_Regenerate_Call
func (*Repository_Regenerate_Call) Run ¶ added in v0.94.0
func (_c *Repository_Regenerate_Call) Run(run func(ctx context.Context, id string, secretHash string, expiresAt time.Time)) *Repository_Regenerate_Call
func (*Repository_Regenerate_Call) RunAndReturn ¶ added in v0.94.0
type Repository_UpdateLastUsedAt_Call ¶ added in v0.93.2
Repository_UpdateLastUsedAt_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateLastUsedAt'
func (*Repository_UpdateLastUsedAt_Call) Return ¶ added in v0.93.2
func (_c *Repository_UpdateLastUsedAt_Call) Return(_a0 error) *Repository_UpdateLastUsedAt_Call
func (*Repository_UpdateLastUsedAt_Call) Run ¶ added in v0.93.2
func (_c *Repository_UpdateLastUsedAt_Call) Run(run func(ctx context.Context, id string, at time.Time)) *Repository_UpdateLastUsedAt_Call
func (*Repository_UpdateLastUsedAt_Call) RunAndReturn ¶ added in v0.93.2
func (_c *Repository_UpdateLastUsedAt_Call) RunAndReturn(run func(context.Context, string, time.Time) error) *Repository_UpdateLastUsedAt_Call
type Repository_Update_Call ¶ added in v0.94.0
Repository_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'
func (*Repository_Update_Call) Return ¶ added in v0.94.0
func (_c *Repository_Update_Call) Return(_a0 models.PAT, _a1 error) *Repository_Update_Call
func (*Repository_Update_Call) Run ¶ added in v0.94.0
func (_c *Repository_Update_Call) Run(run func(ctx context.Context, pat models.PAT)) *Repository_Update_Call
func (*Repository_Update_Call) RunAndReturn ¶ added in v0.94.0
func (_c *Repository_Update_Call) RunAndReturn(run func(context.Context, models.PAT) (models.PAT, error)) *Repository_Update_Call
type RoleService ¶
RoleService is an autogenerated mock type for the RoleService type
func NewRoleService ¶
func NewRoleService(t interface {
mock.TestingT
Cleanup(func())
}) *RoleService
NewRoleService creates a new instance of RoleService. 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 (*RoleService) EXPECT ¶
func (_m *RoleService) EXPECT() *RoleService_Expecter
type RoleService_Expecter ¶
type RoleService_Expecter struct {
// contains filtered or unexported fields
}
func (*RoleService_Expecter) Get ¶
func (_e *RoleService_Expecter) Get(ctx interface{}, id interface{}) *RoleService_Get_Call
Get is a helper method to define mock.On call
- ctx context.Context
- id string
func (*RoleService_Expecter) List ¶
func (_e *RoleService_Expecter) List(ctx interface{}, f interface{}) *RoleService_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- f role.Filter
type RoleService_Get_Call ¶
RoleService_Get_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Get'
func (*RoleService_Get_Call) Return ¶
func (_c *RoleService_Get_Call) Return(_a0 role.Role, _a1 error) *RoleService_Get_Call
func (*RoleService_Get_Call) Run ¶
func (_c *RoleService_Get_Call) Run(run func(ctx context.Context, id string)) *RoleService_Get_Call
func (*RoleService_Get_Call) RunAndReturn ¶
func (_c *RoleService_Get_Call) RunAndReturn(run func(context.Context, string) (role.Role, error)) *RoleService_Get_Call
type RoleService_List_Call ¶
RoleService_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*RoleService_List_Call) Return ¶
func (_c *RoleService_List_Call) Return(_a0 []role.Role, _a1 error) *RoleService_List_Call
func (*RoleService_List_Call) Run ¶
func (_c *RoleService_List_Call) Run(run func(ctx context.Context, f role.Filter)) *RoleService_List_Call
func (*RoleService_List_Call) RunAndReturn ¶
func (_c *RoleService_List_Call) RunAndReturn(run func(context.Context, role.Filter) ([]role.Role, error)) *RoleService_List_Call