mirror of
https://github.com/smartxworks/sunmao-ui.git
synced 2024-11-27 08:39:59 +08:00
25 lines
584 B
YAML
25 lines
584 B
YAML
name: CI
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
branches: [main]
|
|
workflow_dispatch:
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- uses: actions/setup-node@v2
|
|
with:
|
|
node-version: "12"
|
|
- name: install dependencies
|
|
run: yarn install
|
|
- name: run test
|
|
uses: mattallty/jest-github-action@v1
|
|
env:
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
with:
|
|
test-command: "yarn test:ci"
|
|
coverage-comment: ${{ github.event_name == 'pull_request'}}
|