@@ -727,23 +727,22 @@ var _ = Describe("Bundle", Ordered, Label("Feature:TrustManager"), func() {
727727 WithFilterExpiredCertificates (v1alpha1 .FilterExpiredCertificatesPolicyEnabled ))
728728
729729 sourceCMName = "filter-src-cm-" + randomStr (5 )
730+ filterBundleName = "bundle-filter-expired-" + randomStr (5 )
730731 combinedPEM := testCertPEM1 + expiredCertPEM
731732
732733 By ("creating source ConfigMap with valid + expired certs in trust namespace" )
733734 createSourceConfigMap (ctx , trustManagerNamespace , sourceCMName , bundleSourceKey , combinedPEM )
734- })
735- AfterAll (func () { deleteTrustManager (ctx ) })
736-
737- It ("should exclude expired certificates from ConfigMap target when using ConfigMap source" , func () {
738- filterBundleName = "bundle-filter-expired-" + randomStr (5 )
739735
740736 bundle := newBundle (filterBundleName ).
741737 WithConfigMapSource (sourceCMName , bundleSourceKey ).
742738 WithConfigMapTarget (bundleTargetKey ).
743739 Build ()
744740
745741 createBundleWithCleanup (ctx , bundle )
742+ })
743+ AfterAll (func () { deleteTrustManager (ctx ) })
746744
745+ It ("should exclude expired certificates from ConfigMap target when using ConfigMap source" , func () {
747746 By ("verifying target contains the valid certificate" )
748747 err := waitForConfigMapTarget (ctx , bundleClient , filterBundleName , testNS .Name , bundleTargetKey , testCertPEM1 , highTimeout )
749748 Expect (err ).ShouldNot (HaveOccurred ())
0 commit comments