Skip to content

Commit 79820dc

Browse files
committed
e2e support: return AppWrapper pointers instead of structs
1 parent 86b35a4 commit 79820dc

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

test/support/mcad.go

+10-3
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,18 @@ func AppWrapper(t Test, namespace *corev1.Namespace, name string) func(g gomega.
3232
}
3333
}
3434

35-
func AppWrappers(t Test, namespace *corev1.Namespace) func(g gomega.Gomega) []mcadv1beta1.AppWrapper {
36-
return func(g gomega.Gomega) []mcadv1beta1.AppWrapper {
35+
func AppWrappers(t Test, namespace *corev1.Namespace) func(g gomega.Gomega) []*mcadv1beta1.AppWrapper {
36+
return func(g gomega.Gomega) []*mcadv1beta1.AppWrapper {
3737
aws, err := t.Client().MCAD().WorkloadV1beta1().AppWrappers(namespace.Name).List(t.Ctx(), metav1.ListOptions{})
3838
g.Expect(err).NotTo(gomega.HaveOccurred())
39-
return aws.Items
39+
40+
awsp := []*mcadv1beta1.AppWrapper{}
41+
for _, v := range aws.Items {
42+
v := v
43+
awsp = append(awsp, &v)
44+
}
45+
46+
return awsp
4047
}
4148
}
4249

0 commit comments

Comments
 (0)