mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-08-04 01:40:07 +00:00
Merge pull request #17427 from gmarek/expect-noerror
Log an error instantly in expectNoError
This commit is contained in:
commit
28a4adabb5
@ -916,6 +916,9 @@ func randomSuffix() string {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func expectNoError(err error, explain ...interface{}) {
|
func expectNoError(err error, explain ...interface{}) {
|
||||||
|
if err != nil {
|
||||||
|
Logf("Unexpected error occurred: %v", err)
|
||||||
|
}
|
||||||
ExpectWithOffset(1, err).NotTo(HaveOccurred(), explain...)
|
ExpectWithOffset(1, err).NotTo(HaveOccurred(), explain...)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user