liferay-npm-build-tools-common
Advanced tools
Comparing version 1.7.0-alpha.2956f206 to 1.7.0-alpha.37376d14
@@ -131,2 +131,28 @@ 'use strict'; | ||
} | ||
/** | ||
* Test if there are warn messages. | ||
* @return {boolean} if at least one warn message is registered in the logger | ||
*/ | ||
}, { | ||
key: 'warnsPresent', | ||
get: function get() { | ||
return this._msgs.filter(function (msg) { | ||
return msg.level === 'warn'; | ||
}).length > 0; | ||
} | ||
/** | ||
* Test if there are error messages. | ||
* @return {boolean} if at least one error message is registered in the logger | ||
*/ | ||
}, { | ||
key: 'errorsPresent', | ||
get: function get() { | ||
return this._msgs.filter(function (msg) { | ||
return msg.level === 'error'; | ||
}).length > 0; | ||
} | ||
}]); | ||
@@ -133,0 +159,0 @@ |
{ | ||
"name": "liferay-npm-build-tools-common", | ||
"version": "1.7.0-alpha.2956f206", | ||
"version": "1.7.0-alpha.37376d14", | ||
"description": "Utility library for Liferay NPM Build Tools.", | ||
@@ -5,0 +5,0 @@ "scripts": { |
@@ -64,2 +64,18 @@ /** | ||
/** | ||
* Test if there are warn messages. | ||
* @return {boolean} if at least one warn message is registered in the logger | ||
*/ | ||
get warnsPresent() { | ||
return this._msgs.filter(msg => msg.level === 'warn').length > 0; | ||
} | ||
/** | ||
* Test if there are error messages. | ||
* @return {boolean} if at least one error message is registered in the logger | ||
*/ | ||
get errorsPresent() { | ||
return this._msgs.filter(msg => msg.level === 'error').length > 0; | ||
} | ||
/** | ||
* Return a printable string representation of the messages logged till now | ||
@@ -66,0 +82,0 @@ * @return {String} a string containing one line per message |
Sorry, the diff of this file is not supported yet
126453
1974