Documentation
¶
Index ¶
- type CASBackendReader
- func (_m *CASBackendReader) FindByIDInOrg(ctx context.Context, OrgID string, ID string) (*biz.CASBackend, error)
- func (_m *CASBackendReader) FindDefaultBackend(ctx context.Context, orgID string) (*biz.CASBackend, error)
- func (_m *CASBackendReader) PerformValidation(ctx context.Context, ID string) error
- type CASBackendRepo
- func (_m *CASBackendRepo) Create(_a0 context.Context, _a1 *biz.CASBackendCreateOpts) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) Delete(ctx context.Context, ID uuid.UUID) error
- func (_m *CASBackendRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) FindByIDInOrg(ctx context.Context, OrgID uuid.UUID, ID uuid.UUID) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) FindByNameInOrg(ctx context.Context, OrgID uuid.UUID, name string) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) FindDefaultBackend(ctx context.Context, orgID uuid.UUID) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) FindFallbackBackend(ctx context.Context, orgID uuid.UUID) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) List(ctx context.Context, orgID uuid.UUID) ([]*biz.CASBackend, error)
- func (_m *CASBackendRepo) SoftDelete(ctx context.Context, ID uuid.UUID) error
- func (_m *CASBackendRepo) Update(_a0 context.Context, _a1 *biz.CASBackendUpdateOpts) (*biz.CASBackend, error)
- func (_m *CASBackendRepo) UpdateValidationStatus(ctx context.Context, ID uuid.UUID, status biz.CASBackendValidationStatus) error
- type CASClient
- type CASMappingRepo
- type MembershipsRBAC
- type MockAPITokenRepo
- func (_mock *MockAPITokenRepo) Create(ctx context.Context, name string, description *string, expiresAt *time.Time, ...) (*biz.APIToken, error)
- func (_m *MockAPITokenRepo) EXPECT() *MockAPITokenRepo_Expecter
- func (_mock *MockAPITokenRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.APIToken, error)
- func (_mock *MockAPITokenRepo) FindByNameInOrg(ctx context.Context, orgID uuid.UUID, name string, projectID *uuid.UUID) (*biz.APIToken, error)
- func (_mock *MockAPITokenRepo) List(ctx context.Context, orgID *uuid.UUID, projectID *uuid.UUID, ...) ([]*biz.APIToken, error)
- func (_mock *MockAPITokenRepo) Revoke(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) error
- func (_mock *MockAPITokenRepo) UpdateExpiration(ctx context.Context, ID uuid.UUID, expiresAt time.Time) error
- func (_mock *MockAPITokenRepo) UpdateLastUsedAt(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time) error
- type MockAPITokenRepo_Create_Call
- type MockAPITokenRepo_Expecter
- func (_e *MockAPITokenRepo_Expecter) Create(ctx interface{}, name interface{}, description interface{}, ...) *MockAPITokenRepo_Create_Call
- func (_e *MockAPITokenRepo_Expecter) FindByID(ctx interface{}, ID interface{}) *MockAPITokenRepo_FindByID_Call
- func (_e *MockAPITokenRepo_Expecter) FindByNameInOrg(ctx interface{}, orgID interface{}, name interface{}, projectID interface{}) *MockAPITokenRepo_FindByNameInOrg_Call
- func (_e *MockAPITokenRepo_Expecter) List(ctx interface{}, orgID interface{}, projectID interface{}, ...) *MockAPITokenRepo_List_Call
- func (_e *MockAPITokenRepo_Expecter) Revoke(ctx interface{}, orgID interface{}, ID interface{}) *MockAPITokenRepo_Revoke_Call
- func (_e *MockAPITokenRepo_Expecter) UpdateExpiration(ctx interface{}, ID interface{}, expiresAt interface{}) *MockAPITokenRepo_UpdateExpiration_Call
- func (_e *MockAPITokenRepo_Expecter) UpdateLastUsedAt(ctx interface{}, ID interface{}, lastUsedAt interface{}) *MockAPITokenRepo_UpdateLastUsedAt_Call
- type MockAPITokenRepo_FindByID_Call
- func (_c *MockAPITokenRepo_FindByID_Call) Return(aPIToken *biz.APIToken, err error) *MockAPITokenRepo_FindByID_Call
- func (_c *MockAPITokenRepo_FindByID_Call) Run(run func(ctx context.Context, ID uuid.UUID)) *MockAPITokenRepo_FindByID_Call
- func (_c *MockAPITokenRepo_FindByID_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID) (*biz.APIToken, error)) *MockAPITokenRepo_FindByID_Call
- type MockAPITokenRepo_FindByNameInOrg_Call
- func (_c *MockAPITokenRepo_FindByNameInOrg_Call) Return(aPIToken *biz.APIToken, err error) *MockAPITokenRepo_FindByNameInOrg_Call
- func (_c *MockAPITokenRepo_FindByNameInOrg_Call) Run(...) *MockAPITokenRepo_FindByNameInOrg_Call
- func (_c *MockAPITokenRepo_FindByNameInOrg_Call) RunAndReturn(...) *MockAPITokenRepo_FindByNameInOrg_Call
- type MockAPITokenRepo_List_Call
- func (_c *MockAPITokenRepo_List_Call) Return(aPITokens []*biz.APIToken, err error) *MockAPITokenRepo_List_Call
- func (_c *MockAPITokenRepo_List_Call) Run(run func(ctx context.Context, orgID *uuid.UUID, projectID *uuid.UUID, ...)) *MockAPITokenRepo_List_Call
- func (_c *MockAPITokenRepo_List_Call) RunAndReturn(...) *MockAPITokenRepo_List_Call
- type MockAPITokenRepo_Revoke_Call
- func (_c *MockAPITokenRepo_Revoke_Call) Return(err error) *MockAPITokenRepo_Revoke_Call
- func (_c *MockAPITokenRepo_Revoke_Call) Run(run func(ctx context.Context, orgID uuid.UUID, ID uuid.UUID)) *MockAPITokenRepo_Revoke_Call
- func (_c *MockAPITokenRepo_Revoke_Call) RunAndReturn(run func(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) error) *MockAPITokenRepo_Revoke_Call
- type MockAPITokenRepo_UpdateExpiration_Call
- func (_c *MockAPITokenRepo_UpdateExpiration_Call) Return(err error) *MockAPITokenRepo_UpdateExpiration_Call
- func (_c *MockAPITokenRepo_UpdateExpiration_Call) Run(run func(ctx context.Context, ID uuid.UUID, expiresAt time.Time)) *MockAPITokenRepo_UpdateExpiration_Call
- func (_c *MockAPITokenRepo_UpdateExpiration_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID, expiresAt time.Time) error) *MockAPITokenRepo_UpdateExpiration_Call
- type MockAPITokenRepo_UpdateLastUsedAt_Call
- func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) Return(err error) *MockAPITokenRepo_UpdateLastUsedAt_Call
- func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) Run(run func(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time)) *MockAPITokenRepo_UpdateLastUsedAt_Call
- func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time) error) *MockAPITokenRepo_UpdateLastUsedAt_Call
- type OrganizationRepo
- func (_m *OrganizationRepo) Create(ctx context.Context, name string) (*biz.Organization, error)
- func (_m *OrganizationRepo) Delete(ctx context.Context, ID uuid.UUID) error
- func (_m *OrganizationRepo) FindByID(ctx context.Context, orgID uuid.UUID) (*biz.Organization, error)
- func (_m *OrganizationRepo) FindByName(ctx context.Context, name string) (*biz.Organization, error)
- func (_m *OrganizationRepo) Update(ctx context.Context, id uuid.UUID, blockOnPolicyViolation *bool) (*biz.Organization, error)
- type PromObservable
- type UserOrgFinder
- func (_m *UserOrgFinder) CurrentMembership(ctx context.Context, userID string) (*biz.Membership, error)
- func (_m *UserOrgFinder) FindByID(ctx context.Context, userID string) (*biz.User, error)
- func (_m *UserOrgFinder) MembershipInOrg(ctx context.Context, userID string, orgName string) (*biz.Membership, error)
- type WorkflowRunRepo
- func (_m *WorkflowRunRepo) Create(ctx context.Context, opts *biz.WorkflowRunRepoCreateOpts) (*biz.WorkflowRun, error)
- func (_m *WorkflowRunRepo) Expire(ctx context.Context, id uuid.UUID) error
- func (_m *WorkflowRunRepo) FindByAttestationDigest(ctx context.Context, digest string) (*biz.WorkflowRun, error)
- func (_m *WorkflowRunRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.WorkflowRun, error)
- func (_m *WorkflowRunRepo) FindByIDInOrg(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) (*biz.WorkflowRun, error)
- func (_m *WorkflowRunRepo) GetBundle(ctx context.Context, wrID uuid.UUID) ([]byte, error)
- func (_m *WorkflowRunRepo) List(ctx context.Context, orgID uuid.UUID, f *biz.RunListFilters, ...) ([]*biz.WorkflowRun, string, error)
- func (_m *WorkflowRunRepo) ListNotFinishedOlderThan(ctx context.Context, olderThan time.Time, limit int) ([]*biz.WorkflowRun, error)
- func (_m *WorkflowRunRepo) MarkAsFinished(ctx context.Context, ID uuid.UUID, status biz.WorkflowRunStatus, reason string) error
- func (_m *WorkflowRunRepo) SaveAttestation(ctx context.Context, ID uuid.UUID, att *dsse.Envelope, digest string) error
- func (_m *WorkflowRunRepo) SaveBundle(ctx context.Context, ID uuid.UUID, bundle []byte) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CASBackendReader ¶
CASBackendReader is an autogenerated mock type for the CASBackendReader type
func NewCASBackendReader ¶
func NewCASBackendReader(t interface {
mock.TestingT
Cleanup(func())
}) *CASBackendReader
NewCASBackendReader creates a new instance of CASBackendReader. 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 (*CASBackendReader) FindByIDInOrg ¶
func (_m *CASBackendReader) FindByIDInOrg(ctx context.Context, OrgID string, ID string) (*biz.CASBackend, error)
FindByIDInOrg provides a mock function with given fields: ctx, OrgID, ID
func (*CASBackendReader) FindDefaultBackend ¶
func (_m *CASBackendReader) FindDefaultBackend(ctx context.Context, orgID string) (*biz.CASBackend, error)
FindDefaultBackend provides a mock function with given fields: ctx, orgID
func (*CASBackendReader) PerformValidation ¶
func (_m *CASBackendReader) PerformValidation(ctx context.Context, ID string) error
PerformValidation provides a mock function with given fields: ctx, ID
type CASBackendRepo ¶
CASBackendRepo is an autogenerated mock type for the CASBackendRepo type
func NewCASBackendRepo ¶
func NewCASBackendRepo(t interface {
mock.TestingT
Cleanup(func())
}) *CASBackendRepo
NewCASBackendRepo creates a new instance of CASBackendRepo. 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 (*CASBackendRepo) Create ¶
func (_m *CASBackendRepo) Create(_a0 context.Context, _a1 *biz.CASBackendCreateOpts) (*biz.CASBackend, error)
Create provides a mock function with given fields: _a0, _a1
func (*CASBackendRepo) FindByID ¶
func (_m *CASBackendRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.CASBackend, error)
FindByID provides a mock function with given fields: ctx, ID
func (*CASBackendRepo) FindByIDInOrg ¶
func (_m *CASBackendRepo) FindByIDInOrg(ctx context.Context, OrgID uuid.UUID, ID uuid.UUID) (*biz.CASBackend, error)
FindByIDInOrg provides a mock function with given fields: ctx, OrgID, ID
func (*CASBackendRepo) FindByNameInOrg ¶ added in v0.93.0
func (_m *CASBackendRepo) FindByNameInOrg(ctx context.Context, OrgID uuid.UUID, name string) (*biz.CASBackend, error)
FindByNameInOrg provides a mock function with given fields: ctx, OrgID, name
func (*CASBackendRepo) FindDefaultBackend ¶
func (_m *CASBackendRepo) FindDefaultBackend(ctx context.Context, orgID uuid.UUID) (*biz.CASBackend, error)
FindDefaultBackend provides a mock function with given fields: ctx, orgID
func (*CASBackendRepo) FindFallbackBackend ¶
func (_m *CASBackendRepo) FindFallbackBackend(ctx context.Context, orgID uuid.UUID) (*biz.CASBackend, error)
FindFallbackBackend provides a mock function with given fields: ctx, orgID
func (*CASBackendRepo) List ¶
func (_m *CASBackendRepo) List(ctx context.Context, orgID uuid.UUID) ([]*biz.CASBackend, error)
List provides a mock function with given fields: ctx, orgID
func (*CASBackendRepo) SoftDelete ¶
SoftDelete provides a mock function with given fields: ctx, ID
func (*CASBackendRepo) Update ¶
func (_m *CASBackendRepo) Update(_a0 context.Context, _a1 *biz.CASBackendUpdateOpts) (*biz.CASBackend, error)
Update provides a mock function with given fields: _a0, _a1
func (*CASBackendRepo) UpdateValidationStatus ¶
func (_m *CASBackendRepo) UpdateValidationStatus(ctx context.Context, ID uuid.UUID, status biz.CASBackendValidationStatus) error
UpdateValidationStatus provides a mock function with given fields: ctx, ID, status
type CASClient ¶
CASClient is an autogenerated mock type for the CASClient type
func NewCASClient ¶
NewCASClient creates a new instance of CASClient. 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.
type CASMappingRepo ¶
CASMappingRepo is an autogenerated mock type for the CASMappingRepo type
func NewCASMappingRepo ¶
func NewCASMappingRepo(t interface {
mock.TestingT
Cleanup(func())
}) *CASMappingRepo
NewCASMappingRepo creates a new instance of CASMappingRepo. 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 (*CASMappingRepo) Create ¶
func (_m *CASMappingRepo) Create(ctx context.Context, digest string, casBackendID uuid.UUID, opts *biz.CASMappingCreateOpts) (*biz.CASMapping, error)
Create provides a mock function with given fields: ctx, digest, casBackendID, opts
func (*CASMappingRepo) FindByDigest ¶
func (_m *CASMappingRepo) FindByDigest(ctx context.Context, digest string) ([]*biz.CASMapping, error)
FindByDigest provides a mock function with given fields: ctx, digest
type MembershipsRBAC ¶ added in v1.11.0
MembershipsRBAC is an autogenerated mock type for the MembershipsRBAC type
func NewMembershipsRBAC ¶ added in v1.11.0
func NewMembershipsRBAC(t interface {
mock.TestingT
Cleanup(func())
}) *MembershipsRBAC
NewMembershipsRBAC creates a new instance of MembershipsRBAC. 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 (*MembershipsRBAC) ListAllMembershipsForUser ¶ added in v1.11.0
func (_m *MembershipsRBAC) ListAllMembershipsForUser(ctx context.Context, userID uuid.UUID) ([]*biz.Membership, error)
ListAllMembershipsForUser provides a mock function with given fields: ctx, userID
type MockAPITokenRepo ¶ added in v1.19.0
MockAPITokenRepo is an autogenerated mock type for the APITokenRepo type
func NewMockAPITokenRepo ¶ added in v1.19.0
func NewMockAPITokenRepo(t interface {
mock.TestingT
Cleanup(func())
}) *MockAPITokenRepo
NewMockAPITokenRepo creates a new instance of MockAPITokenRepo. 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 (*MockAPITokenRepo) Create ¶ added in v1.19.0
func (_mock *MockAPITokenRepo) Create(ctx context.Context, name string, description *string, expiresAt *time.Time, organizationID uuid.UUID, projectID *uuid.UUID) (*biz.APIToken, error)
Create provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) EXPECT ¶ added in v1.19.0
func (_m *MockAPITokenRepo) EXPECT() *MockAPITokenRepo_Expecter
func (*MockAPITokenRepo) FindByID ¶ added in v1.19.0
FindByID provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) FindByNameInOrg ¶ added in v1.19.0
func (_mock *MockAPITokenRepo) FindByNameInOrg(ctx context.Context, orgID uuid.UUID, name string, projectID *uuid.UUID) (*biz.APIToken, error)
FindByNameInOrg provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) List ¶ added in v1.19.0
func (_mock *MockAPITokenRepo) List(ctx context.Context, orgID *uuid.UUID, projectID *uuid.UUID, includeRevoked bool, showOnlySystemTokens bool) ([]*biz.APIToken, error)
List provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) Revoke ¶ added in v1.19.0
Revoke provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) UpdateExpiration ¶ added in v1.19.0
func (_mock *MockAPITokenRepo) UpdateExpiration(ctx context.Context, ID uuid.UUID, expiresAt time.Time) error
UpdateExpiration provides a mock function for the type MockAPITokenRepo
func (*MockAPITokenRepo) UpdateLastUsedAt ¶ added in v1.19.0
func (_mock *MockAPITokenRepo) UpdateLastUsedAt(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time) error
UpdateLastUsedAt provides a mock function for the type MockAPITokenRepo
type MockAPITokenRepo_Create_Call ¶ added in v1.19.0
MockAPITokenRepo_Create_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Create'
func (*MockAPITokenRepo_Create_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_Create_Call) Return(aPIToken *biz.APIToken, err error) *MockAPITokenRepo_Create_Call
func (*MockAPITokenRepo_Create_Call) RunAndReturn ¶ added in v1.19.0
type MockAPITokenRepo_Expecter ¶ added in v1.19.0
type MockAPITokenRepo_Expecter struct {
// contains filtered or unexported fields
}
func (*MockAPITokenRepo_Expecter) Create ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) Create(ctx interface{}, name interface{}, description interface{}, expiresAt interface{}, organizationID interface{}, projectID interface{}) *MockAPITokenRepo_Create_Call
Create is a helper method to define mock.On call
- ctx context.Context
- name string
- description *string
- expiresAt *time.Time
- organizationID uuid.UUID
- projectID *uuid.UUID
func (*MockAPITokenRepo_Expecter) FindByID ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) FindByID(ctx interface{}, ID interface{}) *MockAPITokenRepo_FindByID_Call
FindByID is a helper method to define mock.On call
- ctx context.Context
- ID uuid.UUID
func (*MockAPITokenRepo_Expecter) FindByNameInOrg ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) FindByNameInOrg(ctx interface{}, orgID interface{}, name interface{}, projectID interface{}) *MockAPITokenRepo_FindByNameInOrg_Call
FindByNameInOrg is a helper method to define mock.On call
- ctx context.Context
- orgID uuid.UUID
- name string
- projectID *uuid.UUID
func (*MockAPITokenRepo_Expecter) List ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) List(ctx interface{}, orgID interface{}, projectID interface{}, includeRevoked interface{}, showOnlySystemTokens interface{}) *MockAPITokenRepo_List_Call
List is a helper method to define mock.On call
- ctx context.Context
- orgID *uuid.UUID
- projectID *uuid.UUID
- includeRevoked bool
- showOnlySystemTokens bool
func (*MockAPITokenRepo_Expecter) Revoke ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) Revoke(ctx interface{}, orgID interface{}, ID interface{}) *MockAPITokenRepo_Revoke_Call
Revoke is a helper method to define mock.On call
- ctx context.Context
- orgID uuid.UUID
- ID uuid.UUID
func (*MockAPITokenRepo_Expecter) UpdateExpiration ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) UpdateExpiration(ctx interface{}, ID interface{}, expiresAt interface{}) *MockAPITokenRepo_UpdateExpiration_Call
UpdateExpiration is a helper method to define mock.On call
- ctx context.Context
- ID uuid.UUID
- expiresAt time.Time
func (*MockAPITokenRepo_Expecter) UpdateLastUsedAt ¶ added in v1.19.0
func (_e *MockAPITokenRepo_Expecter) UpdateLastUsedAt(ctx interface{}, ID interface{}, lastUsedAt interface{}) *MockAPITokenRepo_UpdateLastUsedAt_Call
UpdateLastUsedAt is a helper method to define mock.On call
- ctx context.Context
- ID uuid.UUID
- lastUsedAt time.Time
type MockAPITokenRepo_FindByID_Call ¶ added in v1.19.0
MockAPITokenRepo_FindByID_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByID'
func (*MockAPITokenRepo_FindByID_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_FindByID_Call) Return(aPIToken *biz.APIToken, err error) *MockAPITokenRepo_FindByID_Call
func (*MockAPITokenRepo_FindByID_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_FindByID_Call) Run(run func(ctx context.Context, ID uuid.UUID)) *MockAPITokenRepo_FindByID_Call
func (*MockAPITokenRepo_FindByID_Call) RunAndReturn ¶ added in v1.19.0
func (_c *MockAPITokenRepo_FindByID_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID) (*biz.APIToken, error)) *MockAPITokenRepo_FindByID_Call
type MockAPITokenRepo_FindByNameInOrg_Call ¶ added in v1.19.0
MockAPITokenRepo_FindByNameInOrg_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'FindByNameInOrg'
func (*MockAPITokenRepo_FindByNameInOrg_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_FindByNameInOrg_Call) Return(aPIToken *biz.APIToken, err error) *MockAPITokenRepo_FindByNameInOrg_Call
func (*MockAPITokenRepo_FindByNameInOrg_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_FindByNameInOrg_Call) Run(run func(ctx context.Context, orgID uuid.UUID, name string, projectID *uuid.UUID)) *MockAPITokenRepo_FindByNameInOrg_Call
func (*MockAPITokenRepo_FindByNameInOrg_Call) RunAndReturn ¶ added in v1.19.0
type MockAPITokenRepo_List_Call ¶ added in v1.19.0
MockAPITokenRepo_List_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'List'
func (*MockAPITokenRepo_List_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_List_Call) Return(aPITokens []*biz.APIToken, err error) *MockAPITokenRepo_List_Call
func (*MockAPITokenRepo_List_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_List_Call) Run(run func(ctx context.Context, orgID *uuid.UUID, projectID *uuid.UUID, includeRevoked bool, showOnlySystemTokens bool)) *MockAPITokenRepo_List_Call
func (*MockAPITokenRepo_List_Call) RunAndReturn ¶ added in v1.19.0
type MockAPITokenRepo_Revoke_Call ¶ added in v1.19.0
MockAPITokenRepo_Revoke_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Revoke'
func (*MockAPITokenRepo_Revoke_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_Revoke_Call) Return(err error) *MockAPITokenRepo_Revoke_Call
func (*MockAPITokenRepo_Revoke_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_Revoke_Call) Run(run func(ctx context.Context, orgID uuid.UUID, ID uuid.UUID)) *MockAPITokenRepo_Revoke_Call
func (*MockAPITokenRepo_Revoke_Call) RunAndReturn ¶ added in v1.19.0
func (_c *MockAPITokenRepo_Revoke_Call) RunAndReturn(run func(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) error) *MockAPITokenRepo_Revoke_Call
type MockAPITokenRepo_UpdateExpiration_Call ¶ added in v1.19.0
MockAPITokenRepo_UpdateExpiration_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateExpiration'
func (*MockAPITokenRepo_UpdateExpiration_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateExpiration_Call) Return(err error) *MockAPITokenRepo_UpdateExpiration_Call
func (*MockAPITokenRepo_UpdateExpiration_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateExpiration_Call) Run(run func(ctx context.Context, ID uuid.UUID, expiresAt time.Time)) *MockAPITokenRepo_UpdateExpiration_Call
func (*MockAPITokenRepo_UpdateExpiration_Call) RunAndReturn ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateExpiration_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID, expiresAt time.Time) error) *MockAPITokenRepo_UpdateExpiration_Call
type MockAPITokenRepo_UpdateLastUsedAt_Call ¶ added in v1.19.0
MockAPITokenRepo_UpdateLastUsedAt_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateLastUsedAt'
func (*MockAPITokenRepo_UpdateLastUsedAt_Call) Return ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) Return(err error) *MockAPITokenRepo_UpdateLastUsedAt_Call
func (*MockAPITokenRepo_UpdateLastUsedAt_Call) Run ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) Run(run func(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time)) *MockAPITokenRepo_UpdateLastUsedAt_Call
func (*MockAPITokenRepo_UpdateLastUsedAt_Call) RunAndReturn ¶ added in v1.19.0
func (_c *MockAPITokenRepo_UpdateLastUsedAt_Call) RunAndReturn(run func(ctx context.Context, ID uuid.UUID, lastUsedAt time.Time) error) *MockAPITokenRepo_UpdateLastUsedAt_Call
type OrganizationRepo ¶
OrganizationRepo is an autogenerated mock type for the OrganizationRepo type
func NewOrganizationRepo ¶
func NewOrganizationRepo(t interface {
mock.TestingT
Cleanup(func())
}) *OrganizationRepo
NewOrganizationRepo creates a new instance of OrganizationRepo. 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 (*OrganizationRepo) Create ¶
func (_m *OrganizationRepo) Create(ctx context.Context, name string) (*biz.Organization, error)
Create provides a mock function with given fields: ctx, name
func (*OrganizationRepo) FindByID ¶
func (_m *OrganizationRepo) FindByID(ctx context.Context, orgID uuid.UUID) (*biz.Organization, error)
FindByID provides a mock function with given fields: ctx, orgID
func (*OrganizationRepo) FindByName ¶ added in v0.91.8
func (_m *OrganizationRepo) FindByName(ctx context.Context, name string) (*biz.Organization, error)
FindByName provides a mock function with given fields: ctx, name
type PromObservable ¶ added in v0.95.0
PromObservable is an autogenerated mock type for the PromObservable type
func NewPromObservable ¶ added in v0.95.0
func NewPromObservable(t interface {
mock.TestingT
Cleanup(func())
}) *PromObservable
NewPromObservable creates a new instance of PromObservable. 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 (*PromObservable) ObserveAttestationIfNeeded ¶ added in v0.95.0
func (_m *PromObservable) ObserveAttestationIfNeeded(ctx context.Context, run *biz.WorkflowRun, status biz.WorkflowRunStatus) bool
ObserveAttestationIfNeeded provides a mock function with given fields: ctx, run, status
type UserOrgFinder ¶
UserOrgFinder is an autogenerated mock type for the UserOrgFinder type
func NewUserOrgFinder ¶
func NewUserOrgFinder(t interface {
mock.TestingT
Cleanup(func())
}) *UserOrgFinder
NewUserOrgFinder creates a new instance of UserOrgFinder. 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 (*UserOrgFinder) CurrentMembership ¶
func (_m *UserOrgFinder) CurrentMembership(ctx context.Context, userID string) (*biz.Membership, error)
CurrentMembership provides a mock function with given fields: ctx, userID
func (*UserOrgFinder) MembershipInOrg ¶ added in v0.140.0
func (_m *UserOrgFinder) MembershipInOrg(ctx context.Context, userID string, orgName string) (*biz.Membership, error)
MembershipInOrg provides a mock function with given fields: ctx, userID, orgName
type WorkflowRunRepo ¶
WorkflowRunRepo is an autogenerated mock type for the WorkflowRunRepo type
func NewWorkflowRunRepo ¶
func NewWorkflowRunRepo(t interface {
mock.TestingT
Cleanup(func())
}) *WorkflowRunRepo
NewWorkflowRunRepo creates a new instance of WorkflowRunRepo. 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 (*WorkflowRunRepo) Create ¶
func (_m *WorkflowRunRepo) Create(ctx context.Context, opts *biz.WorkflowRunRepoCreateOpts) (*biz.WorkflowRun, error)
Create provides a mock function with given fields: ctx, opts
func (*WorkflowRunRepo) FindByAttestationDigest ¶
func (_m *WorkflowRunRepo) FindByAttestationDigest(ctx context.Context, digest string) (*biz.WorkflowRun, error)
FindByAttestationDigest provides a mock function with given fields: ctx, digest
func (*WorkflowRunRepo) FindByID ¶
func (_m *WorkflowRunRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.WorkflowRun, error)
FindByID provides a mock function with given fields: ctx, ID
func (*WorkflowRunRepo) FindByIDInOrg ¶
func (_m *WorkflowRunRepo) FindByIDInOrg(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) (*biz.WorkflowRun, error)
FindByIDInOrg provides a mock function with given fields: ctx, orgID, ID
func (*WorkflowRunRepo) GetBundle ¶ added in v0.160.0
GetBundle provides a mock function with given fields: ctx, wrID
func (*WorkflowRunRepo) List ¶
func (_m *WorkflowRunRepo) List(ctx context.Context, orgID uuid.UUID, f *biz.RunListFilters, p *pagination.CursorOptions) ([]*biz.WorkflowRun, string, error)
List provides a mock function with given fields: ctx, orgID, f, p
func (*WorkflowRunRepo) ListNotFinishedOlderThan ¶
func (_m *WorkflowRunRepo) ListNotFinishedOlderThan(ctx context.Context, olderThan time.Time, limit int) ([]*biz.WorkflowRun, error)
ListNotFinishedOlderThan provides a mock function with given fields: ctx, olderThan, limit
func (*WorkflowRunRepo) MarkAsFinished ¶
func (_m *WorkflowRunRepo) MarkAsFinished(ctx context.Context, ID uuid.UUID, status biz.WorkflowRunStatus, reason string) error
MarkAsFinished provides a mock function with given fields: ctx, ID, status, reason
func (*WorkflowRunRepo) SaveAttestation ¶
func (_m *WorkflowRunRepo) SaveAttestation(ctx context.Context, ID uuid.UUID, att *dsse.Envelope, digest string) error
SaveAttestation provides a mock function with given fields: ctx, ID, att, digest
func (*WorkflowRunRepo) SaveBundle ¶ added in v0.159.0
SaveBundle provides a mock function with given fields: ctx, ID, bundle