Skip to content

Commit

Permalink
Another version of regex
Browse files Browse the repository at this point in the history
  • Loading branch information
domhanak committed Feb 8, 2024
1 parent addad4e commit 1ffb9cf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion test/e2e/helpers.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func getHealthStatusInContainer(podName string, containerName string, ns string)
Expect(err).NotTo(HaveOccurred())
stringOutput := string(output)
fmt.Printf("Output transformed to string: %v\n", stringOutput)
reg, _ := regexp.Compile("(\\{(.*)\\](.*)\\})")
reg, _ := regexp.Compile("\\{.*\\].*\\}")
stringOutput = reg.FindString(stringOutput)
fmt.Printf("Found string using regex: %v\n", stringOutput)
err = json.Unmarshal([]byte(stringOutput), &h)
Expand Down

0 comments on commit 1ffb9cf

Please sign in to comment.