-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
MAGETWO-52717: [GitHub] Configurable product disabling lowest price a…
…ssociated product still shows its price #4419 -- fix integration tests
- Loading branch information
vnayda
committed
Oct 6, 2016
1 parent
0027ad7
commit a86ea1c
Showing
7 changed files
with
40 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
...uite/Magento/ConfigurableProduct/_files/configurable_product_with_two_simple_rollback.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<?php | ||
/** | ||
* Copyright © 2016 Magento. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
use Magento\Catalog\Api\ProductRepositoryInterface; | ||
use Magento\Framework\Exception\NoSuchEntityException; | ||
use Magento\TestFramework\Helper\Bootstrap; | ||
|
||
$objectManager = Bootstrap::getObjectManager(); | ||
/** @var ProductRepositoryInterface $productRepository */ | ||
$productRepository = Bootstrap::getObjectManager()->get(ProductRepositoryInterface::class); | ||
|
||
foreach (['sku_10', 'sku_20', 'configurable_product_with_two_simple'] as $sku) { | ||
try { | ||
$product = $productRepository->get($sku, false, null, true); | ||
$productRepository->delete($product); | ||
} catch (NoSuchEntityException $e) { | ||
//Product already removed | ||
} | ||
} | ||
|
||
require __DIR__ . '/configurable_attribute_rollback.php'; |