We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 49e2e23 commit 02b640aCopy full SHA for 02b640a
Magento2/Tests/Eslint/AbstractEslintTestCase.php
@@ -7,6 +7,7 @@
7
8
namespace Magento2\Tests\Eslint;
9
10
+use PHP_CodeSniffer\Config;
11
use PHPUnit\Framework\TestCase;
12
13
/**
@@ -24,6 +25,10 @@ abstract class AbstractEslintTestCase extends TestCase
24
25
*/
26
protected function assertFileContainsError(string $testFile, array $expectedMessages): void
27
{
28
+ if (Config::getExecutablePath('npm') === null) {
29
+ $this->markTestSkipped('npm is not installed here');
30
+ }
31
+
32
// phpcs:ignore Magento2.Security.InsecureFunction.FoundWithAlternative
33
exec(
34
'npm run eslint -- Magento2/Tests/Eslint/' . $testFile,
0 commit comments