This repository was archived by the owner on Dec 19, 2019. It is now read-only.
File tree 2 files changed +5
-1
lines changed
testsuite/Magento/Test/Php 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change 30
30
</testsuites >
31
31
<php >
32
32
<ini name =" date.timezone" value =" America/Los_Angeles" />
33
+ <const name =" TESTCODESTYLE_IS_FULL_SCAN" value =" 1" />
33
34
<!-- TESTS_COMPOSER_PATH - specify the path to composer binary, if a relative reference cannot be resolved -->
34
35
<!-- <const name="TESTS_COMPOSER_PATH" value="/usr/local/bin/composer"/>-->
35
36
</php >
Original file line number Diff line number Diff line change @@ -201,11 +201,14 @@ private function getFullWhitelist()
201
201
202
202
public function testCodeStyle ()
203
203
{
204
+ $ whiteList = defined ('TESTCODESTYLE_IS_FULL_SCAN ' ) && TESTCODESTYLE_IS_FULL_SCAN === '1 '
205
+ ? $ this ->getFullWhitelist () : self ::getWhitelist (['php ' , 'phtml ' ]);
206
+
204
207
$ reportFile = self ::$ reportDir . '/phpcs_report.txt ' ;
205
208
$ codeSniffer = new CodeSniffer ('Magento ' , $ reportFile , new Wrapper ());
206
209
$ this ->assertEquals (
207
210
0 ,
208
- $ result = $ codeSniffer ->run ($ this -> getFullWhitelist () ),
211
+ $ result = $ codeSniffer ->run ($ whiteList ),
209
212
"PHP Code Sniffer detected {$ result } violation(s): " . PHP_EOL . file_get_contents ($ reportFile )
210
213
);
211
214
}
You can’t perform that action at this time.
0 commit comments