Skip to content

Commit 9bd0a17

Browse files
committed
migration github action
1 parent b2d1ab4 commit 9bd0a17

File tree

2 files changed

+57
-0
lines changed

2 files changed

+57
-0
lines changed
Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
name: Build and Test
2+
3+
on:
4+
pull_request:
5+
types: [opened, synchronize]
6+
7+
push:
8+
branches-ignore:
9+
- main
10+
concurrency:
11+
group: build-and-test-${{ github.head_ref || github.ref_name }}
12+
cancel-in-progress: true
13+
14+
jobs:
15+
build-and-test:
16+
runs-on: ubuntu-latest-4-cores
17+
18+
env:
19+
BOT_GH_TOKEN: ${{ secrets.BOT_GH_TOKEN }}
20+
21+
steps:
22+
- name: Checkout code
23+
uses: actions/checkout@v4
24+
25+
- name: Setup Node.js
26+
uses: actions/setup-node@v4
27+
with:
28+
node-version: '16.19.1'
29+
cache: 'yarn'
30+
31+
- name: Install dependencies
32+
run: |
33+
yarn install --immutable
34+
35+
- name: Run lint
36+
if: ${{ success() }}
37+
run: |
38+
yarn lint
39+
40+
- name: Run build
41+
if: ${{ success() }}
42+
run: |
43+
yarn build
44+
45+
- name: Run test
46+
if: ${{ success() }}
47+
timeout-minutes: 15
48+
run: |
49+
yarn test --forceExit --runInBand
50+
51+
- name: Store artifacts
52+
if: ${{ success() }}
53+
uses: actions/upload-artifact@v4
54+
with:
55+
name: coverage
56+
path: coverage
57+
retention-days: 2

0 commit comments

Comments
 (0)