dependencytrack

package
v0.0.0-...-f79a1ae Latest Latest
Warning

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

Go to latest
Published: Apr 26, 2024 License: MIT Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppInstance

type AppInstance struct {
	Env, Team, App, Image string
}

func (*AppInstance) ID

func (a *AppInstance) ID() string

func (*AppInstance) ProjectName

func (a *AppInstance) ProjectName() string

type Client

type Client struct {
	// contains filtered or unexported fields
}

func New

func New(endpoint, username, password, frontend string, log *logrus.Entry) *Client

func (*Client) GetProjectMetrics

func (c *Client) GetProjectMetrics(ctx context.Context, app *AppInstance, date string) (*ProjectMetric, error)

func (*Client) GetVulnerabilities

func (c *Client) GetVulnerabilities(ctx context.Context, apps []*AppInstance, filters ...Filter) ([]*model.Vulnerability, error)

func (*Client) Init

func (c *Client) Init(ctx context.Context) error

func (*Client) VulnerabilitySummary

func (c *Client) VulnerabilitySummary(ctx context.Context, app *AppInstance) (*model.Vulnerability, error)

func (*Client) WithCache

func (c *Client) WithCache(cache *cache.Cache) *Client

func (*Client) WithClient

func (c *Client) WithClient(client dependencytrack.Client) *Client

type Filter

type Filter = func(vulnerability *model.Vulnerability) bool

func RequireSbom

func RequireSbom() Filter

type InternalClient

type InternalClient interface {
	client.Client
}

type MockInternalClient

type MockInternalClient struct {
	mock.Mock
}

MockInternalClient is an autogenerated mock type for the InternalClient type

func NewMockInternalClient

func NewMockInternalClient(t interface {
	mock.TestingT
	Cleanup(func())
},
) *MockInternalClient

NewMockInternalClient creates a new instance of MockInternalClient. 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 (*MockInternalClient) AddToTeam

func (_m *MockInternalClient) AddToTeam(ctx context.Context, username string, uuid string) error

AddToTeam provides a mock function with given fields: ctx, username, uuid

func (*MockInternalClient) ChangeAdminPassword

func (_m *MockInternalClient) ChangeAdminPassword(ctx context.Context, oldPassword string, newPassword string) error

ChangeAdminPassword provides a mock function with given fields: ctx, oldPassword, newPassword

func (*MockInternalClient) ConfigPropertyAggregate

func (_m *MockInternalClient) ConfigPropertyAggregate(ctx context.Context, properties []client.ConfigProperty) ([]client.ConfigProperty, error)

ConfigPropertyAggregate provides a mock function with given fields: ctx, properties

func (*MockInternalClient) CreateAdminUsers

func (_m *MockInternalClient) CreateAdminUsers(ctx context.Context, users *client.AdminUsers, teamUuid string) error

CreateAdminUsers provides a mock function with given fields: ctx, users, teamUuid

func (*MockInternalClient) CreateChildProject

func (_m *MockInternalClient) CreateChildProject(ctx context.Context, project *client.Project, name string, version string, group string, classifier string, tags []string) (*client.Project, error)

CreateChildProject provides a mock function with given fields: ctx, project, name, version, group, classifier, tags

func (*MockInternalClient) CreateManagedUser

func (_m *MockInternalClient) CreateManagedUser(ctx context.Context, username string, password string) error

CreateManagedUser provides a mock function with given fields: ctx, username, password

func (*MockInternalClient) CreateOidcUser

func (_m *MockInternalClient) CreateOidcUser(ctx context.Context, email string) error

CreateOidcUser provides a mock function with given fields: ctx, email

func (*MockInternalClient) CreateProject

func (_m *MockInternalClient) CreateProject(ctx context.Context, name string, version string, group string, tags []string) (*client.Project, error)

CreateProject provides a mock function with given fields: ctx, name, version, group, tags

func (*MockInternalClient) CreateTeam

func (_m *MockInternalClient) CreateTeam(ctx context.Context, teamName string, permissions []client.Permission) (*client.Team, error)

CreateTeam provides a mock function with given fields: ctx, teamName, permissions

func (*MockInternalClient) DeleteManagedUser

func (_m *MockInternalClient) DeleteManagedUser(ctx context.Context, username string) error

DeleteManagedUser provides a mock function with given fields: ctx, username

func (*MockInternalClient) DeleteOidcUser

func (_m *MockInternalClient) DeleteOidcUser(ctx context.Context, username string) error

DeleteOidcUser provides a mock function with given fields: ctx, username

