From 8abcc14dd12529f08904606fb75d5d3231ce9de2 Mon Sep 17 00:00:00 2001 From: Bryce Palmer Date: Thu, 8 Jun 2023 15:00:33 -0400 Subject: [PATCH] missed some Signed-off-by: Bryce Palmer --- test/e2e/e2e_suite_test.go | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/test/e2e/e2e_suite_test.go b/test/e2e/e2e_suite_test.go index 0814dcfc6..4df4ad81a 100644 --- a/test/e2e/e2e_suite_test.go +++ b/test/e2e/e2e_suite_test.go @@ -78,29 +78,24 @@ var _ = BeforeSuite(func() { var _ = AfterSuite(func() { ctx := context.Background() - err := c.Delete(ctx, operatorCatalog) - Expect(err).ToNot(HaveOccurred()) + Expect(c.Delete(ctx, operatorCatalog)).To(Succeed()) Eventually(func(g Gomega) { - err = c.Get(ctx, types.NamespacedName{Name: operatorCatalog.Name}, &catalogd.Catalog{}) + err := c.Get(ctx, types.NamespacedName{Name: operatorCatalog.Name}, &catalogd.Catalog{}) Expect(errors.IsNotFound(err)).To(BeTrue()) }).Should(Succeed()) // speed up delete without waiting for gc - err = c.DeleteAllOf(ctx, &catalogd.BundleMetadata{}) - Expect(err).ToNot(HaveOccurred()) - err = c.DeleteAllOf(ctx, &catalogd.Package{}) - Expect(err).ToNot(HaveOccurred()) + Expect(c.DeleteAllOf(ctx, &catalogd.BundleMetadata{})).To(Succeed()) + Expect(c.DeleteAllOf(ctx, &catalogd.Package{})).To(Succeed()) Eventually(func(g Gomega) { // ensure resource cleanup packages := &catalogd.PackageList{} - err = c.List(ctx, packages) - g.Expect(err).To(BeNil()) + g.Expect(c.List(ctx, packages)).To(Succeed()) g.Expect(packages.Items).To(BeEmpty()) bmd := &catalogd.BundleMetadataList{} - err = c.List(ctx, bmd) - g.Expect(err).To(BeNil()) + g.Expect(c.List(ctx, bmd)).To(Succeed()) g.Expect(bmd.Items).To(BeEmpty()) }).Should(Succeed()) })