Documentation ¶
Index ¶
- Constants
- type GCP
- func (g GCP) EnableApis(t testing.TB, project string, apis []string)
- func (g GCP) GetBuildStatus(t testing.TB, projectID, region, buildID string) string
- func (g GCP) GetBuilds(t testing.TB, projectID, region, filter string) map[string]string
- func (g GCP) GetFinalBuildState(t testing.TB, projectID, region, buildID string, maxRetry int) (string, error)
- func (g GCP) GetLastBuildStatus(t testing.TB, projectID, region, filter string) string
- func (g GCP) GetRunningBuildID(t testing.TB, projectID, region, filter string) string
- func (g GCP) HasSccNotification(t testing.TB, orgID, sccName string) bool
- func (g GCP) HasTagKey(t testing.TB, orgID, tag string) bool
- func (g GCP) IsApiEnabled(t testing.TB, project, api string) bool
- func (g GCP) WaitBuildSuccess(t testing.TB, project, region, repo, commitSha, failureMsg string, ...) error
Constants ¶
View Source
const ( StatusQueued = "QUEUED" StatusWorking = "WORKING" StatusSuccess = "SUCCESS" StatusFailure = "FAILURE" StatusCancelled = "CANCELLED" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GCP ¶
type GCP struct { Runf func(t testing.TB, cmd string, args ...interface{}) gjson.Result // contains filtered or unexported fields }
func (GCP) EnableApis ¶
EnableApis enables the apis in the given project
func (GCP) GetBuildStatus ¶
GetBuildStatus gets the status of the given build
func (GCP) GetBuilds ¶
GetBuilds gets all Cloud Build builds form a project and region that satisfy the given filter.
func (GCP) GetFinalBuildState ¶
func (g GCP) GetFinalBuildState(t testing.TB, projectID, region, buildID string, maxRetry int) (string, error)
GetFinalBuildState gets the terminal status of the given build. It will wait if build is not finished.
func (GCP) GetLastBuildStatus ¶
GetLastBuildStatus gets the status of the last build form a project and region that satisfy the given filter.
func (GCP) GetRunningBuildID ¶
GetRunningBuildID gets the current build running for the given project, region, and filter
func (GCP) HasSccNotification ¶
HasSccNotification checks if a Security Command Center notification exists
func (GCP) IsApiEnabled ¶
IsApiEnabled checks if the api is enabled in the given project
Click to show internal directories.
Click to hide internal directories.