func (*MockInternalClient) DeleteProject

func (_m *MockInternalClient) DeleteProject(ctx context.Context, uuid string) error

DeleteProject provides a mock function with given fields: ctx, uuid

func (*MockInternalClient) DeleteProjects

func (_m *MockInternalClient) DeleteProjects(ctx context.Context, name string) error

DeleteProjects provides a mock function with given fields: ctx, name

func (*MockInternalClient) DeleteTeam

func (_m *MockInternalClient) DeleteTeam(ctx context.Context, uuid string) error

DeleteTeam provides a mock function with given fields: ctx, uuid

func (*MockInternalClient) DeleteUserMembership

func (_m *MockInternalClient) DeleteUserMembership(ctx context.Context, uuid string, username string) error

DeleteUserMembership provides a mock function with given fields: ctx, uuid, username

func (*MockInternalClient) EXPECT

func (*MockInternalClient) GenerateApiKey

func (_m *MockInternalClient) GenerateApiKey(ctx context.Context, uuid string) (string, error)

GenerateApiKey provides a mock function with given fields: ctx, uuid

func (*MockInternalClient) GetConfigProperties

func (_m *MockInternalClient) GetConfigProperties(ctx context.Context) ([]client.ConfigProperty, error)

GetConfigProperties provides a mock function with given fields: ctx

func (*MockInternalClient) GetCurrentProjectMetric

func (_m *MockInternalClient) GetCurrentProjectMetric(ctx context.Context, projectUuid string) (*client.ProjectMetric, error)

GetCurrentProjectMetric provides a mock function with given fields: ctx, projectUuid

func (*MockInternalClient) GetEcosystems

func (_m *MockInternalClient) GetEcosystems(ctx context.Context) ([]string, error)

GetEcosystems provides a mock function with given fields: ctx

func (*MockInternalClient) GetFindings

func (_m *MockInternalClient) GetFindings(ctx context.Context, projectUuid string) ([]*client.Finding, error)

GetFindings provides a mock function with given fields: ctx, projectUuid

func (*MockInternalClient) GetOidcUsers

func (_m *MockInternalClient) GetOidcUsers(ctx context.Context) ([]client.User, error)

GetOidcUsers provides a mock function with given fields: ctx

func (*MockInternalClient) GetProject

func (_m *MockInternalClient) GetProject(ctx context.Context, name string, version string) (*client.Project, error)

GetProject provides a mock function with given fields: ctx, name, version

func (*MockInternalClient) GetProjectMetricsByDate

func (_m *MockInternalClient) GetProjectMetricsByDate(ctx context.Context, projectUuid string, date string) ([]*client.ProjectMetric, error)

GetProjectMetricsByDate provides a mock function with given fields: ctx, projectUuid, date

func (*MockInternalClient) GetProjects

func (_m *MockInternalClient) GetProjects(ctx context.Context) ([]*client.Project, error)

GetProjects provides a mock function with given fields: ctx

func (*MockInternalClient) GetProjectsByTag

func (_m *MockInternalClient) GetProjectsByTag(ctx context.Context, tag string) ([]*client.Project, error)

GetProjectsByTag provides a mock function with given fields: ctx, tag

func (*MockInternalClient) GetTeam

func (_m *MockInternalClient) GetTeam(ctx context.Context, team string) (*client.Team, error)

GetTeam provides a mock function with given fields: ctx, team

func (*MockInternalClient) GetTeams

func (_m *MockInternalClient) GetTeams(ctx context.Context) ([]client.Team, error)

GetTeams provides a mock function with given fields: ctx

func (*MockInternalClient) Headers

func (_m *MockInternalClient) Headers(ctx context.Context) (http.Header, error)

Headers provides a mock function with given fields: ctx

func (*MockInternalClient) PortfolioRefresh

func (_m *MockInternalClient) PortfolioRefresh(ctx context.Context) error

PortfolioRefresh provides a mock function with given fields: ctx

func (*MockInternalClient) RemoveAdminUsers

func (_m *MockInternalClient) RemoveAdminUsers(ctx context.Context, users *client.AdminUsers) error

RemoveAdminUsers provides a mock function with given fields: ctx, users

func (*MockInternalClient) TriggerAnalysis

func (_m *MockInternalClient) TriggerAnalysis(ctx context.Context, projectUuid string) error

TriggerAnalysis provides a mock function with given fields: ctx, projectUuid

func (*MockInternalClient) UpdateProject

func (_m *MockInternalClient) UpdateProject(ctx context.Context, uuid string, name string, version string, group string, tags []string) (*client.Project, error)

