Skip to content

Commit

Permalink
Add codecov (#318)
Browse files Browse the repository at this point in the history
Fixes #258
  • Loading branch information
raylu authored and alangpierce committed Oct 7, 2018
1 parent 96a6e92 commit 228d40f
Show file tree
Hide file tree
Showing 6 changed files with 285 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,4 @@ dist-self-build
example-runner/example-repos
integrations/gulp-plugin/dist
.nyc_output
coverage.lcov
9 changes: 9 additions & 0 deletions .nycrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"include": [
"src/**/*"
],
"extension": [
".ts"
],
"all": true
}
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ matrix:
- yarn run-examples tslint apollo-client
- script:
- yarn build
- yarn test
- 'yarn test && yarn coverage'
- yarn run-examples decaffeinate decaffeinate-parser coffee-lex
- node_js: '8'
script:
Expand Down
7 changes: 5 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,9 @@
"prepublishOnly": "yarn clean && yarn build",
"release": "sucrase-node script/release.ts",
"run-examples": "sucrase-node example-runner/example-runner.ts",
"test": "yarn lint && yarn test-only",
"test-only": "mocha './test/**/*.ts'"
"test": "yarn lint && nyc yarn test-only",
"test-only": "mocha './test/**/*.ts'",
"coverage": "nyc report --reporter=text-lcov > coverage.lcov && codecov"
},
"repository": {
"type": "git",
Expand Down Expand Up @@ -53,6 +54,7 @@
"@types/mocha": "^2.2.43",
"@types/mz": "^0.0.32",
"@types/node": "^8.0.31",
"codecov": "^3.1.0",
"eslint": "^4.13.1",
"eslint-config-airbnb-base": "^12.1.0",
"eslint-config-prettier": "^2.9.0",
Expand All @@ -62,6 +64,7 @@
"mocha": "^3.5.3",
"nyc": "^12.0.2",
"prettier": "^1.12.1",
"source-map-support": "^0.5.9",
"sucrase": "^3.5.0",
"tslint": "^5.9.1",
"tslint-language-service": "^0.9.9",
Expand Down
1 change: 1 addition & 0 deletions test/mocha.opts
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
--require sucrase/register
--require source-map-support/register
Loading

0 comments on commit 228d40f

Please sign in to comment.