now clears CLI pipe for tests

This commit is contained in:
Philipp Kunz 2016-05-21 19:41:18 +02:00
parent f65c09c24e
commit a6e91c6a7f
4 changed files with 6 additions and 2 deletions

View File

@ -43,7 +43,6 @@ exports.promisechain = function () {
plugins.beautylog.success("READY TO SHIP!"); plugins.beautylog.success("READY TO SHIP!");
} }
else { else {
exports.npmtsOra.endOk("Tasks finished!");
plugins.beautylog.success("Done!"); plugins.beautylog.success("Done!");
} }
done.resolve(); done.resolve();

3
dist/npmts.tests.js vendored
View File

@ -19,11 +19,13 @@ exports.publishCoverage = function (configArg) {
* @returns {*} * @returns {*}
*/ */
var istanbul = function (configArg) { var istanbul = function (configArg) {
npmts_promisechain_1.npmtsOra.text("Instrumentalizing transpiled JS...");
var done = plugins.Q.defer(); var done = plugins.Q.defer();
var stream = plugins.gulp.src([plugins.path.join(paths.cwd, "dist/*.js")]) var stream = plugins.gulp.src([plugins.path.join(paths.cwd, "dist/*.js")])
.pipe(plugins.g.istanbul()) // Covering files .pipe(plugins.g.istanbul()) // Covering files
.pipe(plugins.g.istanbul.hookRequire()) // Force `require` to return covered files .pipe(plugins.g.istanbul.hookRequire()) // Force `require` to return covered files
.pipe(plugins.g.gFunction(function () { .pipe(plugins.g.gFunction(function () {
plugins.beautylog.ok("JS has been instrumentalized to get test code coverage!");
done.resolve(configArg); done.resolve(configArg);
}, "atEnd")); }, "atEnd"));
return done.promise; return done.promise;
@ -34,6 +36,7 @@ var istanbul = function (configArg) {
*/ */
var mocha = function (configArg) { var mocha = function (configArg) {
var done = plugins.Q.defer(); var done = plugins.Q.defer();
npmts_promisechain_1.npmtsOra.end(); // end npmtsOra for tests.
var stream = plugins.gulp.src(["./test/test.js"]) var stream = plugins.gulp.src(["./test/test.js"])
.pipe(plugins.g.mocha()) .pipe(plugins.g.mocha())
.pipe(plugins.g.istanbul.writeReports()) // Creating the reports after tests ran .pipe(plugins.g.istanbul.writeReports()) // Creating the reports after tests ran

View File

@ -44,7 +44,6 @@ export let promisechain = function(){
console.log(shipString); console.log(shipString);
plugins.beautylog.success("READY TO SHIP!"); plugins.beautylog.success("READY TO SHIP!");
} else { } else {
npmtsOra.endOk("Tasks finished!");
plugins.beautylog.success("Done!"); plugins.beautylog.success("Done!");
} }
done.resolve(); done.resolve();

View File

@ -20,11 +20,13 @@ export let publishCoverage = function(configArg){
* @returns {*} * @returns {*}
*/ */
let istanbul = function (configArg) { let istanbul = function (configArg) {
npmtsOra.text("Instrumentalizing transpiled JS...");
let done = plugins.Q.defer(); let done = plugins.Q.defer();
var stream = plugins.gulp.src([plugins.path.join(paths.cwd,"dist/*.js")]) var stream = plugins.gulp.src([plugins.path.join(paths.cwd,"dist/*.js")])
.pipe(plugins.g.istanbul()) // Covering files .pipe(plugins.g.istanbul()) // Covering files
.pipe(plugins.g.istanbul.hookRequire()) // Force `require` to return covered files .pipe(plugins.g.istanbul.hookRequire()) // Force `require` to return covered files
.pipe(plugins.g.gFunction(function(){ .pipe(plugins.g.gFunction(function(){
plugins.beautylog.ok("JS has been instrumentalized to get test code coverage!");
done.resolve(configArg); done.resolve(configArg);
},"atEnd")); },"atEnd"));
return done.promise; return done.promise;
@ -36,6 +38,7 @@ let istanbul = function (configArg) {
*/ */
let mocha = function (configArg) { let mocha = function (configArg) {
let done = plugins.Q.defer(); let done = plugins.Q.defer();
npmtsOra.end(); // end npmtsOra for tests.
let stream = plugins.gulp.src(["./test/test.js"]) let stream = plugins.gulp.src(["./test/test.js"])
.pipe(plugins.g.mocha()) .pipe(plugins.g.mocha())
.pipe(plugins.g.istanbul.writeReports()) // Creating the reports after tests ran .pipe(plugins.g.istanbul.writeReports()) // Creating the reports after tests ran