Skip to content
This repository has been archived by the owner on Feb 16, 2024. It is now read-only.

Commit

Permalink
remove code
Browse files Browse the repository at this point in the history
Signed-off-by: Shubham Gupta <iamshubhamgupta2001@gmail.com>
  • Loading branch information
shubham-cmyk committed Sep 22, 2023
1 parent 9162533 commit 7595bde
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions pkg/test/step.go
Original file line number Diff line number Diff line change
Expand Up @@ -378,17 +378,6 @@ func (s *Step) CheckResource(expected assertArray, namespace string) []error {
return testErrors
}

func (s *Step) extractDataFromObject(obj client.Object, path string, resourceType string) ([]interface{}, error) {
data, found, err := unstructured.NestedSlice(obj.(runtime.Unstructured).UnstructuredContent(), strings.Split(path, "/")...)
if err != nil {
return nil, fmt.Errorf("failed to extract data from resource type %s at path '%s'. Error: %v", resourceType, path, err)
}
if !found {
return nil, fmt.Errorf("path '%s' not found in resource of type %s", path, resourceType)
}
return data, nil
}

// CheckResourceAbsent checks if the expected resource's state is absent in Kubernetes.
func (s *Step) CheckResourceAbsent(expected runtime.Object, namespace string) error {
cl, err := s.Client(false)
Expand Down

0 comments on commit 7595bde

Please sign in to comment.