@@ -23,3 +23,39 @@ Feature: Solutions
2323 And we delete the Solution Configuration file
2424 Then we have no Solution 'example-solution' archive mounted
2525 And we have no Solution Configuration file present
26+
27+ @solution-upgrade
28+ Scenario : Upgrade Solution
29+ Given the Kubernetes API is available
30+ And no Solution 'example-solution' is imported
31+ And no Solution environment 'example-environment' is available
32+ And the Solution Configuration file is absent
33+ When we import a Solution archive '/var/tmp/example-solution.iso'
34+ Then Solution archive 'example-solution' is imported correctly
35+ And Solution 'example-solution' version '1.1.0' is available
36+ When we activate Solution 'example-solution' version '1.1.0'
37+ Then Solution 'example-solution' version '1.1.0' is activated
38+ And CRD 'versionservers.metalk8s-solution-example.scality.com' exists in Kubernetes API
39+ And CRD 'clockservers.metalk8s-solution-example.scality.com' exists in Kubernetes API
40+ When we create a solution environment 'example-environment'
41+ Then solution environment 'example-environment' is available
42+ When we deploy Solution 'example-solution' in environment 'example-environment' with version '1.1.0'
43+ Then we have 1 running pod labeled 'app=example-solution-operator' in namespace 'example-environment'
44+ When we import a Solution archive '/var/tmp/example-solution-next.iso'
45+ Then Solution archive 'example-solution-next' is imported correctly
46+ And Solution 'example-solution-next' version '1.1.1' is available
47+ When we activate Solution 'example-solution-next' version '1.1.1'
48+ Then Solution 'example-solution-next' version '1.1.1' is activated
49+ And CRD 'versionservers.example-solution-next.metalk8s.scality.com' exists in Kubernetes API
50+ And CRD 'clockservers.example-solution-next.metalk8s.scality.com' exists in Kubernetes API
51+ When we deploy Solution 'example-solution' in environment 'example-environment' with version '1.1.1'
52+ Then we have 1 running pod labeled 'app=example-solution-operator,app.kubernetes.io/version=1.1.1' in namespace 'example-environment'
53+ When we unimport Solution archive '/var/tmp/example-solution.iso'
54+ Then we have 1 running pod labeled 'app=example-solution-operator' in namespace 'example-environment'
55+ When we deactivate Solution 'example-solution'
56+ And we delete Solution 'example-solution' in environment 'example-environment'
57+ And we delete Solution environment 'example-environment'
58+ And we unimport Solution archive '/var/tmp/example-solution-next.iso'
59+ And we delete the Solution Configuration file
60+ Then we have no Solution 'example-solution' archive mounted
61+ And we have no Solution Configuration file present
0 commit comments