File tree Expand file tree Collapse file tree 2 files changed +6
-1
lines changed
dev/tests/static/testsuite/Magento/Test/Xml Expand file tree Collapse file tree 2 files changed +6
-1
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ $wishlistHelper = $block->getData('wishlistHelper');
12
12
?>
13
13
<?php if ($ block ->getLink ()): ?>
14
14
<p id="wishlist-rss-email-link">
15
+ <h2>{{escapehtml "H2"}}</h2>
15
16
<?= $ block ->escapeHtml (__ ("RSS link to %1's wishlist " , $ wishlistHelper ->getCustomerName ())) ?>
16
17
<br />
17
18
<a href="<?= $ block ->escapeUrl ($ block ->getLink ()) ?> "><?= $ block ->escapeUrl ($ block ->getLink ()) ?> </a>
Original file line number Diff line number Diff line change 10
10
use Magento \TestFramework \CodingStandard \Tool \CodeSniffer ;
11
11
use Magento \Test \Php \LiveCodeTest as PHPCodeTest ;
12
12
use Magento \TestFramework \CodingStandard \Tool \CodeSniffer \Wrapper ;
13
+ use Magento \TestFramework \Utility \FilesSearch ;
13
14
use PHPUnit \Framework \TestCase ;
14
15
15
16
/**
@@ -45,10 +46,13 @@ public static function setUpBeforeClass(): void
45
46
public function testCodeStyle (): void
46
47
{
47
48
$ reportFile = self ::$ reportDir . '/xml_report.txt ' ;
49
+ if (!file_exists ($ reportFile )) {
50
+ touch ($ reportFile );
51
+ }
48
52
$ codeSniffer = new CodeSniffer ('Magento ' , $ reportFile , new Wrapper ());
49
53
$ codeSniffer ->setExtensions ([self ::FILE_EXTENSION ]);
50
54
$ fileList = $ this ->isFullScan () ? array_column (Files::init ()->getXmlFiles (), '0 ' )
51
- : PHPCodeTest::getWhitelist ([self ::FILE_EXTENSION ], __DIR__ , __DIR__ );
55
+ : PHPCodeTest::getWhitelist ([self ::FILE_EXTENSION ]);
52
56
$ result = $ codeSniffer ->run ($ fileList );
53
57
$ report = file_exists ($ reportFile ) ? file_get_contents ($ reportFile ) : '' ;
54
58
$ this ->assertEquals (
You can’t perform that action at this time.
0 commit comments