Magento Extensions Rating 2024
EXTENSIONS BY CATEGORY
B2B (Business-To-Business)
Blog
Customer
ERP (Enterprise Resource Planning)
Mega Menu
One Step Checkout
Order
POS (Point Of Sale)
Search
Shopping Cart
Sitemap
SEO
Social
Stock & Inventory Management
EXTENSIONS BY DEVELOPER
aheadWorks
Amasty
Boost My Shop
BSS Commerce
Magestore
MageWorx
Mirasvit
Templates Master
Wyomind
XTENTO
Magento 2 Documentation
Magento 2 Documentation
2.3
Documentation for Magento 2 CMS v2.3 (December 2018)
vendor
magento
magento2-base
dev
tests
static
testsuite
Magento
Test
Tools
Composer
RootComposerMappingTest.php
Go to the documentation of this file.
1
<?php
6
namespace
Magento\Test\Tools\Composer
;
7
8
use Magento\Tools\Composer\Package\Reader;
9
13
class
RootComposerMappingTest
extends
\PHPUnit\Framework\TestCase
14
{
19
public
function
testMapping
()
20
{
21
//Checking existence of composer components
22
$reader =
new
Reader(
BP
.
'/dev/tools/Magento/Tools/Composer'
);
23
$patterns = $reader->getPatterns();
24
$counter = 0;
25
$count
= count($patterns);
26
for
(
$i
= 0;
$i
<
$count
;
$i
++) {
27
if
(file_exists(
BP
.
'/'
. $patterns[
$i
])) {
28
$counter++;
29
}
30
}
31
32
$this->assertEquals(
$count
, $counter);
33
34
//Checking existence of customizable paths
35
$customizablePaths = $reader->getCustomizablePaths();
36
$counter = 0;
37
$count
= count($customizablePaths);
38
for
(
$i
= 0;
$i
<
$count
;
$i
++) {
39
if
(file_exists(
BP
.
'/'
. str_replace(
'*'
,
''
, $customizablePaths[
$i
]))) {
40
$counter++;
41
}
42
}
43
44
$this->assertEquals(
$count
, $counter);
45
}
46
}
$count
$count
Definition:
recent.phtml:13
Magento\Test\Tools\Composer\RootComposerMappingTest
Definition:
RootComposerMappingTest.php:13
Magento\Test\Tools\Composer\RootComposerMappingTest\testMapping
testMapping()
Definition:
RootComposerMappingTest.php:19
BP
const BP
Definition:
autoload.php:14
Magento\Test\Tools\Composer
Definition:
RootComposerMappingTest.php:6
$i
$i
Definition:
gallery.phtml:31