Skip to content

Commit

Permalink
Use HaveOccurred() for E2E error checking
Browse files Browse the repository at this point in the history
Signed-off-by: Dale Haiducek <[email protected]>
(cherry picked from commit dee3a70)
  • Loading branch information
dhaiducek authored and magic-mirror-bot[bot] committed Feb 19, 2024
1 parent 7e6a34b commit 41d31c0
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/utils/utils.go
Original file line number Diff line number Diff line change
Expand Up @@ -160,7 +160,7 @@ func GetClusterLevelWithTimeout(
}

return nil
}, timeout, 1).Should(BeNil())
}, timeout, 1).ShouldNot(HaveOccurred())

if wantFound {
return obj
Expand Down Expand Up @@ -202,7 +202,7 @@ func GetWithTimeout(
}

return nil
}, timeout, 1).Should(BeNil())
}, timeout, 1).ShouldNot(HaveOccurred())

if wantFound {
return obj
Expand Down Expand Up @@ -239,7 +239,7 @@ func ListWithTimeout(
}

return nil
}, timeout, 1).Should(BeNil())
}, timeout, 1).ShouldNot(HaveOccurred())

if wantFound {
return list
Expand Down Expand Up @@ -277,7 +277,7 @@ func ListWithTimeoutByNamespace(
}

return nil
}, timeout, 1).Should(BeNil())
}, timeout, 1).ShouldNot(HaveOccurred())

if wantFound {
return list
Expand Down

0 comments on commit 41d31c0

Please sign in to comment.