Skip to content

Commit

Permalink
ci: upload code coverage to Codecov (#71)
Browse files Browse the repository at this point in the history
  • Loading branch information
malept authored Aug 3, 2021
1 parent 42793b7 commit de19285
Show file tree
Hide file tree
Showing 4 changed files with 733 additions and 13 deletions.
11 changes: 10 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,17 @@ jobs:
cache: yarn
- name: Install
run: yarn --frozen-lockfile
- name: Lint
run: yarn lint
- name: Test
run: yarn test
run: yarn coverage
- name: Upload code coverage to Codecov
uses: codecov/codecov-action@v2.0.1
with:
file: ./coverage/lcov.info
env_vars: NODE_VERSION
env:
NODE_VERSION: ${{ matrix.node-version }}

automerge:
needs: build
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
*-error.log
node_modules/
.DS_Store
.nyc_output/
coverage/
npm-debug.log
package-lock.json
test/fixture*
8 changes: 5 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,10 @@
"url": "git://github.com/electron-userland/electron-installer-dmg.git"
},
"scripts": {
"coverage": "nyc --reporter=lcov --reporter=text npm run spec",
"lint": "eslint src test bin",
"mocha": "mocha",
"test": "npm run lint && npm run mocha"
"spec": "mocha",
"test": "npm run lint && npm run spec"
},
"bin": {
"electron-installer-dmg": "bin/electron-installer-dmg.js"
Expand Down Expand Up @@ -40,7 +41,8 @@
"eslint-config-airbnb-base": "^14.2.1",
"eslint-plugin-import": "^2.23.4",
"extract-zip": "^2.0.1",
"mocha": "^9.0.3"
"mocha": "^9.0.3",
"nyc": "^15.1.0"
},
"keywords": [
"mongodb.js",
Expand Down
Loading

0 comments on commit de19285

Please sign in to comment.