Skip to content

Commit

Permalink
Bulk upgrade test case #1230 (#1324)
Browse files Browse the repository at this point in the history
  • Loading branch information
omgoswami authored Jul 8, 2024
1 parent c582411 commit dcc6424
Show file tree
Hide file tree
Showing 8 changed files with 257 additions and 29 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ jobs:
eval $(minikube -p minikube docker-env)
echo "Glibc version"
ldd --version
sudo apt-get install python3-lxml
echo "Installing helm..."
wget https://get.helm.sh/helm-v3.12.1-linux-amd64.tar.gz
gunzip helm-v3.12.1-linux-amd64.tar.gz
Expand Down Expand Up @@ -113,8 +114,11 @@ jobs:
kubectl delete resourcecomposition wordpress-service-composition --kubeconfig=kubeplus-saas-provider.json
echo "Running tests..starting in 5 seconds"
sleep 5
source venv/bin/activate
cd tests
python3 -m venv venv
source venv/bin/activate
pip3 install -r requirements.txt
python3 -m unittest -v tests
deactivate
cd ../..
mv kubeplus $runner_dir
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
pyyaml
pyyaml
Binary file not shown.
Binary file not shown.
43 changes: 43 additions & 0 deletions tests/application-upgrade/resource-composition-localchart.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
apiVersion: workflows.kubeplus/v1alpha1
kind: ResourceComposition
metadata:
name: basic-web-app-service-composition
spec:
newResource:
chartName: basicwebapp
chartURL: file:///resource-composition-0.0.1.tgz
resource:
group: platformapi.kubeplus
kind: WebAppService
plural: webappservices
version: v1alpha1
resmonitor:
apiVersion: workflows.kubeplus/v1alpha1
kind: ResourceMonitor
metadata:
name: web-app-service-monitor
spec:
monitorRelationships: all
resource:
group: platformapi.kubeplus
kind: WebAppService
version: v1alpha1
respolicy:
apiVersion: workflows.kubeplus/v1alpha1
kind: ResourcePolicy
metadata:
name: web-app-service-policy
spec:
policy:
podconfig:
limits:
cpu: 200m
memory: 2Gi
nodeSelector: values.nodeName
requests:
cpu: 100m
memory: 1Gi
resource:
group: platformapi.kubeplus
kind: WebAppService
version: v1alpha1
6 changes: 6 additions & 0 deletions tests/application-upgrade/tenant1.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apiVersion: platformapi.kubeplus/v1alpha1
kind: WebAppService
metadata:
name: bwa-tenant1
spec:
nodeName: minikube
4 changes: 4 additions & 0 deletions tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
pyyaml
kubernetes
bs4
lxml
Loading

0 comments on commit dcc6424

Please sign in to comment.