You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was experimenting with what happens when I use HaveField with a field name that doesn't exist:
gomega.Eventually(getNewCalls).WithTimeout(registrationTimeout).Should(gomega.HaveExactElements(
gomega.And(
gomega.HaveField("FullMethod", "/pluginregistration.Registration/GetInfo"),
gomega.HaveField("Err", gomega.BeNil()),
),
gomega.And(
gomega.HaveField("FullMethod", "/pluginregistration.Registration/NotifyRegistrationStatus"),
gomega.HaveField("Err2", gomega.BeNil()),
),
), "kubelet plugin should be registered via two calls, GetInfo and NotifyRegistrationStatus")
ah good catch. looks like an issue in HaveExactElements - it's calling FailureMessage on HaveField when it should instead be reporting the error returned by HaveField.
I was experimenting with what happens when I use
HaveField
with a field name that doesn't exist:getNewCalls
returns a slice ofI expected to get some failure message pointing out that there is no
Err2
field (Err
is correct).Instead I got:
The text was updated successfully, but these errors were encountered: