Skip to content

Commit

Permalink
chore: add ci action config
Browse files Browse the repository at this point in the history
  • Loading branch information
pubuzhixing8 committed Apr 17, 2024
1 parent 99fecff commit 0a00d4d
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 1 deletion.
30 changes: 30 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: CI

on:
push:
branches: [ "develop" ]
pull_request:
branches: [ "develop" ]

jobs:
build:
name: Test
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [18.x]

steps:
- uses: actions/checkout@v3
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v3
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'

- name: Install Dependencies
run: npm run i --force

- name: Run Unit Tests
run: npm run ci:test
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,12 @@
"pub:draw": "cd dist/draw && npm publish --access public",
"pub": "./scripts/publish.sh",
"watch": "ng build --watch --configuration development",
"test": "ng test mind",
"test:mind": "ng test mind",
"test:draw": "ng test draw",
"test:core": "ng test core",
"test:common": "ng test common",
"test:flow": "ng test flow",
"ci:test": "ng test --watch=false",
"start:docs": "docgeni serve --port 4600",
"lint": "ng lint --fix",
"pretty": "pretty-quick --staged"
Expand Down

0 comments on commit 0a00d4d

Please sign in to comment.