INTER-2069 Recurrent care #250
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: Test e2e for PR | |
| on: | |
| pull_request: | |
| jobs: | |
| check_changed_files: | |
| runs-on: ubuntu-latest | |
| name: Check changed files | |
| outputs: | |
| any_changed: ${{ steps.files.outputs.test_any_changed }} | |
| steps: | |
| - uses: actions/checkout@v7 | |
| with: | |
| fetch-depth: 0 | |
| - id: files | |
| uses: step-security/changed-files@2e07db73e5ccdb319b9a6c7766bd46d39d304bad # v47 | |
| with: | |
| files_yaml: | | |
| test: | |
| - assets/** | |
| - generators/** | |
| - build.ts | |
| - "**/*ci.yml" | |
| build-and-test-e2e: | |
| runs-on: ubuntu-latest | |
| name: Test e2e for PR | |
| needs: check_changed_files | |
| if: needs.check_changed_files.outputs.any_changed == 'true' | |
| steps: | |
| - uses: actions/checkout@v7 | |
| - name: 'Install pnpm' | |
| uses: pnpm/action-setup@0ebf47130e4866e96fce0953f49152a61190b271 # v6.0.9 | |
| - name: Install node | |
| uses: actions/setup-node@v6 | |
| with: | |
| node-version-file: '.node-version' | |
| - name: Install dependencies | |
| run: pnpm install | |
| - name: Install Playwright | |
| run: pnpm exec playwright install | |
| - name: Extract Branch Name | |
| id: extract-branch | |
| run: | | |
| echo SUBDOMAIN=$(echo ${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}} | perl -pe 's/[^a-zA-Z0-9]+/-/g and s/-+$//g' | tr '[:upper:]' '[:lower:]') >> $GITHUB_OUTPUT | |
| - name: Run test | |
| run: pnpm test:e2e | |
| env: | |
| TEST_DOMAIN: 'https://${{steps.extract-branch.outputs.SUBDOMAIN}}.${{secrets.FPJS_CI_DOMAIN}}' | |
| TEST_RESULT_DOMAIN: ${{secrets.TEST_RESULT_DOMAIN}} | |
| TEST_RESULT_PATH: ${{secrets.TEST_RESULT_PATH}} | |
| INTEGRATION_PATH: ${{secrets.INTEGRATION_PATH}} | |
| RESULT_PATH: ${{secrets.RESULT_PATH}} | |
| AGENT_PATH: ${{secrets.AGENT_PATH}} | |
| FPJS_API_KEY: ${{secrets.FPJS_API_KEY}} |