Skip to content

Revert "do not run e2e and unit test action if only docs update" #8

Revert "do not run e2e and unit test action if only docs update"

Revert "do not run e2e and unit test action if only docs update" #8

Workflow file for this run

name: Run E2E Tests
on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]
jobs:
playwright:
name: 'Playwright Tests'
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
- name: Install dependencies
run: yarn install
- name: Build packages
run: yarn build
- name: Set Up Starship Infrastructure
id: starship-infra
uses: hyperweb-io/starship-action@1.0.0
with:
config: e2e/starship/configs/osmosis-cosmoshub.yaml
- name: Install Playwright browsers
run: cd e2e && npx playwright install --with-deps chromium
# 運行所有 E2E 測試
- name: Run All E2E Tests
run: yarn test:e2e
# 上傳測試報告
- name: Upload test results
if: always()
uses: actions/upload-artifact@v4
with:
name: playwright-report
path: e2e/playwright-report/
retention-days: 30
# 上傳測試截圖
- name: Upload screenshots
if: failure()
uses: actions/upload-artifact@v4
with:
name: test-screenshots
path: e2e/test-results/
retention-days: 7