test

package
v0.1.31 Latest Latest
Warning

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

Go to latest
Published: Jan 23, 2025 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 BuildReportsOnList added in v0.1.29

type BuildReportsOnList struct {
	Given *registry.BuildReportFilter
	List  *registry.BuildReportList
	Error error
}

type ImageConfigOnGet added in v0.1.20

type ImageConfigOnGet struct {
	Given *registry.ImageConfigRequest
	Get   *registry.ImageConfig
	Error error
}

type ManifestMetadataOnList added in v0.1.20

type ManifestMetadataOnList struct {
	Given *registry.ManifestMetadataFilter
	List  *registry.ManifestMetadataList
	Error error
}

type MockApkoClient added in v0.1.29

type MockApkoClient struct {
	registry.ApkoClient

	OnResolveConfig []OnResolveConfig
	OnBuildImage    []OnBuildImage
}

func (MockApkoClient) BuildImage added in v0.1.29

func (MockApkoClient) ResolveConfig added in v0.1.29

type MockRegistryClient

type MockRegistryClient struct {
	registry.RegistryClient

	OnCreateRepos               []ReposOnCreate
	OnDeleteRepos               []ReposOnDelete
	OnListRepos                 []ReposOnList
	OnCreateTags                []TagsOnCreate
	OnDeleteTags                []TagsOnDelete
	OnUpdateTag                 []TagOnUpdate
	OnListTags                  []TagsOnList
	OnUpdateRepo                []RepoOnUpdate
	OnListTagHistory            []TagHistoryOnList
	OnGetImageConfig            []ImageConfigOnGet
	OnGetSbom                   []SbomOnGet
	OnGetVulnReport             []VulnReportOnGet
	OnListManifestMetadata      []ManifestMetadataOnList
	OnGetRawSbom                []RawSbomOnGet
	OnGetPackageVersionMetadata []PackageVersionMetadataOnGet
	OnListBuildReports          []BuildReportsOnList
}

func (MockRegistryClient) CreateRepo

func (MockRegistryClient) CreateTag

func (MockRegistryClient) DeleteRepo

func (MockRegistryClient) DeleteTag

func (MockRegistryClient) GetImageConfig added in v0.1.20

func (MockRegistryClient) GetPackageVersionMetadata added in v0.1.25

func (MockRegistryClient) GetRawSbom added in v0.1.21

func (MockRegistryClient) GetSbom added in v0.1.8

func (MockRegistryClient) GetVulnReport added in v0.1.12

func (MockRegistryClient) ListBuildReports added in v0.1.29

func (MockRegistryClient) ListManifestMetadata added in v0.1.20

func (MockRegistryClient) ListRepos

func (MockRegistryClient) ListTagHistory

func (MockRegistryClient) ListTags

func (MockRegistryClient) UpdateRepo

func (m MockRegistryClient) UpdateRepo(_ context.Context, given *registry.Repo, _ ...grpc.CallOption) (*registry.Repo, error)

func (MockRegistryClient) UpdateTag

func (m MockRegistryClient) UpdateTag(_ context.Context, given *registry.Tag, _ ...grpc.CallOption) (*registry.Tag, error)

type MockRegistryClients

type MockRegistryClients struct {
	OnClose error

	RegistryClient        MockRegistryClient
	VulnerabilitiesClient MockVulnerabilitiesClient
	ApkoClient            MockApkoClient
}

func (MockRegistryClients) Apko added in v0.1.29

func (MockRegistryClients) Close

func (m MockRegistryClients) Close() error

func (MockRegistryClients) Registry

func (MockRegistryClients) Vulnerabilities added in v0.1.27

type MockVulnerabilitiesClient added in v0.1.27

type MockVulnerabilitiesClient struct {
	registry.VulnerabilitiesClient

	OnListVulnReports      []VulnReportsOnList
	OnGetRawVulnReport     []RawVulnReportOnGet
	OnListVulnCountReports []VulnCountReportsOnList
}

func (MockVulnerabilitiesClient) GetRawVulnReport added in v0.1.27

func (MockVulnerabilitiesClient) ListVulnCountReports added in v0.1.27

func (MockVulnerabilitiesClient) ListVulnReports added in v0.1.27

type OnBuildImage added in v0.1.29

type OnBuildImage struct {
	Given  *registry.BuildImageRequest
	Result *registry.BuildImageResponse
	Error  error
}

type OnResolveConfig added in v0.1.29

type OnResolveConfig struct {
	Given  *registry.ResolveConfigRequest
	Result *registry.ApkoConfig
	Error  error
}

type PackageVersionMetadataOnGet added in v0.1.25

type PackageVersionMetadataOnGet struct {
	Given *registry.PackageVersionMetadataRequest
	Get   *registry.PackageVersionMetadata
	Error error
}

type RawSbomOnGet added in v0.1.21

type RawSbomOnGet struct {
	Given *registry.RawSbomRequest
	Get   *registry.RawSbom
	Error error
}

type RawVulnReportOnGet added in v0.1.27

type RawVulnReportOnGet struct {
	Given *registry.GetRawVulnReportRequest
	Get   *registry.RawVulnReport
	Error error
}

type RepoOnUpdate

type RepoOnUpdate struct {
	Given   *registry.Repo
	Updated *registry.Repo
	Error   error
}

type ReposOnCreate

type ReposOnCreate struct {
	Given   *registry.CreateRepoRequest
	Created *registry.Repo
	Error   error
}

type ReposOnDelete

type ReposOnDelete struct {
	Given *registry.DeleteRepoRequest
	Error error
}

type ReposOnList

type ReposOnList struct {
	Given *registry.RepoFilter
	List  *registry.RepoList
	Error error
}

type SbomOnGet added in v0.1.8

type SbomOnGet struct {
	Given *registry.SbomRequest
	Get   *tenant.Sbom2
	Error error
}

type TagHistoryOnList

type TagHistoryOnList struct {
	Given *registry.TagHistoryFilter
	List  *registry.TagHistoryList
	Error error
}

type TagOnUpdate

type TagOnUpdate struct {
	Given   *registry.Tag
	Updated *registry.Tag
	Error   error
}

type TagsOnCreate

type TagsOnCreate struct {
	Given   *registry.CreateTagRequest
	Created *registry.Tag
	Error   error
}

type TagsOnDelete

type TagsOnDelete struct {
	Given *registry.DeleteTagRequest
	Error error
}

type TagsOnList

type TagsOnList struct {
	Given *registry.TagFilter
	List  *registry.TagList
	Error error
}

type VulnCountReportsOnList added in v0.1.27

type VulnCountReportsOnList struct {
	Given *registry.VulnCountReportFilter
	List  *registry.VulnCountReportList
	Error error
}

type VulnReportOnGet added in v0.1.12

type VulnReportOnGet struct {
	Given *registry.VulnReportRequest
	Get   *tenant.VulnReport
	Error error
}

type VulnReportsOnList added in v0.1.27

type VulnReportsOnList struct {
	Given *registry.VulnReportFilter
	List  *registry.VulnReportList
	Error error
}

Jump to

Keyboard shortcuts

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