Skip to content

Commit

Permalink
add code coverage generator [ci skip]
Browse files Browse the repository at this point in the history
  • Loading branch information
phpnode committed Apr 4, 2014
1 parent cf2deb3 commit 8e3744f
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
1 change: 1 addition & 0 deletions .gitignore
@@ -1,5 +1,6 @@
/node_modules
/ci/environment
/coverage
.DS_Store
*.swp
.idea
Expand Down
8 changes: 8 additions & 0 deletions CONTRIBUTING.md
Expand Up @@ -18,6 +18,14 @@ To run the tests:
npm test
```

To generate the code coverage report, run:

```
npm run coverage
```

And have a look at `coverage/lcov-report/index.html`.



## Git Workflow For Contributors
Expand Down
6 changes: 4 additions & 2 deletions package.json
Expand Up @@ -50,7 +50,8 @@
"devDependencies": {
"mocha": "*",
"should": "*",
"expect.js": "*"
"expect.js": "*",
"istanbul": "*"
},
"main": "./lib/index.js",
"directories": {
Expand All @@ -63,7 +64,8 @@
"oriento": "./bin/oriento"
},
"scripts": {
"test": "echo \"\n\nNOTICE: If tests fail, please ensure you've set the correct credentials in test/test-server.json\n\n\"; node ./node_modules/mocha/bin/mocha ./test/index.js ./test/**/*.js ./test/**/**/*.js --reporter=spec -t 10000"
"test": "echo \"\n\nNOTICE: If tests fail, please ensure you've set the correct credentials in test/test-server.json\n\n\"; node ./node_modules/mocha/bin/mocha ./test/index.js ./test/**/*.js ./test/**/**/*.js --reporter=spec -t 10000",
"coverage": "./node_modules/istanbul/lib/cli.js cover ./node_modules/mocha/bin/_mocha ./test/index.js ./test/**/*.js ./test/**/**/*.js --reporter=spec"
},
"licenses": [
{
Expand Down

0 comments on commit 8e3744f

Please sign in to comment.