-
-
Notifications
You must be signed in to change notification settings - Fork 19
49 lines (42 loc) · 1.62 KB
/
mac-test-2.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
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: mac-test-2
on:
push:
branches: [ build, test ]
jobs:
build:
runs-on: macos-11
environment: build
if: "!contains(github.event.head_commit.message, '[skip test]') && !contains(github.event.head_commit.message, '[skip ci]') && !contains(github.event.head_commit.message, '[skip mac]') && !contains(github.event.head_commit.message, '[skip test2]')"
steps:
- uses: actions/checkout@v4
- name: Use Node.js 18.x
uses: actions/setup-node@v4
with:
node-version: 18.x
# before_install:
- run: npm i
- run: npx playwright install chromium
- run: npm i -g pm2
# script:
- run: npm run build
- run: cp .sample.env .env
- run: npm run test3
- run: echo "npm run prod" > run.sh && pm2 start run.sh
- name: test
uses: GabrielBB/xvfb-action@v1
with:
run: npm run test2
env:
NODE_TEST: 1
TEST_HOST: ${{ secrets.TEST_HOST }}
TEST_USER: ${{ secrets.TEST_USER_DARWIN }}
TEST_PASS: ${{ secrets.TEST_PASS_DARWIN }}
GIST_TOKEN: ${{ secrets.GIST_TOKEN }}
GIST_ID: ${{ secrets.GIST_ID }}
GITEE_TOKEN: ${{ secrets.GITEE_TOKEN }}
GITEE_ID: ${{ secrets.GITEE_ID }}
CUSTOM_SYNC_URL: ${{ secrets.CUSTOM_SYNC_URL }}
CUSTOM_SYNC_USER: ${{ secrets.CUSTOM_SYNC_USER }}
CUSTOM_SYNC_SECRET: ${{ secrets.CUSTOM_SYNC_SECRET }}