UpdateProject provides a mock function with given fields: ctx, uuid, name, version, group, tags

func (*MockInternalClient) UpdateProjectInfo

func (_m *MockInternalClient) UpdateProjectInfo(ctx context.Context, uuid string, version string, group string, tags []string) error

UpdateProjectInfo provides a mock function with given fields: ctx, uuid, version, group, tags

func (*MockInternalClient) UploadProject

func (_m *MockInternalClient) UploadProject(ctx context.Context, name string, version string, parentUuid string, autoCreate bool, bom []byte) error

UploadProject provides a mock function with given fields: ctx, name, version, parentUuid, autoCreate, bom

func (*MockInternalClient) Version

func (_m *MockInternalClient) Version(ctx context.Context) (string, error)

Version provides a mock function with given fields: ctx

type MockInternalClient_AddToTeam_Call

type MockInternalClient_AddToTeam_Call struct {
	*mock.Call
}

MockInternalClient_AddToTeam_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'AddToTeam'

func (*MockInternalClient_AddToTeam_Call) Return

func (*MockInternalClient_AddToTeam_Call) Run

func (*MockInternalClient_AddToTeam_Call) RunAndReturn

type MockInternalClient_ChangeAdminPassword_Call

type MockInternalClient_ChangeAdminPassword_Call struct {
	*mock.Call
}

MockInternalClient_ChangeAdminPassword_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ChangeAdminPassword'

func (*MockInternalClient_ChangeAdminPassword_Call) Return

func (*MockInternalClient_ChangeAdminPassword_Call) Run

func (*MockInternalClient_ChangeAdminPassword_Call) RunAndReturn

type MockInternalClient_ConfigPropertyAggregate_Call

type MockInternalClient_ConfigPropertyAggregate_Call struct {
	*mock.Call
}

MockInternalClient_ConfigPropertyAggregate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ConfigPropertyAggregate'

func (*MockInternalClient_ConfigPropertyAggregate_Call) Return

func (*MockInternalClient_ConfigPropertyAggregate_Call) Run

func (*MockInternalClient_ConfigPropertyAggregate_Call) RunAndReturn

type MockInternalClient_CreateAdminUsers_Call

type MockInternalClient_CreateAdminUsers_Call struct {
	*mock.Call
}

MockInternalClient_CreateAdminUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateAdminUsers'

func (*MockInternalClient_CreateAdminUsers_Call) Return

func (*MockInternalClient_CreateAdminUsers_Call) Run

func (*MockInternalClient_CreateAdminUsers_Call) RunAndReturn

type MockInternalClient_CreateChildProject_Call

type MockInternalClient_CreateChildProject_Call struct {
	*mock.Call
}

MockInternalClient_CreateChildProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateChildProject'

func (*MockInternalClient_CreateChildProject_Call) Return

func (*MockInternalClient_CreateChildProject_Call) Run

func (_c *MockInternalClient_CreateChildProject_Call) Run(run func(ctx context.Context, project *client.Project, name string, version string, group string, classifier string, tags []string)) *MockInternalClient_CreateChildProject_Call

func (*MockInternalClient_CreateChildProject_Call) RunAndReturn

type MockInternalClient_CreateManagedUser_Call

type MockInternalClient_CreateManagedUser_Call struct {
	*mock.Call
}

MockInternalClient_CreateManagedUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateManagedUser'

func (*MockInternalClient_CreateManagedUser_Call) Return

func (*MockInternalClient_CreateManagedUser_Call) Run

func (*MockInternalClient_CreateManagedUser_Call) RunAndReturn

type MockInternalClient_CreateOidcUser_Call

type MockInternalClient_CreateOidcUser_Call struct {
	*mock.Call
}

MockInternalClient_CreateOidcUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateOidcUser'

func (*MockInternalClient_CreateOidcUser_Call) Return

func (*MockInternalClient_CreateOidcUser_Call) Run

func (*MockInternalClient_CreateOidcUser_Call) RunAndReturn

type MockInternalClient_CreateProject_Call

type MockInternalClient_CreateProject_Call struct {
	*mock.Call
}

MockInternalClient_CreateProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateProject'

func (*MockInternalClient_CreateProject_Call) Return

func (*MockInternalClient_CreateProject_Call) Run

func (*MockInternalClient_CreateProject_Call) RunAndReturn

type MockInternalClient_CreateTeam_Call

type MockInternalClient_CreateTeam_Call struct {
	*mock.Call
}

MockInternalClient_CreateTeam_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'CreateTeam'

