Skip to content

Commit

Permalink
Fixes #22480 - Add code coverage to Travis CI
Browse files Browse the repository at this point in the history
publish code-coverage report from travis to coveralls.io
  • Loading branch information
Avi Sharvit authored and dLobatog committed Feb 2, 2018
1 parent 0d332ec commit 254f227
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

[![Build Status](http://ci.theforeman.org/buildStatus/icon?job=test_develop)](http://ci.theforeman.org/job/test_develop/)
[![Code Climate](https://codeclimate.com/github/theforeman/foreman/badges/gpa.svg)](https://codeclimate.com/github/theforeman/foreman)
[![Coverage Status](https://coveralls.io/repos/github/theforeman/foreman/badge.svg?branch=develop)](https://coveralls.io/github/theforeman/foreman?branch=develop)
[![Issue Stats](http://issuestats.com/github/theforeman/foreman/badge/pr)](http://issuestats.com/github/theforeman/foreman)
[![Support IRC channel](https://kiwiirc.com/buttons/irc.freenode.net/theforeman.png)](https://kiwiirc.com/client/irc.freenode.net/?#theforeman)

Expand Down
2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
"babel-preset-react": "^6.5.0",
"babel-register": "^6.9.0",
"compression-webpack-plugin": "~0.3.1",
"coveralls": "^3.0.0",
"css-loader": "^0.23.1",
"dotenv": "^2.0.0",
"enzyme": "^3.1.1",
Expand Down Expand Up @@ -98,6 +99,7 @@
"test": "node node_modules/.bin/jest",
"test:watch": "node node_modules/.bin/jest --watchAll",
"test:current": "node node_modules/.bin/jest --watch",
"coveralls": "cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js",
"storybook": "start-storybook -p 6006",
"build-storybook": "build-storybook",
"deploy-storybook": "storybook-to-ghpages",
Expand Down
1 change: 1 addition & 0 deletions script/travis_run_js_tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,5 @@
set -ev
if [[ $( git diff --name-only HEAD~1..HEAD config/webpack.config.js webpack/ .travis.yml package.json | wc -l ) -ne 0 ]]; then
npm run test;
npm run coveralls;
fi

0 comments on commit 254f227

Please sign in to comment.