chore: credit E2E crackdown #1678
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: Pull Request | |
on: | |
pull_request: | |
types: | |
- opened | |
- synchronize | |
- reopened | |
- ready_for_review | |
defaults: | |
run: | |
working-directory: packages/client | |
env: | |
BUCKET_WEB: reactive-trader-web-builds | |
BUCKET_OPENFIN: reactive-trader-openfin-builds | |
ENVIRONMENT: env | |
jobs: | |
build: | |
name: Multi E2E | |
runs-on: ubuntu-20.04 | |
if: ${{ !github.event.pull_request.head.repo.fork }} | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Set Node version | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: Install dependencies | |
run: npm ci | |
# - name: Build (web) | |
# env: | |
# DOMAIN: https://web.env.reactivetrader.com | |
# URL_PATH: /pull/${{ github.event.number }} | |
# VITE_BUILD_VERSION: ${{ github.sha }} | |
# run: | | |
# npm run build | |
# - name: "Authenticate to Google Cloud" | |
# uses: "google-github-actions/auth@v2" | |
# with: | |
# credentials_json: "${{ secrets.GCLOUD_SERVICE_ACCOUNT_JSON }}" | |
# - name: Set up GCloud | |
# uses: google-github-actions/setup-gcloud@v2 | |
# with: | |
# project_id: ${{ secrets.GOOGLE_PROJECT_ID }} | |
# - name: Deploy (web) | |
# run: | | |
# gsutil -m \ | |
# -h "Cache-Control: no-cache" \ | |
# rsync -d -r dist \ | |
# gs://$BUCKET_WEB/pull/${{ github.event.number }} | |
- name: E2E Run 1 | |
id: e1 | |
continue-on-error: true | |
env: | |
E2E_RTC_WEB_ROOT_URL: https://web.env.reactivetrader.com/pull/${{ github.event.number }} | |
run: npx playwright test --project=web credit.spec.ts | |
- name: Artifact Upload | |
uses: actions/upload-artifact@v4 | |
if: steps.e1.outcome == 'failure' | |
with: | |
name: playwright-report-1 | |
path: packages/client/playwright-report/ | |
retention-days: 1 | |
- name: E2E Run 2 | |
id: e2 | |
continue-on-error: true | |
env: | |
E2E_RTC_WEB_ROOT_URL: https://web.env.reactivetrader.com/pull/${{ github.event.number }} | |
run: npx playwright test --project=web | |
- name: Artifact Upload | |
uses: actions/upload-artifact@v4 | |
if: steps.e2.outcome == 'failure' | |
with: | |
name: playwright-report-2 | |
path: packages/client/playwright-report/ | |
retention-days: 1 | |
- name: E2E Run 3 | |
id: e3 | |
continue-on-error: true | |
env: | |
E2E_RTC_WEB_ROOT_URL: https://web.env.reactivetrader.com/pull/${{ github.event.number }} | |
run: npx playwright test --project=web credit.spec.ts | |
- name: Artifact Upload | |
uses: actions/upload-artifact@v4 | |
if: steps.e3.outcome == 'failure' | |
with: | |
name: playwright-report-3 | |
path: packages/client/playwright-report/ | |
retention-days: 1 | |
- name: E2E Run 4 | |
id: e4 | |
continue-on-error: true | |
env: | |
E2E_RTC_WEB_ROOT_URL: https://web.env.reactivetrader.com/pull/${{ github.event.number }} | |
run: npx playwright test --project=web | |
- name: Artifact Upload | |
uses: actions/upload-artifact@v4 | |
if: steps.e4.outcome == 'failure' | |
with: | |
name: playwright-report-4 | |
path: packages/client/playwright-report/ | |
retention-days: 1 |