mirror of
https://github.com/mermaid-js/mermaid.git
synced 2025-01-14 06:43:25 +08:00
36 lines
820 B
YAML
36 lines
820 B
YAML
name: Build
|
|
|
|
on: [push, pull_request]
|
|
|
|
jobs:
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
strategy:
|
|
matrix:
|
|
node-version: [10.x, 12.x]
|
|
steps:
|
|
- uses: actions/checkout@v1
|
|
- name: Setup Node.js ${{ matrix.node-version }}
|
|
uses: actions/setup-node@v1
|
|
with:
|
|
node-version: ${{ matrix.node-version }}
|
|
- name: Install Yarn
|
|
run: npm i yarn --global
|
|
|
|
- name: Install Packages
|
|
run: yarn install
|
|
|
|
- name: Run Build
|
|
run: yarn build
|
|
|
|
- name: Run Unit Tests
|
|
run: |
|
|
yarn test --coverage
|
|
cat ./coverage/lcov.info | ./node_modules/.bin/coveralls
|
|
with:
|
|
COVERALLS_SERVICE_NAME: ${{ secrets.COVERALLS_SERVICE_NAME }}
|
|
COVERALLS_REPO_TOKEN: ${{ secrets.COVERALLS_REPO_TOKEN }}
|
|
|
|
- name: Run E2E Tests
|
|
run: yarn e2e
|