func (*MockInternalClient_CreateTeam_Call) Return

func (*MockInternalClient_CreateTeam_Call) Run

func (*MockInternalClient_CreateTeam_Call) RunAndReturn

type MockInternalClient_DeleteManagedUser_Call

type MockInternalClient_DeleteManagedUser_Call struct {
	*mock.Call
}

MockInternalClient_DeleteManagedUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteManagedUser'

func (*MockInternalClient_DeleteManagedUser_Call) Return

func (*MockInternalClient_DeleteManagedUser_Call) Run

func (*MockInternalClient_DeleteManagedUser_Call) RunAndReturn

type MockInternalClient_DeleteOidcUser_Call

type MockInternalClient_DeleteOidcUser_Call struct {
	*mock.Call
}

MockInternalClient_DeleteOidcUser_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteOidcUser'

func (*MockInternalClient_DeleteOidcUser_Call) Return

func (*MockInternalClient_DeleteOidcUser_Call) Run

func (*MockInternalClient_DeleteOidcUser_Call) RunAndReturn

type MockInternalClient_DeleteProject_Call

type MockInternalClient_DeleteProject_Call struct {
	*mock.Call
}

MockInternalClient_DeleteProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteProject'

func (*MockInternalClient_DeleteProject_Call) Return

func (*MockInternalClient_DeleteProject_Call) Run

func (*MockInternalClient_DeleteProject_Call) RunAndReturn

type MockInternalClient_DeleteProjects_Call

type MockInternalClient_DeleteProjects_Call struct {
	*mock.Call
}

MockInternalClient_DeleteProjects_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteProjects'

func (*MockInternalClient_DeleteProjects_Call) Return

func (*MockInternalClient_DeleteProjects_Call) Run

func (*MockInternalClient_DeleteProjects_Call) RunAndReturn

type MockInternalClient_DeleteTeam_Call

type MockInternalClient_DeleteTeam_Call struct {
	*mock.Call
}

MockInternalClient_DeleteTeam_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteTeam'

func (*MockInternalClient_DeleteTeam_Call) Return

func (*MockInternalClient_DeleteTeam_Call) Run

func (*MockInternalClient_DeleteTeam_Call) RunAndReturn

type MockInternalClient_DeleteUserMembership_Call

type MockInternalClient_DeleteUserMembership_Call struct {
	*mock.Call
}

MockInternalClient_DeleteUserMembership_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'DeleteUserMembership'

func (*MockInternalClient_DeleteUserMembership_Call) Return

func (*MockInternalClient_DeleteUserMembership_Call) Run

func (*MockInternalClient_DeleteUserMembership_Call) RunAndReturn

type MockInternalClient_Expecter

type MockInternalClient_Expecter struct {
	// contains filtered or unexported fields
}

func (*MockInternalClient_Expecter) AddToTeam

func (_e *MockInternalClient_Expecter) AddToTeam(ctx interface{}, username interface{}, uuid interface{}) *MockInternalClient_AddToTeam_Call

AddToTeam is a helper method to define mock.On call

  • ctx context.Context
  • username string
  • uuid string

func (*MockInternalClient_Expecter) ChangeAdminPassword

func (_e *MockInternalClient_Expecter) ChangeAdminPassword(ctx interface{}, oldPassword interface{}, newPassword interface{}) *MockInternalClient_ChangeAdminPassword_Call

ChangeAdminPassword is a helper method to define mock.On call

  • ctx context.Context
  • oldPassword string
  • newPassword string

func (*MockInternalClient_Expecter) ConfigPropertyAggregate

func (_e *MockInternalClient_Expecter) ConfigPropertyAggregate(ctx interface{}, properties interface{}) *MockInternalClient_ConfigPropertyAggregate_Call

ConfigPropertyAggregate is a helper method to define mock.On call

  • ctx context.Context
  • properties []client.ConfigProperty

func (*MockInternalClient_Expecter) CreateAdminUsers

func (_e *MockInternalClient_Expecter) CreateAdminUsers(ctx interface{}, users interface{}, teamUuid interface{}) *MockInternalClient_CreateAdminUsers_Call

CreateAdminUsers is a helper method to define mock.On call

  • ctx context.Context
  • users *client.AdminUsers
  • teamUuid string

func (*MockInternalClient_Expecter) CreateChildProject

func (_e *MockInternalClient_Expecter) CreateChildProject(ctx interface{}, project interface{}, name interface{}, version interface{}, group interface{}, classifier interface{}, tags interface{}) *MockInternalClient_CreateChildProject_Call

