Skip to content

Commit

Permalink
chore: workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
justfizah authored Jan 7, 2025
1 parent 7c96cfe commit 348a122
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/playwright.yml
Original file line number Diff line number Diff line change
@@ -1,32 +1,54 @@
name: Playwright Tests

on:
push:
branches: [ main, master ]
pull_request:
branches: [ main, master ]

jobs:
test:
timeout-minutes: 60
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- uses: actions/setup-node@v4
with:
node-version: lts/*

- name: Enable Corepack
run: corepack enable

- name: Prepare Yarn
run: corepack prepare [email protected] --activate

- name: Install dependencies
run: yarn install

- name: Install Playwright Browsers
run: yarn playwright install --with-deps

- name: Build the application
run: yarn build # Ensure your app has a build step

- name: Start the application
run: yarn start &
env:
PORT: 3100

- name: Wait for the application to be ready
run: npx wait-on http://localhost:3100

- name: Run Playwright tests
run: yarn playwright test

- uses: actions/upload-artifact@v4
if: ${{ !cancelled() }}
with:
name: playwright-report
path: playwright-report/
retention-days: 30


0 comments on commit 348a122

Please sign in to comment.