chore: linting #205
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci-merge | |
on: | |
push: | |
branches: ["main"] | |
workflow_dispatch: | |
branches: ["main"] | |
jobs: | |
ci: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [16.x] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Use Node.js ${{ matrix.node-version }} | |
uses: actions/setup-node@v2 | |
with: | |
node-version: ${{ matrix.node-version }} | |
- uses: actions/cache@v2 | |
with: | |
path: "**/node_modules" | |
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | |
- name: Install and build | |
run: yarn --frozen-lockfile | |
- name: Unit tests | |
run: yarn test:ci | |
- name: Process Test Results | |
uses: dorny/test-reporter@v1 | |
with: | |
name: Jest Tests | |
path: "junit.xml" | |
reporter: jest-junit | |
- name: Upload coverage to Codecov | |
uses: codecov/codecov-action@v2 | |
with: | |
files: ./coverage/coverage-final.json | |
verbose: true | |
- name: Upload coverage to Code Climate | |
uses: paambaati/[email protected] | |
env: | |
CC_TEST_REPORTER_ID: ${{ secrets.CC_TEST_REPORTER_ID }} | |
with: | |
coverageLocations: | | |
${{ github.workspace }}/coverage/lcov.info:lcov | |
- name: Upload coverage to Codacy | |
uses: codacy/[email protected] | |
with: | |
project-token: ${{ secrets.CODACY_PROJECT_TOKEN }} | |
coverage-reports: ./coverage/lcov.info |