kuttl
kuttl copied to clipboard
Show content of unexpected resources
What would you like to be added:
Just like kuttl shows a diff between expected and actual resource for assert.yaml files, it should show the content of the actual resource when an errors.yaml says that the resource should not exist (i.e. when the expected resource specifies just apiVersion, kind and metadata.name).
Why is this needed:
Currently all that is printed is:
case.go:363: resource matched of kind: authorization.openshift.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: authorization.openshift.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: authorization.openshift.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: rbac.authorization.k8s.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: rbac.authorization.k8s.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: rbac.authorization.k8s.io/v1, Kind=ClusterRole
case.go:363: resource matched of kind: /v1, Kind=ConfigMap
Which is not terribly useful - in order to investigate the cause for unexpected existence of a resource I'd like to see its metadata (to see owner references for example) and status (which might show details of why it was not deleted).