mocks

package
v0.85.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 30, 2024 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APITokenRepo added in v0.55.0

type APITokenRepo struct {
	mock.Mock
}

APITokenRepo is an autogenerated mock type for the APITokenRepo type

func NewAPITokenRepo added in v0.55.0

func NewAPITokenRepo(t mockConstructorTestingTNewAPITokenRepo) *APITokenRepo

NewAPITokenRepo creates a new instance of APITokenRepo. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*APITokenRepo) Create added in v0.55.0

func (_m *APITokenRepo) Create(ctx context.Context, name string, description *string, expiresAt *time.Time, organizationID uuid.UUID) (*biz.APIToken, error)

Create provides a mock function with given fields: ctx, name, description, expiresAt, organizationID

func (*APITokenRepo) FindByID added in v0.55.0

func (_m *APITokenRepo) FindByID(ctx context.Context, ID uuid.UUID) (*biz.APIToken, error)

FindByID provides a mock function with given fields: ctx, ID

func (*APITokenRepo) List added in v0.55.0

func (_m *APITokenRepo) List(ctx context.Context, orgID *uuid.UUID, includeRevoked bool) ([]*biz.APIToken, error)

List provides a mock function with given fields: ctx, orgID, includeRevoked

func (*APITokenRepo) Revoke added in v0.55.0

func (_m *APITokenRepo) Revoke(ctx context.Context, orgID uuid.UUID, ID uuid.UUID) error

Revoke provides a mock function with given fields: ctx, orgID, ID

type CASBackendReader added in v0.14.0

type CASBackendReader struct {
	mock.Mock
}

CASBackendReader is an autogenerated mock type for the CASBackendReader type

func NewCASBackendReader added in v0.14.0

func NewCASBackendReader(t mockConstructorTestingTNewCASBackendReader) *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.

func (*CASBackendReader) FindByIDInOrg added in v0.14.0

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 added in v0.14.0

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 added in v0.14.0

func (_m *CASBackendReader) PerformValidation(ctx context.Context, ID string) error

PerformValidation provides a mock function with given fields: ctx, ID

type CASBackendRepo added in v0.14.0

type CASBackendRepo struct {
	mock.Mock
}

CASBackendRepo is an autogenerated mock type for the CASBackendRepo type

func NewCASBackendRepo added in v0.14.0

func NewCASBackendRepo(t mockConstructorTestingTNewCASBackendRepo) *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.

func (*CASBackendRepo) Create added in v0.14.0

Create provides a mock function with given fields: _a0, _a1

func (*CASBackendRepo) Delete added in v0.14.0

func (_m *CASBackendRepo) Delete(ctx context.Context, ID uuid.UUID) error

Delete provides a mock function with given fields: ctx, ID

func (*CASBackendRepo) FindByID added in v0.14.0

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 added in v0.14.0

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) FindDefaultBackend added in v0.14.0

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 added in v0.14.0

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 added in v0.14.0

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 added in v0.14.0

func (_m *CASBackendRepo) SoftDelete(ctx context.Context, ID uuid.UUID) error

SoftDelete provides a mock function with given fields: ctx, ID

func (*CASBackendRepo) Update added in v0.14.0

Update provides a mock function with given fields: _a0, _a1

func (*CASBackendRepo) UpdateValidationStatus added in v0.14.0

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 added in v0.8.95

type CASClient struct {
	mock.Mock
}

CASClient is an autogenerated mock type for the CASClient type

func NewCASClient added in v0.8.95

func NewCASClient(t mockConstructorTestingTNewCASClient) *CASClient

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.

func (*CASClient) Download added in v0.8.95

func (_m *CASClient) Download(ctx context.Context, backendType string, secretID string, w io.Writer, digest string) error

Download provides a mock function with given fields: ctx, backendType, secretID, w, digest

func (*CASClient) Upload added in v0.8.95

func (_m *CASClient) Upload(ctx context.Context, backendType string, secretID string, content io.Reader, filename string, digest string) error

Upload provides a mock function with given fields: ctx, backendType, secretID, content, filename, digest

type CASMappingRepo added in v0.17.0

type CASMappingRepo struct {
	mock.Mock
}

CASMappingRepo is an autogenerated mock type for the CASMappingRepo type

func NewCASMappingRepo added in v0.17.0

func NewCASMappingRepo(t mockConstructorTestingTNewCASMappingRepo) *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.

func (*CASMappingRepo) Create added in v0.17.0

func (_m *CASMappingRepo) Create(ctx context.Context, digest string, casBackendID uuid.UUID, workflowRunID uuid.UUID) (*biz.CASMapping, error)

Create provides a mock function with given fields: ctx, digest, casBackendID, workflowRunID

func (*CASMappingRepo) FindByDigest added in v0.17.0

func (_m *CASMappingRepo) FindByDigest(ctx context.Context, digest string) ([]*biz.CASMapping, error)

FindByDigest provides a mock function with given fields: ctx, digest

type OrganizationRepo

type OrganizationRepo struct {
	mock.Mock
}

OrganizationRepo is an autogenerated mock type for the OrganizationRepo type

func NewOrganizationRepo

func NewOrganizationRepo(t mockConstructorTestingTNewOrganizationRepo) *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.

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) Delete

func (_m *OrganizationRepo) Delete(ctx context.Context, ID uuid.UUID) error

Delete provides a mock function with given fields: ctx, ID

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) Update added in v0.50.0

func (_m *OrganizationRepo) Update(ctx context.Context, id uuid.UUID, name *string) (*biz.Organization, error)

Update provides a mock function with given fields: ctx, id, name

type UserOrgFinder

type UserOrgFinder struct {
	mock.Mock
}

UserOrgFinder is an autogenerated mock type for the UserOrgFinder type

func NewUserOrgFinder

func NewUserOrgFinder(t mockConstructorTestingTNewUserOrgFinder) *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.

func (*UserOrgFinder) CurrentMembership added in v0.75.0

func (_m *UserOrgFinder) CurrentMembership(ctx context.Context, userID string) (*biz.Membership, error)

CurrentMembership provides a mock function with given fields: ctx, userID

func (*UserOrgFinder) FindByID

func (_m *UserOrgFinder) FindByID(ctx context.Context, userID string) (*biz.User, error)

FindByID provides a mock function with given fields: ctx, userID

type WorkflowRunRepo

type WorkflowRunRepo struct {
	mock.Mock
}

WorkflowRunRepo is an autogenerated mock type for the WorkflowRunRepo type

func NewWorkflowRunRepo

func NewWorkflowRunRepo(t mockConstructorTestingTNewWorkflowRunRepo) *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.

func (*WorkflowRunRepo) Create

Create provides a mock function with given fields: ctx, opts

func (*WorkflowRunRepo) Expire

func (_m *WorkflowRunRepo) Expire(ctx context.Context, id uuid.UUID) error

Expire provides a mock function with given fields: ctx, id

func (*WorkflowRunRepo) FindByAttestationDigest added in v0.18.0

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) List

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) ([]*biz.WorkflowRun, error)

ListNotFinishedOlderThan provides a mock function with given fields: ctx, olderThan

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 added in v0.11.1

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

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL