11name : Build and test MicroK8s snap
22
33on :
4- pull_request :
5- branches :
6- - master
4+ - push
75
86jobs :
97 build :
5250 uses : ./.github/actions/test-prep
5351 - name : Running upgrade path test
5452 run : |
55- sudo -E UPGRADE_MICROK8S_FROM=latest/edge UPGRADE_MICROK8S_TO=$PWD/build/microk8s.snap pytest -s ./tests/test-upgrade-path.py
53+ sudo -E STRICT=yes UPGRADE_MICROK8S_FROM=latest/edge/strict UPGRADE_MICROK8S_TO=$PWD/build/microk8s.snap pytest -s ./tests/test-upgrade-path.py
5654
5755 test-addons-core :
5856 name : Test core addons
6967 UNDER_TIME_PRESSURE : ${{ !contains(github.event.pull_request.labels.*.name, 'run-all-tests') }}
7068 run : |
7169 set -x
72- sudo snap install build/microk8s.snap --classic --dangerous
70+ sudo snap install build/microk8s.snap --dangerous
71+ sudo /snap/microk8s/current/connect-all-interfaces.sh
72+ sudo microk8s status --wait-ready --timeout 300
7373 ./tests/smoke-test.sh
7474 export SKIP_PROMETHEUS="False"
75+ export STRICT="yes"
7576 sudo -E bash -c "cd /var/snap/microk8s/common/addons/core/tests; pytest -s -ra test-addons.py"
7677
7778 test-addons-community :
9091 run : |
9192 set -x
9293 sudo snap install build/microk8s.snap --classic --dangerous
94+ sudo /snap/microk8s/current/connect-all-interfaces.sh
95+ sudo microk8s status --wait-ready --timeout 300
9396 sudo microk8s enable community
97+ export STRICT="yes"
9498 sudo -E bash -c "cd /var/snap/microk8s/common/addons/community/; pytest -s -ra ./tests/"
9599
96100 test-addons-core-upgrade :
@@ -108,7 +112,8 @@ jobs:
108112 UNDER_TIME_PRESSURE : ${{ !contains(github.event.pull_request.labels.*.name, 'run-all-tests') }}
109113 run : |
110114 set -x
111- sudo -E bash -c "UPGRADE_MICROK8S_FROM=latest/edge UPGRADE_MICROK8S_TO=$PWD/build/microk8s.snap pytest -s ./tests/test-upgrade.py"
115+ export STRICT="yes"
116+ sudo -E bash -c "UPGRADE_MICROK8S_FROM=latest/edge/strict UPGRADE_MICROK8S_TO=$PWD/build/microk8s.snap pytest -s ./tests/test-upgrade.py"
112117
113118 test-cluster-agent :
114119 name : Cluster agent health check
@@ -124,6 +129,7 @@ jobs:
124129 run : |
125130 set -x
126131 sudo snap install build/microk8s.snap --classic --dangerous
132+ sudo /snap/microk8s/current/connect-all-interfaces.sh
127133 sudo -E bash -c "pytest -s ./tests/test-cluster-agent.py"
128134
129135 test-airgap :
0 commit comments