CreateChildProject is a helper method to define mock.On call

  • ctx context.Context
  • project *client.Project
  • name string
  • version string
  • group string
  • classifier string
  • tags []string

func (*MockInternalClient_Expecter) CreateManagedUser

func (_e *MockInternalClient_Expecter) CreateManagedUser(ctx interface{}, username interface{}, password interface{}) *MockInternalClient_CreateManagedUser_Call

CreateManagedUser is a helper method to define mock.On call

  • ctx context.Context
  • username string
  • password string

func (*MockInternalClient_Expecter) CreateOidcUser

func (_e *MockInternalClient_Expecter) CreateOidcUser(ctx interface{}, email interface{}) *MockInternalClient_CreateOidcUser_Call

CreateOidcUser is a helper method to define mock.On call

  • ctx context.Context
  • email string

func (*MockInternalClient_Expecter) CreateProject

func (_e *MockInternalClient_Expecter) CreateProject(ctx interface{}, name interface{}, version interface{}, group interface{}, tags interface{}) *MockInternalClient_CreateProject_Call

CreateProject is a helper method to define mock.On call

  • ctx context.Context
  • name string
  • version string
  • group string
  • tags []string

func (*MockInternalClient_Expecter) CreateTeam

func (_e *MockInternalClient_Expecter) CreateTeam(ctx interface{}, teamName interface{}, permissions interface{}) *MockInternalClient_CreateTeam_Call

CreateTeam is a helper method to define mock.On call

  • ctx context.Context
  • teamName string
  • permissions []client.Permission

func (*MockInternalClient_Expecter) DeleteManagedUser

func (_e *MockInternalClient_Expecter) DeleteManagedUser(ctx interface{}, username interface{}) *MockInternalClient_DeleteManagedUser_Call

DeleteManagedUser is a helper method to define mock.On call

  • ctx context.Context
  • username string

func (*MockInternalClient_Expecter) DeleteOidcUser

func (_e *MockInternalClient_Expecter) DeleteOidcUser(ctx interface{}, username interface{}) *MockInternalClient_DeleteOidcUser_Call

DeleteOidcUser is a helper method to define mock.On call

  • ctx context.Context
  • username string

func (*MockInternalClient_Expecter) DeleteProject

func (_e *MockInternalClient_Expecter) DeleteProject(ctx interface{}, uuid interface{}) *MockInternalClient_DeleteProject_Call

DeleteProject is a helper method to define mock.On call

  • ctx context.Context
  • uuid string

func (*MockInternalClient_Expecter) DeleteProjects

func (_e *MockInternalClient_Expecter) DeleteProjects(ctx interface{}, name interface{}) *MockInternalClient_DeleteProjects_Call

DeleteProjects is a helper method to define mock.On call

  • ctx context.Context
  • name string

func (*MockInternalClient_Expecter) DeleteTeam

func (_e *MockInternalClient_Expecter) DeleteTeam(ctx interface{}, uuid interface{}) *MockInternalClient_DeleteTeam_Call

DeleteTeam is a helper method to define mock.On call

  • ctx context.Context
  • uuid string

func (*MockInternalClient_Expecter) DeleteUserMembership

func (_e *MockInternalClient_Expecter) DeleteUserMembership(ctx interface{}, uuid interface{}, username interface{}) *MockInternalClient_DeleteUserMembership_Call

DeleteUserMembership is a helper method to define mock.On call

  • ctx context.Context
  • uuid string
  • username string

func (*MockInternalClient_Expecter) GenerateApiKey

func (_e *MockInternalClient_Expecter) GenerateApiKey(ctx interface{}, uuid interface{}) *MockInternalClient_GenerateApiKey_Call

GenerateApiKey is a helper method to define mock.On call

  • ctx context.Context
  • uuid string

func (*MockInternalClient_Expecter) GetConfigProperties

func (_e *MockInternalClient_Expecter) GetConfigProperties(ctx interface{}) *MockInternalClient_GetConfigProperties_Call

GetConfigProperties is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) GetCurrentProjectMetric

func (_e *MockInternalClient_Expecter) GetCurrentProjectMetric(ctx interface{}, projectUuid interface{}) *MockInternalClient_GetCurrentProjectMetric_Call

GetCurrentProjectMetric is a helper method to define mock.On call

  • ctx context.Context
  • projectUuid string

func (*MockInternalClient_Expecter) GetEcosystems

func (_e *MockInternalClient_Expecter) GetEcosystems(ctx interface{}) *MockInternalClient_GetEcosystems_Call

