From e378d2d6daa0e0c43e9bd7131c2fc990e4e65b7c Mon Sep 17 00:00:00 2001 From: Leonardo Gatica Date: Thu, 5 May 2016 17:42:32 -0300 Subject: [PATCH] Add coverage --- .travis.yml | 2 ++ README.md | 1 + package.json | 5 ++++- 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index ab54ba5..282070f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -5,3 +5,5 @@ node_js: - "6" notifications: email: false +after_success: + - npm run coveralls diff --git a/README.md b/README.md index 102db40..d8fcc75 100644 --- a/README.md +++ b/README.md @@ -3,6 +3,7 @@ [![npm version](https://img.shields.io/npm/v/bip.svg?style=flat-square)](https://www.npmjs.com/package/bip) [![npm downloads](https://img.shields.io/npm/dm/bip.svg?style=flat-square)](https://www.npmjs.com/package/bip) [![Build Status](https://img.shields.io/travis/lgaticaq/bip.svg?style=flat-square)](https://travis-ci.org/lgaticaq/bip) +[![Coverage Status](https://img.shields.io/coveralls/lgaticaq/bip/master.svg?style=flat-square)](https://coveralls.io/github/lgaticaq/bip?branch=master) [![dependency Status](https://img.shields.io/david/lgaticaq/bip.svg?style=flat-square)](https://david-dm.org/lgaticaq/bip#info=dependencies) [![devDependency Status](https://img.shields.io/david/dev/lgaticaq/bip.svg?style=flat-square)](https://david-dm.org/lgaticaq/bip#info=devDependencies) [![Join the chat at https://gitter.im/lgaticaq/bip](https://img.shields.io/badge/gitter-join%20chat%20%E2%86%92-brightgreen.svg?style=flat-square)](https://gitter.im/lgaticaq/bip?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) diff --git a/package.json b/package.json index 2012e98..f43ac7a 100644 --- a/package.json +++ b/package.json @@ -6,7 +6,8 @@ "scripts": { "lint": "eslint src", "clean": "rimraf lib", - "test": "mocha" + "test": "istanbul cover _mocha", + "coveralls": "coveralls < coverage/lcov.info" }, "engines": { "node": ">=4" @@ -32,7 +33,9 @@ }, "devDependencies": { "chai": "^3.5.0", + "coveralls": "^2.11.9", "eslint": "^2.9.0", + "istanbul": "^0.4.3", "mocha": "^2.4.5", "nock": "^8.0.0", "rimraf": "^2.5.2"