End-to-end certifier #45
Workflow file for this run
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: 'End-to-end certifier' | |
| permissions: | |
| actions: read | |
| contents: read | |
| on: | |
| workflow_dispatch: | |
| inputs: | |
| environment: | |
| description: The environment in which to run the job | |
| default: dev | |
| region: | |
| description: The region in which to run the job | |
| default: us-east-1 | |
| package: | |
| description: The package name | |
| job: | |
| description: The name of the job (as defined in the deployment config) | |
| extra: | |
| description: Extra parameters passed from the deployment config | |
| default: '{"JSUI_VERSION":""}' | |
| workflow_call: | |
| jobs: | |
| e2e-certifier: | |
| runs-on: ubuntu-24.04 | |
| steps: | |
| - name: Harden the runner (Audit all outbound calls) | |
| uses: step-security/harden-runner@f4a75cfd619ee5ce8d5b864b0d183aff3c69b55a # v2.13.1 | |
| with: | |
| egress-policy: audit | |
| - name: Deploy JSUI beta version on Netlify | |
| # Only run this step if a JSUI_VERSION has been specified: | |
| if: ${{ github.event_name == 'workflow_dispatch' && fromJSON(inputs.extra).JSUI_VERSION != '' }} | |
| run: curl --request POST https://api.netlify.com/build_hooks/${{ secrets.NETLIFY_BUILD_HOOK_ID }} | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Install test dependencies | |
| working-directory: ${{ github.workspace }}/playwright | |
| run: npm install && npx playwright install --with-deps | |
| - name: Validate JSUI version | |
| # Only run this step if a JSUI_VERSION has been specified: | |
| if: ${{ github.event_name == 'workflow_dispatch' && fromJSON(inputs.extra).JSUI_VERSION != '' }} | |
| working-directory: ${{ github.workspace }}/playwright | |
| env: | |
| JSUI_VERSION: ${{ fromJSON(inputs.extra || '{"JSUI_VERSION":""}').JSUI_VERSION }} | |
| run: npm run validate-jsui-version | |
| - name: Run tests | |
| working-directory: ${{ github.workspace }}/playwright | |
| run: npm test | |
| - uses: actions/upload-artifact@v4 | |
| if: failure() || success() | |
| with: | |
| name: playwright-report-html | |
| path: playwright/playwright-report/ | |
| retention-days: 3 | |
| - uses: actions/upload-artifact@v4 | |
| if: failure() || success() | |
| with: | |
| name: playwright-report-json | |
| path: playwright/test-results.json | |
| retention-days: 30 |