Skip to content

Commit 5445f80

Browse files
author
Ganin, Roman(rganin)
committed
Merge pull request #253 from magento-troll/MAGETWO-35179
[Troll] End-to-end measurements
2 parents beae9c1 + e9d8bd6 commit 5445f80

File tree

16 files changed

+365
-11
lines changed

16 files changed

+365
-11
lines changed

dev/tests/integration/testsuite/Magento/ToolkitFramework/_files/small.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
<value>0</value>
6262
</config>
6363
<config>
64-
<path>system/full_page_cache/varnish/access_lis</path>
64+
<path>system/full_page_cache/varnish/access_list</path>
6565
<scope>default</scope>
6666
<scopeId>0</scopeId>
6767
<value>localhost</value>

dev/tools/performance-toolkit/fixtures/cart_price_rules.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,10 @@ class CartPriceRulesFixture extends \Magento\ToolkitFramework\Fixture
2020
public function execute()
2121
{
2222
$this->application->resetObjectManager();
23-
$cartPriceRulesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('cart_price_rules', 9);
23+
$cartPriceRulesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('cart_price_rules', 0);
24+
if (!$cartPriceRulesCount) {
25+
return;
26+
}
2427
$cartPriceRulesProductsFloor = \Magento\ToolkitFramework\Config::getInstance()->getValue(
2528
'cart_price_rules_floor',
2629
3

dev/tools/performance-toolkit/fixtures/catalog_price_rules.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ class CatalogPriceRulesFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22-
$catalogPriceRulesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('catalog_price_rules', 3);
22+
$catalogPriceRulesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('catalog_price_rules', 0);
23+
if (!$catalogPriceRulesCount) {
24+
return;
25+
}
2326
$this->application->resetObjectManager();
2427

2528
/** @var \Magento\Store\Model\StoreManager $storeManager */

dev/tools/performance-toolkit/fixtures/categories.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ class CategoriesFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22-
$categoriesNumber = \Magento\ToolkitFramework\Config::getInstance()->getValue('categories', 18);
22+
$categoriesNumber = \Magento\ToolkitFramework\Config::getInstance()->getValue('categories', 0);
23+
if (!$categoriesNumber) {
24+
return;
25+
}
2326
$maxNestingLevel = \Magento\ToolkitFramework\Config::getInstance()->getValue('categories_nesting_level', 3);
2427
$this->application->resetObjectManager();
2528

dev/tools/performance-toolkit/fixtures/configs_apply.php

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,9 @@ class ConfigsApplyFixture extends \Magento\ToolkitFramework\Fixture
2020
public function execute()
2121
{
2222
$configs = \Magento\ToolkitFramework\Config::getInstance()->getValue('configs', array());
23+
if (empty($configs)) {
24+
return;
25+
}
2326
$this->application->resetObjectManager();
2427

2528
foreach ($configs['config'] as $config) {

dev/tools/performance-toolkit/fixtures/configurable_products.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -820,7 +820,10 @@ protected function getRows($productCategory, $productRootCategory, $productWebsi
820820
*/
821821
public function execute()
822822
{
823-
$configurablesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('configurable_products', 90);
823+
$configurablesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('configurable_products', 0);
824+
if (!$configurablesCount) {
825+
return;
826+
}
824827
$this->application->resetObjectManager();
825828

826829
/** @var \Magento\Store\Model\StoreManager $storeManager */

dev/tools/performance-toolkit/fixtures/customers.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ class CustomersFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22-
$customersNumber = \Magento\ToolkitFramework\Config::getInstance()->getValue('customers', 10);
22+
$customersNumber = \Magento\ToolkitFramework\Config::getInstance()->getValue('customers', 0);
23+
if (!$customersNumber) {
24+
return;
25+
}
2326
$this->application->resetObjectManager();
2427

2528
/** @var \Magento\Store\Model\StoreManager $storeManager */

dev/tools/performance-toolkit/fixtures/eav_variations.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ class EavVariationsFixture extends \Magento\ToolkitFramework\Fixture
2121
*/
2222
public function execute()
2323
{
24+
$configurablesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('configurable_products', 0);
25+
if (!$configurablesCount) {
26+
return;
27+
}
2428
$this->application->resetObjectManager();
2529

2630
/* @var $model \Magento\Catalog\Model\Resource\Eav\Attribute */

dev/tools/performance-toolkit/fixtures/orders.php

Lines changed: 314 additions & 0 deletions
Large diffs are not rendered by default.

dev/tools/performance-toolkit/fixtures/simple_products.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,10 @@ class SimpleProductsFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22-
$simpleProductsCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('simple_products', 180);
22+
$simpleProductsCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('simple_products', 0);
23+
if (!$simpleProductsCount) {
24+
return;
25+
}
2326
$this->application->resetObjectManager();
2427

2528
/** @var \Magento\Store\Model\StoreManager $storeManager */

dev/tools/performance-toolkit/fixtures/stores.php

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,12 @@ class StoresFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22-
$websitesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('websites', 2);
23-
$storeGroupsCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('store_groups', 3);
24-
$storesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('store_views', 5);
22+
$websitesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('websites', 0);
23+
$storeGroupsCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('store_groups', 0);
24+
$storesCount = \Magento\ToolkitFramework\Config::getInstance()->getValue('store_views', 0);
25+
if (!$websitesCount || !$storeGroupsCount || !$storesCount) {
26+
return;
27+
}
2528
$this->application->resetObjectManager();
2629

2730
/** @var \Magento\Store\Model\StoreManager $storeManager */

dev/tools/performance-toolkit/fixtures/tax_rates.php

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ class TaxRatesFixture extends \Magento\ToolkitFramework\Fixture
1919
*/
2020
public function execute()
2121
{
22+
$taxRatesFile = \Magento\ToolkitFramework\Config::getInstance()->getValue('tax_rates_file', null);
23+
if (empty($taxRatesFile)) {
24+
return;
25+
}
2226
$this->application->resetObjectManager();
2327
/** Clean predefined tax rates to maintain consistency */
2428
/** @var $collection Magento\Tax\Model\Resource\Calculation\Rate\Collection */
@@ -36,7 +40,7 @@ public function execute()
3640
/**
3741
* Import tax rates with import handler
3842
*/
39-
$filename = realpath(__DIR__ . '/tax_rates.csv');
43+
$filename = realpath(__DIR__ . '/' . $taxRatesFile);
4044
$file = [
4145
'name' => $filename,
4246
'type' => 'application/vnd.ms-excel',

dev/tools/performance-toolkit/profiles/ce/extra_large.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
<cart_price_rules>100</cart_price_rules> <!-- Number of shopping cart price rules -->
1919
<cart_price_rules_floor>5</cart_price_rules_floor> <!-- The price rule condition: minimum products amount in shopping cart for price rule to be applied -->
2020
<customers>5000</customers> <!-- Number of customers to generate -->
21+
<tax_rates_file>tax_rates.csv</tax_rates_file> <!-- Tax rates file in fixtures directory-->
22+
<orders>80000</orders> <!-- Orders count -->
2123
<configs> <!-- Config variables and values for change -->
2224
<config>
2325
<path>admin/security/use_form_key</path>

dev/tools/performance-toolkit/profiles/ce/large.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
<cart_price_rules>50</cart_price_rules> <!-- Number of shopping cart price rules -->
1919
<cart_price_rules_floor>2</cart_price_rules_floor> <!-- The price rule condition: minimum products amount in shopping cart for price rule to be applied -->
2020
<customers>2000</customers> <!-- Number of customers to generate -->
21+
<tax_rates_file>tax_rates.csv</tax_rates_file> <!-- Tax rates file in fixtures directory-->
22+
<orders>40000</orders> <!-- Orders count -->
2123
<configs> <!-- Config variables and values for change -->
2224
<config>
2325
<path>admin/security/use_form_key</path>

dev/tools/performance-toolkit/profiles/ce/medium.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
<cart_price_rules>20</cart_price_rules> <!-- Number of shopping cart price rules -->
1919
<cart_price_rules_floor>2</cart_price_rules_floor> <!-- The price rule condition: minimum products amount in shopping cart for price rule to be applied -->
2020
<customers>200</customers> <!-- Number of customers to generate -->
21+
<tax_rates_file>tax_rates.csv</tax_rates_file> <!-- Tax rates file in fixtures directory-->
22+
<orders>1600</orders> <!-- Orders count -->
2123
<configs> <!-- Config variables and values for change -->
2224
<config>
2325
<path>admin/security/use_form_key</path>

dev/tools/performance-toolkit/profiles/ce/small.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,8 @@
1818
<cart_price_rules>10</cart_price_rules> <!-- Number of shopping cart price rules -->
1919
<cart_price_rules_floor>2</cart_price_rules_floor> <!-- The price rule condition: minimum products amount in shopping cart for price rule to be applied -->
2020
<customers>20</customers> <!-- Number of customers to generate -->
21+
<tax_rates_file>tax_rates.csv</tax_rates_file> <!-- Tax rates file in fixtures directory-->
22+
<orders>80</orders> <!-- Orders count -->
2123
<configs> <!-- Config variables and values for change -->
2224
<config>
2325
<path>admin/security/use_form_key</path>

0 commit comments

Comments
 (0)