@@ -80,13 +80,13 @@ var _ = Describe("Pod webhook", func() {
80
80
81
81
By ("Checking that validation sidecar was created" )
82
82
found := & corev1.Pod {}
83
- Eventually (func () error {
83
+ Eventually (ctx , func (ctx context. Context ) error {
84
84
return k8sClient .Get (ctx , typeNamespaceName , found )
85
85
}).Should (Succeed ())
86
86
87
- Eventually (
88
- func (_ Gomega ) []corev1.Container {
89
- Expect (k8sClient .Get (ctx , typeNamespaceName , found )).To (Succeed ())
87
+ Eventually (ctx ,
88
+ func (g Gomega , ctx context. Context ) []corev1.Container {
89
+ g . Expect (k8sClient .Get (ctx , typeNamespaceName , found )).To (Succeed ())
90
90
return found .Spec .InitContainers
91
91
},
92
92
).Should (And (
@@ -112,7 +112,7 @@ var _ = Describe("Pod webhook", func() {
112
112
113
113
By ("Waiting for pod to be injected" )
114
114
found := & corev1.Pod {}
115
- Eventually (func () []corev1.Container {
115
+ Eventually (ctx , func (ctx context. Context ) []corev1.Container {
116
116
_ = k8sClient .Get (ctx , types.NamespacedName {Name : "tracked-pod" , Namespace : Namespace }, found )
117
117
return found .Spec .InitContainers
118
118
}).Should (HaveLen (1 ))
@@ -122,7 +122,7 @@ var _ = Describe("Pod webhook", func() {
122
122
123
123
By ("Checking ModelValidation status was updated" )
124
124
mv := & v1alpha1.ModelValidation {}
125
- Eventually (func () int32 {
125
+ Eventually (ctx , func (ctx context. Context ) int32 {
126
126
_ = k8sClient .Get (ctx , typeNamespaceName , mv )
127
127
return mv .Status .InjectedPodCount
128
128
}, 5 * time .Second ).Should (BeNumerically (">" , 0 ))
0 commit comments