GetEcosystems is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) GetFindings

func (_e *MockInternalClient_Expecter) GetFindings(ctx interface{}, projectUuid interface{}) *MockInternalClient_GetFindings_Call

GetFindings is a helper method to define mock.On call

  • ctx context.Context
  • projectUuid string

func (*MockInternalClient_Expecter) GetOidcUsers

func (_e *MockInternalClient_Expecter) GetOidcUsers(ctx interface{}) *MockInternalClient_GetOidcUsers_Call

GetOidcUsers is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) GetProject

func (_e *MockInternalClient_Expecter) GetProject(ctx interface{}, name interface{}, version interface{}) *MockInternalClient_GetProject_Call

GetProject is a helper method to define mock.On call

  • ctx context.Context
  • name string
  • version string

func (*MockInternalClient_Expecter) GetProjectMetricsByDate

func (_e *MockInternalClient_Expecter) GetProjectMetricsByDate(ctx interface{}, projectUuid interface{}, date interface{}) *MockInternalClient_GetProjectMetricsByDate_Call

GetProjectMetricsByDate is a helper method to define mock.On call

  • ctx context.Context
  • projectUuid string
  • date string

func (*MockInternalClient_Expecter) GetProjects

func (_e *MockInternalClient_Expecter) GetProjects(ctx interface{}) *MockInternalClient_GetProjects_Call

GetProjects is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) GetProjectsByTag

func (_e *MockInternalClient_Expecter) GetProjectsByTag(ctx interface{}, tag interface{}) *MockInternalClient_GetProjectsByTag_Call

GetProjectsByTag is a helper method to define mock.On call

  • ctx context.Context
  • tag string

func (*MockInternalClient_Expecter) GetTeam

func (_e *MockInternalClient_Expecter) GetTeam(ctx interface{}, team interface{}) *MockInternalClient_GetTeam_Call

GetTeam is a helper method to define mock.On call

  • ctx context.Context
  • team string

func (*MockInternalClient_Expecter) GetTeams

func (_e *MockInternalClient_Expecter) GetTeams(ctx interface{}) *MockInternalClient_GetTeams_Call

GetTeams is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) Headers

func (_e *MockInternalClient_Expecter) Headers(ctx interface{}) *MockInternalClient_Headers_Call

Headers is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) PortfolioRefresh

func (_e *MockInternalClient_Expecter) PortfolioRefresh(ctx interface{}) *MockInternalClient_PortfolioRefresh_Call

PortfolioRefresh is a helper method to define mock.On call

  • ctx context.Context

func (*MockInternalClient_Expecter) RemoveAdminUsers

func (_e *MockInternalClient_Expecter) RemoveAdminUsers(ctx interface{}, users interface{}) *MockInternalClient_RemoveAdminUsers_Call

RemoveAdminUsers is a helper method to define mock.On call

  • ctx context.Context
  • users *client.AdminUsers

func (*MockInternalClient_Expecter) TriggerAnalysis

func (_e *MockInternalClient_Expecter) TriggerAnalysis(ctx interface{}, projectUuid interface{}) *MockInternalClient_TriggerAnalysis_Call

TriggerAnalysis is a helper method to define mock.On call

  • ctx context.Context
  • projectUuid string

func (*MockInternalClient_Expecter) UpdateProject

func (_e *MockInternalClient_Expecter) UpdateProject(ctx interface{}, uuid interface{}, name interface{}, version interface{}, group interface{}, tags interface{}) *MockInternalClient_UpdateProject_Call

UpdateProject is a helper method to define mock.On call

  • ctx context.Context
  • uuid string
  • name string
  • version string
  • group string
  • tags []string

func (*MockInternalClient_Expecter) UpdateProjectInfo

func (_e *MockInternalClient_Expecter) UpdateProjectInfo(ctx interface{}, uuid interface{}, version interface{}, group interface{}, tags interface{}) *MockInternalClient_UpdateProjectInfo_Call

UpdateProjectInfo is a helper method to define mock.On call

  • ctx context.Context
  • uuid string
  • version string
  • group string
  • tags []string

func (*MockInternalClient_Expecter) UploadProject

func (_e *MockInternalClient_Expecter) UploadProject(ctx interface{}, name interface{}, version interface{}, parentUuid interface{}, autoCreate interface{}, bom interface{}) *MockInternalClient_UploadProject_Call

UploadProject is a helper method to define mock.On call

  • ctx context.Context
  • name string
  • version string
  • parentUuid string
  • autoCreate bool
  • bom []byte

