@@ -17,17 +17,30 @@ limitations under the License.
17
17
package previous_version
18
18
19
19
import (
20
+ "fmt"
21
+
20
22
"github.com/feast-dev/feast/infra/feast-operator/test/utils"
21
23
. "github.com/onsi/ginkgo/v2"
24
+ . "github.com/onsi/gomega"
22
25
)
23
26
24
27
var _ = Describe ("previous version operator" , Ordered , func () {
28
+ namespace := "test-ns-feast"
29
+
25
30
BeforeAll (func () {
26
31
utils .DeployPreviousVersionOperator ()
32
+
33
+ By (fmt .Sprintf ("Creating test namespace: %s" , namespace ))
34
+ err := utils .CreateNamespace (namespace , "/test/e2e" )
35
+ Expect (err ).ToNot (HaveOccurred (), fmt .Sprintf ("failed to create namespace %s" , namespace ))
27
36
})
28
37
29
38
AfterAll (func () {
30
39
utils .DeleteOperatorDeployment ("/test/upgrade" )
40
+
41
+ By (fmt .Sprintf ("Deleting test namespace: %s" , namespace ))
42
+ err := utils .DeleteNamespace (namespace , "/test/e2e" )
43
+ Expect (err ).ToNot (HaveOccurred (), fmt .Sprintf ("failed to delete namespace %s" , namespace ))
31
44
})
32
45
33
46
Context ("Previous version operator Tests" , func () {
@@ -38,9 +51,9 @@ var _ = Describe("previous version operator", Ordered, func() {
38
51
}
39
52
40
53
runTestDeploySimpleCRFunc := utils .GetTestDeploySimpleCRFunc ("/test/upgrade" , utils .GetSimplePreviousVerCR (),
41
- utils .FeatureStoreName , utils .FeastResourceName , feastK8sResourceNames , "default" )
54
+ utils .FeatureStoreName , utils .FeastResourceName , feastK8sResourceNames , namespace )
42
55
runTestWithRemoteRegistryFunction := utils .GetTestWithRemoteRegistryFunc ("/test/upgrade" , utils .GetSimplePreviousVerCR (),
43
- utils .GetRemoteRegistryPreviousVerCR (), utils .FeatureStoreName , utils .FeastResourceName , feastK8sResourceNames , "default" )
56
+ utils .GetRemoteRegistryPreviousVerCR (), utils .FeatureStoreName , utils .FeastResourceName , feastK8sResourceNames , namespace )
44
57
45
58
// Run Test on previous version operator
46
59
It ("Should be able to deploy and run a default feature store CR successfully" , runTestDeploySimpleCRFunc )
0 commit comments