Documentation ¶
Overview ¶
package failurehandler provides functions to help with extra debugging when Gomega assertions fail
Example using Gomega's `Eventually` ¶
Eventually(wait.IsAllAppDeployed(state.GetContext(), state.GetFramework().MC(), appNamespacedNames)). WithTimeout(timeout). WithPolling(10*time.Second). Should( BeTrue(), failurehandler.AppIssues(state.GetContext(), state.GetFramework(), state.GetCluster()), )
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FailureHandler ¶
type FailureHandler interface{}
FailureHandler is a function that can be used with Gomega to perform extra debugging when an assertion fails Note: Needs to be `interface{}` for Gomega to accept this alias type
func AppIssues ¶
func AppIssues(ctx context.Context, framework *clustertest.Framework, cluster *application.Cluster) FailureHandler
AppIssues produces debugging information from app-operator (on the MC) and chart-operator (on the WC) This function will log out the status of the deployments, any related Events found and the last 25 lines of logs from the pods.
func Wrap ¶
func Wrap(fn func()) FailureHandler
Wrap returns a valid FailureHandler for the given function
Click to show internal directories.
Click to hide internal directories.