Juju dashboard integration test #54
This file contains hidden or 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: Juju dashboard integration test | |
| on: | |
| workflow_call: | |
| workflow_dispatch: | |
| pull_request: | |
| types: [labeled] | |
| schedule: | |
| # Run twice a week: Mondays and Wednesdays at 03:00 UTC | |
| - cron: '0 3 * * 1,3' | |
| jobs: | |
| test-dashboard: | |
| name: Test JIMM with the Juju dashboard | |
| runs-on: ubuntu-22.04 | |
| # This conditional ensures we only run the test when the test-dashboard label is added. | |
| # See https://stackoverflow.com/a/74829754 | |
| # Because we also call this from other events, we need to allow those too. | |
| # | |
| # Allow 'push' events as workflow_call passes the same event payload from the | |
| # calling workflow and we trigger releases on tag push. | |
| if: | | |
| github.event_name == 'workflow_dispatch' || | |
| github.event_name == 'schedule' || | |
| github.event_name == 'push' || | |
| contains(github.event.pull_request.labels.*.name, 'test-dashboard') | |
| steps: | |
| - name: Checkout JIMM repo | |
| uses: actions/checkout@v4 | |
| - name: Set up Docker Compose | |
| uses: docker/setup-compose-action@v1 | |
| - name: Setup Go | |
| uses: actions/setup-go@v4 | |
| with: | |
| go-version-file: 'go.mod' | |
| - name: Go vendor to speed up docker build | |
| run: go mod vendor | |
| - name: Start JIMM | |
| uses: ./.github/actions/test-server | |
| id: jaas | |
| with: | |
| jimm-version: dev | |
| juju-channel: "3.6/stable" | |
| ghcr-pat: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Run integration tests | |
| uses: canonical/juju-dashboard/.github/actions/run-playwright@f10fb23537cb3c652d664e92d5afa095e96fa433 | |
| with: | |
| test-identifier: e2e-jimm-docker-keycloak | |
| env: | |
| JIMM_CONTROLLER_NAME: jimm | |
| CONTROLLER_NAME: jimm | |
| DASHBOARD_ADDRESS: https://juju-dashboard.localhost | |
| AUTH_MODE: oidc | |
| AUTH_VARIANT: keycloak | |
| JUJU_ENV: jimm | |
| PROVIDER: localhost | |
| ADMIN_IDENTITY_USERNAME: jimm-test | |
| ADMIN_IDENTITY_PASSWORD: password |