-
Notifications
You must be signed in to change notification settings - Fork 80
38 lines (36 loc) · 1.19 KB
/
test.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
name: UI Automation Tests
on: pull_request
jobs:
playwright:
runs-on: ubuntu-latest
permissions: read-all
defaults:
run:
working-directory: "./wormhole-connect"
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 20
cache: "npm"
cache-dependency-path: "wormhole-connect/package-lock.json"
- name: Install dependencies
run: npm ci
- name: Install headless Chromium for Playwright Browser
run: npx playwright install --with-deps --no-shell
- name: Start localhost
run: npm run start &
env:
REACT_APP_TEST_EVM_ADDR: ${{ secrets.REACT_APP_TEST_EVM_ADDR }}
REACT_APP_TEST_EVM_PK: ${{ secrets.REACT_APP_TEST_EVM_PK }}
- name: Run Playwright tests
run: npm test:e2e
env:
REACT_APP_TEST_EVM_ADDR: ${{ secrets.REACT_APP_TEST_EVM_ADDR }}
REACT_APP_TEST_EVM_PK: ${{ secrets.REACT_APP_TEST_EVM_PK }}
- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: playwright-report
path: wormhole-connect/playwright-report/
retention-days: 30