Extensions compatibility tests 2.10 #46
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Extensions Compatibility Tests 2.10 | |
on: | |
schedule: | |
- cron: "0 0 * * *" # runs at midnight every day | |
# TODO: DELETE THIS!!!! JUST FOR TESTING PURPOSES! | |
pull_request: | |
branches: | |
- master | |
env: | |
TEST_USERNAME: admin | |
TEST_PASSWORD: password | |
CATTLE_BOOTSTRAP_PASSWORD: password | |
TEST_BASE_URL: https://127.0.0.1:8005 | |
API: https://127.0.0.1 | |
TEST_PROJECT_ID: rancher-dashboard | |
CYPRESS_API_URL: http://139.59.134.103:1234/ | |
TEST_RUN_ID: ${{github.run_number}}-${{github.run_attempt}}-extensions-compatibility-tests | |
# Build the dashboard to use in tests. When set to false it will grab `latest` from CDN (useful for running e2e tests quickly) | |
BUILD_DASHBOARD: true | |
jobs: | |
e2e-test-extensions-compatibility: | |
strategy: | |
fail-fast: false | |
matrix: | |
role: [ | |
{ username: 'admin', tag: '@adminUser' } | |
] | |
features: [ | |
['@elemental', 'elemental'], | |
['@kubewarden', 'kubewarden'] | |
] | |
rancherEnv: [ | |
['v2.9-head', 'master'] | |
] | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
# ref: ${{ matrix.rancherEnv[1] }} TODO: should be removed after it get's merged | |
fetch-depth: 1 | |
- name: Setup env | |
uses: ./.github/actions/setup | |
# this is where docker is set up with the enviroment | |
- name: Run Rancher ${{ matrix.rancherEnv[0] }} - branch:${{ matrix.rancherEnv[1] }} | |
run: export RANCHER_VERSION_E2E=${{ matrix.rancherEnv[0] }} && yarn e2e:docker | |
## this is just setting up rancher and user | |
- name: Setup Rancher and user | |
run: | | |
yarn e2e:prod | |
env: | |
GREP_TAGS: ${{ matrix.role.tag }}Setup+${{ matrix.features[0] }} --@jenkins ${{ matrix.role.tag }}Setup+${{ matrix.features[0] }} --@jenkins | |
TEST_USERNAME: ${{ matrix.role.username }} | |
TEST_ONLY: setup | |
# This is the actual triggering of the e2e test specs | |
- name: Run user tests | |
run: | | |
export SPEC_FILE="cypress/e2e/tests/pages/extensions-compatibility-tests/${{ matrix.features[1] }}.spec.ts" && yarn e2e:prod | |
[ "$BUILD_DASHBOARD" != "false" ] || exit 0 | |
env: | |
TEST_SKIP: setup | |
GREP_TAGS: ${{ matrix.role.tag }}+${{ matrix.features[0] }} --@jenkins ${{ matrix.role.tag }}+${{ matrix.features[0] }} --@jenkins | |
TEST_USERNAME: ${{ matrix.role.username }} | |
- name: Upload screenshots | |
uses: actions/upload-artifact@v3 | |
if: ${{ failure() }} | |
with: | |
name: ${{github.run_number}}-${{github.run_attempt}}-extensions-compatibility-tests-screenshots-${{ matrix.role.tag }}+${{ matrix.features[0] }} | |
path: cypress/screenshots |