func (*MockInternalClient_Expecter) Version

func (_e *MockInternalClient_Expecter) Version(ctx interface{}) *MockInternalClient_Version_Call

Version is a helper method to define mock.On call

  • ctx context.Context

type MockInternalClient_GenerateApiKey_Call

type MockInternalClient_GenerateApiKey_Call struct {
	*mock.Call
}

MockInternalClient_GenerateApiKey_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GenerateApiKey'

func (*MockInternalClient_GenerateApiKey_Call) Return

func (*MockInternalClient_GenerateApiKey_Call) Run

func (*MockInternalClient_GenerateApiKey_Call) RunAndReturn

type MockInternalClient_GetConfigProperties_Call

type MockInternalClient_GetConfigProperties_Call struct {
	*mock.Call
}

MockInternalClient_GetConfigProperties_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetConfigProperties'

func (*MockInternalClient_GetConfigProperties_Call) Return

func (*MockInternalClient_GetConfigProperties_Call) Run

func (*MockInternalClient_GetConfigProperties_Call) RunAndReturn

type MockInternalClient_GetCurrentProjectMetric_Call

type MockInternalClient_GetCurrentProjectMetric_Call struct {
	*mock.Call
}

MockInternalClient_GetCurrentProjectMetric_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetCurrentProjectMetric'

func (*MockInternalClient_GetCurrentProjectMetric_Call) Return

func (*MockInternalClient_GetCurrentProjectMetric_Call) Run

func (*MockInternalClient_GetCurrentProjectMetric_Call) RunAndReturn

type MockInternalClient_GetEcosystems_Call

type MockInternalClient_GetEcosystems_Call struct {
	*mock.Call
}

MockInternalClient_GetEcosystems_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetEcosystems'

func (*MockInternalClient_GetEcosystems_Call) Return

func (*MockInternalClient_GetEcosystems_Call) Run

func (*MockInternalClient_GetEcosystems_Call) RunAndReturn

type MockInternalClient_GetFindings_Call

type MockInternalClient_GetFindings_Call struct {
	*mock.Call
}

MockInternalClient_GetFindings_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetFindings'

func (*MockInternalClient_GetFindings_Call) Return

func (*MockInternalClient_GetFindings_Call) Run

func (*MockInternalClient_GetFindings_Call) RunAndReturn

type MockInternalClient_GetOidcUsers_Call

type MockInternalClient_GetOidcUsers_Call struct {
	*mock.Call
}

MockInternalClient_GetOidcUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetOidcUsers'

func (*MockInternalClient_GetOidcUsers_Call) Return

func (*MockInternalClient_GetOidcUsers_Call) Run

func (*MockInternalClient_GetOidcUsers_Call) RunAndReturn

type MockInternalClient_GetProjectMetricsByDate_Call

type MockInternalClient_GetProjectMetricsByDate_Call struct {
	*mock.Call
}

MockInternalClient_GetProjectMetricsByDate_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetProjectMetricsByDate'

func (*MockInternalClient_GetProjectMetricsByDate_Call) Return

func (*MockInternalClient_GetProjectMetricsByDate_Call) Run

func (*MockInternalClient_GetProjectMetricsByDate_Call) RunAndReturn

type MockInternalClient_GetProject_Call

type MockInternalClient_GetProject_Call struct {
	*mock.Call
}

MockInternalClient_GetProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetProject'

func (*MockInternalClient_GetProject_Call) Return

func (*MockInternalClient_GetProject_Call) Run

func (*MockInternalClient_GetProject_Call) RunAndReturn

type MockInternalClient_GetProjectsByTag_Call

type MockInternalClient_GetProjectsByTag_Call struct {
	*mock.Call
}

MockInternalClient_GetProjectsByTag_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetProjectsByTag'

func (*MockInternalClient_GetProjectsByTag_Call) Return

func (*MockInternalClient_GetProjectsByTag_Call) Run

func (*MockInternalClient_GetProjectsByTag_Call) RunAndReturn

type MockInternalClient_GetProjects_Call

type MockInternalClient_GetProjects_Call struct {
	*mock.Call
}

MockInternalClient_GetProjects_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetProjects'

func (*MockInternalClient_GetProjects_Call) Return

func (*MockInternalClient_GetProjects_Call) Run

func (*MockInternalClient_GetProjects_Call) RunAndReturn

type MockInternalClient_GetTeam_Call

type MockInternalClient_GetTeam_Call struct {
	*mock.Call
}

MockInternalClient_GetTeam_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTeam'

func (*MockInternalClient_GetTeam_Call) Return

