switched from coveralls to codecov

This commit is contained in:
Philipp Kunz 2016-04-02 19:09:11 +02:00
parent 112ce2d0d6
commit 570046ff67
11 changed files with 13 additions and 13 deletions

View File

@ -39,7 +39,7 @@ Then use it in package.json's script section to trigger a build:
1. Instrumentalize created JavaScript files with istanbul
1. Run Tests
1. Create Coverage report
1. Upload Coverage reports to travis (Tests must pass, Coveralls must be activated, by default only triggers on travis)
1. Upload Coverage reports to codecov.io (Tests must pass, codecov.io must be activated, by default only triggers on travis)
1. Upload JsDoc Documentation to gh-pages branch on GitHub. (Tests must pass, requires GitHub Token)
#### npmts.json

View File

@ -31,8 +31,8 @@ exports.run = function (configArg) {
exports.isRelease() && exports.doPublish() ? plugins.beautylog.info("All right: This is the first subBuild, so this one publishes coverage and docs when tests succeed!")
: plugins.beautylog.info("We are not publishing anything!");
// handle coveralls
config.coveralls ? void (0) : config.coveralls = false;
exports.doPublish() ? void (0) : config.coveralls = false;
config.codecov ? void (0) : config.codecov = true;
exports.doPublish() ? void (0) : config.codecov = false;
config.coverageTreshold ? void (0) : config.coverageTreshold = 70;
// handle docs
config.docs ? void (0) : config.docs = {};

View File

@ -4,7 +4,7 @@ exports.beautylog = require("beautylog");
exports.fs = require("fs-extra");
exports.gulp = require("gulp");
exports.g = {
coveralls: require("gulp-coveralls"),
codecov: require("gulp-codecov"),
gFunction: require("gulp-function"),
istanbul: require("gulp-istanbul"),
jsdoc3: require("gulp-jsdoc3"),

View File

@ -7,7 +7,7 @@ exports.run = function (configArg) {
var done = plugins.Q.defer();
var config = configArg;
var promiseArray = [];
config.coveralls ? promiseArray.push(NpmtsTests.publishCoverage(configArg)) : void (0);
config.codecov ? promiseArray.push(NpmtsTests.publishCoverage(configArg)) : void (0);
config.docs.publish ? promiseArray.push(NpmtsJsdoc.publishDocs(configArg)) : void (0);
promiseArray.length === 0 ? plugins.beautylog.info("Did not publish anything!") : void (0);
plugins.Q.all(promiseArray).then(done.resolve);

2
dist/npmts.tests.js vendored
View File

@ -6,7 +6,7 @@ exports.publishCoverage = function (configArg) {
var done = plugins.Q.defer();
plugins.beautylog.log("now uploading coverage data to coveralls");
var stream = plugins.gulp.src([plugins.path.join(paths.cwd, "./coverage/lcov.info")])
.pipe(plugins.g.coveralls())
.pipe(plugins.g.codecov())
.pipe(plugins.g.gFunction(function () {
plugins.beautylog.ok("Coverage data has been uploaded to Coveralls!");
done.resolve(configArg);

View File

@ -28,8 +28,8 @@
"beautylog": "3.1.2",
"fs-extra": "^0.26.7",
"gulp": "3.9.1",
"gulp-codecov": "^2.0.1",
"gulp-concat": "^2.6.0",
"gulp-coveralls": "^0.1.4",
"gulp-function": "^1.2.0",
"gulp-if": "^2.0.0",
"gulp-istanbul": "^0.10.3",

View File

@ -9,7 +9,7 @@
"./subts2/typings.json",
"./customdir/typings.json"
],
"coveralls":true,
"codecov":true,
"docs": {
"publish":true
},

View File

@ -37,8 +37,8 @@ export var run = function(configArg){
: plugins.beautylog.info("We are not publishing anything!");
// handle coveralls
config.coveralls ? void(0) : config.coveralls = false;
doPublish() ? void(0) : config.coveralls = false;
config.codecov ? void(0) : config.codecov = true;
doPublish() ? void(0) : config.codecov = false;
config.coverageTreshold ? void(0) : config.coverageTreshold = 70;

View File

@ -3,7 +3,7 @@ export let beautylog = require("beautylog");
export let fs = require("fs-extra");
export let gulp = require("gulp");
export let g = {
coveralls: require("gulp-coveralls"),
codecov: require("gulp-codecov"),
gFunction: require("gulp-function"),
istanbul: require("gulp-istanbul"),
jsdoc3: require("gulp-jsdoc3"),

View File

@ -9,7 +9,7 @@ export let run = function(configArg){
let done = plugins.Q.defer();
let config = configArg;
let promiseArray = [];
config.coveralls ? promiseArray.push(NpmtsTests.publishCoverage(configArg)) : void(0);
config.codecov ? promiseArray.push(NpmtsTests.publishCoverage(configArg)) : void(0);
config.docs.publish ? promiseArray.push(NpmtsJsdoc.publishDocs(configArg)) : void(0);
promiseArray.length === 0 ? plugins.beautylog.info("Did not publish anything!") : void(0);

View File

@ -6,7 +6,7 @@ export let publishCoverage = function(configArg){
let done = plugins.Q.defer();
plugins.beautylog.log("now uploading coverage data to coveralls");
var stream = plugins.gulp.src([plugins.path.join(paths.cwd,"./coverage/lcov.info")])
.pipe(plugins.g.coveralls())
.pipe(plugins.g.codecov())
.pipe(plugins.g.gFunction(function(){
plugins.beautylog.ok("Coverage data has been uploaded to Coveralls!");
done.resolve(configArg);