-
Notifications
You must be signed in to change notification settings - Fork 5
65 lines (51 loc) · 1.38 KB
/
check-pr.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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
name: Check PR
on: [pull_request]
jobs:
checks:
runs-on: ubuntu-latest
env:
FORCE_COLOR: 1
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install packages
run: yarn install --frozen-lockfile
- name: Eslint
run: yarn eslint
- name: Prettier
run: yarn pretify
tests:
runs-on: ubuntu-latest
env:
DEPLOY_NAME: sendsay-docs
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup node
uses: actions/setup-node@v3
with:
node-version: 18
- name: Install packages
run: yarn install --frozen-lockfile
- name: Install Playwright Browsers
run: yarn playwright install --with-deps
- name: URL
id: url
shell: bash
run: echo "link=https://deploy-preview-${{ github.event.pull_request.number }}--${{ env.DEPLOY_NAME }}.netlify.app" >> $GITHUB_OUTPUT
- name: Run Playwright tests
env:
BASE_URL: ${{ steps.url.outputs.link }}
run: yarn e2e
- uses: actions/upload-artifact@v3
if: always()
with:
name: playwright-report
path: |
playwright-report
playwright-artifacts
retention-days: 30