From 2f494a2951744432513e6dacad8cc4aa4b592ac7 Mon Sep 17 00:00:00 2001 From: Rodrigo Primo Date: Thu, 23 Sep 2021 11:35:35 -0300 Subject: [PATCH] Change `./do qa:code-sniffer` to include warnings by default This change is necessary to make sure we are running PHPCS with the same parameters in both CircleCI and the pre-commit hook. For more information see the description of the related Jira ticket. [MAILPOET-3831] --- RoboFile.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/RoboFile.php b/RoboFile.php index 9e4b7f2dcd..aca0e9094c 100644 --- a/RoboFile.php +++ b/RoboFile.php @@ -343,7 +343,7 @@ class RoboFile extends \Robo\Tasks { $collection = $this->collectionBuilder(); $collection->addCode([$this, 'qaLint']); $collection->addCode(function() { - return $this->qaCodeSniffer([], ['severity' => 'all']); + return $this->qaCodeSniffer([]); }); return $collection->run(); } @@ -367,7 +367,7 @@ class RoboFile extends \Robo\Tasks { return $this->_exec('npm run stylelint-check -- "assets/css/src/**/*.scss"'); } - public function qaCodeSniffer(array $filesToCheck, $opts = ['severity' => 'errors']) { + public function qaCodeSniffer(array $filesToCheck, $opts = ['severity' => 'all']) { $severityFlag = $opts['severity'] === 'all' ? '-w' : '-n'; $task = implode(' ', [ './tasks/code_sniffer/vendor/bin/phpcs',