Bump @playwright/test from 1.46.1 to 1.47.2 #68
Workflow file for this run
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: pr | |
on: pull_request | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
checks: | |
name: ✅ Checks | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
- name: Install dependencies | |
run: npm ci | |
- name: Biome check | |
run: npm run biome:ci | |
- name: Types and build checks | |
run: npm run build | |
test: | |
name: 🔚 E2E tests | |
timeout-minutes: 60 | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
- name: Install dependencies | |
run: npm ci | |
- name: Install Playwright Browsers | |
run: npm run test:init | |
- name: Run Playwright tests | |
run: npm test | |
- uses: actions/upload-artifact@v4 | |
if: always() | |
with: | |
name: playwright-report | |
path: playwright-report/ | |
retention-days: 30 | |
preview: | |
name: 🔮 Preview | |
runs-on: ubuntu-latest | |
env: | |
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }} | |
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }} | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: lts/* | |
- name: Install dependencies | |
run: npm ci | |
- name: Install Vercel CLI | |
run: npm i -g vercel | |
- name: Pull Vercel Environment Information | |
run: vercel pull --yes --environment=preview --token=${{ secrets.VERCEL_TOKEN }} | |
- name: Build Project Artifacts | |
run: vercel build --token=${{ secrets.VERCEL_TOKEN }} | |
- run: echo "PREVIEW_URL=$(vercel deploy --prebuilt --token=${{ secrets.VERCEL_TOKEN }})" >> $GITHUB_ENV | |
- name: Comment PR | |
uses: actions/github-script@v7 | |
with: | |
github-token: ${{secrets.GITHUB_TOKEN}} | |
script: | | |
const owner = context.repo.owner | |
const repo = context.repo.repo | |
const url = process.env.PREVIEW_URL | |
const { data: comments } = await github.rest.issues.listComments({ | |
owner: owner, | |
repo: repo, | |
issue_number: context.issue.number | |
}) | |
const botComment = comments.find(comment => comment.body.includes('Zod playground preview available at')) | |
if (botComment) { | |
await github.rest.issues.updateComment({ | |
owner: owner, | |
repo: repo, | |
comment_id: botComment.id, | |
body: `Zod playground preview available at: ${url}` | |
}) | |
} else { | |
await github.rest.issues.createComment({ | |
owner: owner, | |
repo: repo, | |
issue_number: context.issue.number, | |
body: `Zod playground preview available at: ${url}` | |
}) | |
} |