@@ -192,7 +192,7 @@ function writeSummary(callback: () => void): void {
192192 if ( shouldRelogIssues && getWarnings ( ) . length ) {
193193 const warnings : string [ ] = getWarnings ( ) ;
194194 for ( let x : number = 0 ; x < warnings . length ; x ++ ) {
195- console . log ( gutil . colors . yellow ( warnings [ x ] ) ) ;
195+ console . error ( gutil . colors . yellow ( warnings [ x ] ) ) ;
196196 }
197197 }
198198
@@ -443,13 +443,8 @@ export function warn(...args: Array<string | Chalk.ChalkChain>): void {
443443 const stringMessage : string = args . join ( ' ' ) ;
444444
445445 if ( ! localCache . errorAndWarningSupressions [ stringMessage ] ) {
446- if ( getConfig ( ) . showWarningsAsErrors ) {
447- localCache . errors . push ( stringMessage ) ;
448- log ( gutil . colors . red . apply ( undefined , args ) ) ;
449- } else {
450- localCache . warnings . push ( stringMessage ) ;
451- log ( gutil . colors . yellow . apply ( undefined , args ) ) ;
452- }
446+ localCache . errors . push ( stringMessage ) ;
447+ log ( gutil . colors . yellow . apply ( undefined , args ) ) ;
453448 }
454449}
455450
@@ -652,6 +647,7 @@ export function initialize(gulp: gulp.Gulp, gulpErrorCallback?: (err: Error) =>
652647 writeSummary ( ( ) => {
653648 // error if we have any errors
654649 if ( localCache . taskErrors > 0 ||
650+ ( getWarnings ( ) . length && getConfig ( ) . showWarningsAsErrors ) ||
655651 getErrors ( ) . length ||
656652 localCache . testsFailed > 0 ) {
657653 exitProcess ( 1 ) ;
0 commit comments