func (*MockInternalClient_GetTeam_Call) Run

func (*MockInternalClient_GetTeam_Call) RunAndReturn

type MockInternalClient_GetTeams_Call

type MockInternalClient_GetTeams_Call struct {
	*mock.Call
}

MockInternalClient_GetTeams_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'GetTeams'

func (*MockInternalClient_GetTeams_Call) Return

func (*MockInternalClient_GetTeams_Call) Run

func (*MockInternalClient_GetTeams_Call) RunAndReturn

type MockInternalClient_Headers_Call

type MockInternalClient_Headers_Call struct {
	*mock.Call
}

MockInternalClient_Headers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Headers'

func (*MockInternalClient_Headers_Call) Return

func (*MockInternalClient_Headers_Call) Run

func (*MockInternalClient_Headers_Call) RunAndReturn

type MockInternalClient_PortfolioRefresh_Call

type MockInternalClient_PortfolioRefresh_Call struct {
	*mock.Call
}

MockInternalClient_PortfolioRefresh_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'PortfolioRefresh'

func (*MockInternalClient_PortfolioRefresh_Call) Return

func (*MockInternalClient_PortfolioRefresh_Call) Run

func (*MockInternalClient_PortfolioRefresh_Call) RunAndReturn

type MockInternalClient_RemoveAdminUsers_Call

type MockInternalClient_RemoveAdminUsers_Call struct {
	*mock.Call
}

MockInternalClient_RemoveAdminUsers_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'RemoveAdminUsers'

func (*MockInternalClient_RemoveAdminUsers_Call) Return

func (*MockInternalClient_RemoveAdminUsers_Call) Run

func (*MockInternalClient_RemoveAdminUsers_Call) RunAndReturn

type MockInternalClient_TriggerAnalysis_Call

type MockInternalClient_TriggerAnalysis_Call struct {
	*mock.Call
}

MockInternalClient_TriggerAnalysis_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'TriggerAnalysis'

func (*MockInternalClient_TriggerAnalysis_Call) Return

func (*MockInternalClient_TriggerAnalysis_Call) Run

func (*MockInternalClient_TriggerAnalysis_Call) RunAndReturn

type MockInternalClient_UpdateProjectInfo_Call

type MockInternalClient_UpdateProjectInfo_Call struct {
	*mock.Call
}

MockInternalClient_UpdateProjectInfo_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateProjectInfo'

func (*MockInternalClient_UpdateProjectInfo_Call) Return

func (*MockInternalClient_UpdateProjectInfo_Call) Run

func (*MockInternalClient_UpdateProjectInfo_Call) RunAndReturn

type MockInternalClient_UpdateProject_Call

type MockInternalClient_UpdateProject_Call struct {
	*mock.Call
}

MockInternalClient_UpdateProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UpdateProject'

func (*MockInternalClient_UpdateProject_Call) Return

func (*MockInternalClient_UpdateProject_Call) Run

func (*MockInternalClient_UpdateProject_Call) RunAndReturn

type MockInternalClient_UploadProject_Call

type MockInternalClient_UploadProject_Call struct {
	*mock.Call
}

MockInternalClient_UploadProject_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'UploadProject'

func (*MockInternalClient_UploadProject_Call) Return

func (*MockInternalClient_UploadProject_Call) Run

func (_c *MockInternalClient_UploadProject_Call) Run(run func(ctx context.Context, name string, version string, parentUuid string, autoCreate bool, bom []byte)) *MockInternalClient_UploadProject_Call

func (*MockInternalClient_UploadProject_Call) RunAndReturn

type MockInternalClient_Version_Call

type MockInternalClient_Version_Call struct {
	*mock.Call
}

MockInternalClient_Version_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Version'

func (*MockInternalClient_Version_Call) Return

func (*MockInternalClient_Version_Call) Run

func (*MockInternalClient_Version_Call) RunAndReturn

type ProjectMetric

type ProjectMetric struct {
	ProjectID            uuid.UUID
	VulnerabilityMetrics []*VulnerabilityMetrics
}

type VulnerabilityMetrics

type VulnerabilityMetrics struct {
	Total           int   `json:"total"`
	RiskScore       int   `json:"riskScore"`
	Critical        int   `json:"critical"`
	High            int   `json:"high"`
	Medium          int   `json:"medium"`
	Low             int   `json:"low"`
	Unassigned      int   `json:"unassigned"`
	FirstOccurrence int64 `json:"firstOccurrence"`
	LastOccurrence  int64 `json:"lastOccurrence"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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