diff --git a/.gitignore b/.gitignore index 39241df7fddd54e703a3e29c5107a18d5cc9c62b..657c315552ed4e9a89623814ed54e2d81903f062 100644 --- a/.gitignore +++ b/.gitignore @@ -32,6 +32,8 @@ atlassian* /pub/media/theme/* /pub/media/theme_customization/* !/pub/media/theme_customization/.htaccess +/pub/media/wysiwyg/* +!/pub/media/wysiwyg/.htaccess /pub/media/tmp/* !/pub/media/tmp/.htaccess /pub/static/* diff --git a/COPYING.txt b/COPYING.txt index 7fafaa3e23d7148ba4df8624b7cb2582cf484554..d7d04f5b7edba818304507c9051c9e5ba195a916 100644 --- a/COPYING.txt +++ b/COPYING.txt @@ -1,7 +1,7 @@ Each Magento source file included in this distribution is licensed under OSL 3.0 or the Magento Enterprise Edition (MEE) license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0) -Please see <insert file name of the OSL license> for the full text of the OSL 3.0 license or contact license@magentocommerce.com for a copy. +Please see LICENSE.txt for the full text of the OSL 3.0 license or contact license@magentocommerce.com for a copy. -Subject to Licensee’s payment of fees and compliance with the terms and conditions of the MEE License, the MEE License supersedes the OSL 3.0 license for each source file. +Subject to Licensee's payment of fees and compliance with the terms and conditions of the MEE License, the MEE License supersedes the OSL 3.0 license for each source file. Please see <insert file name of the MEE license> for the full text of the MEE License or visit http://magento.com/legal/terms/enterprise. \ No newline at end of file diff --git a/app/code/Magento/Backend/etc/di.xml b/app/code/Magento/Backend/etc/di.xml index 2871ef2508f37929a6a1c3af3228d92789511533..5445af580b20c677bc0cff5b40c9bae76fbfeab4 100644 --- a/app/code/Magento/Backend/etc/di.xml +++ b/app/code/Magento/Backend/etc/di.xml @@ -12,7 +12,6 @@ <preference for="Magento\Backend\Model\Config\Structure\SearchInterface" type="Magento\Backend\Model\Config\Structure" /> <preference for="Magento\Backend\Model\Config\Backend\File\RequestData\RequestDataInterface" type="Magento\Backend\Model\Config\Backend\File\RequestData" /> <preference for="Magento\Backend\Model\Auth\Credential\StorageInterface" type="Magento\User\Model\User" /> - <preference for="Magento\Adminhtml\Helper\Data" type="Magento\Backend\Helper\Data" /> <preference for="Magento\Backend\App\ConfigInterface" type="Magento\Backend\App\Config" /> <preference for="Magento\Backend\Model\UrlInterface" type="Magento\Backend\Model\Url" /> <preference for="Magento\Backend\Block\Widget\Button\ToolbarInterface" type="Magento\Backend\Block\Widget\Button\Toolbar" /> diff --git a/app/code/Magento/Backup/Model/Backup.php b/app/code/Magento/Backup/Model/Backup.php index e5ac01021877294b074da4ba5bead0dab74e638f..52f720fea228bcaa3ebfaf6cac8da5f7f5d81fbe 100644 --- a/app/code/Magento/Backup/Model/Backup.php +++ b/app/code/Magento/Backup/Model/Backup.php @@ -6,6 +6,7 @@ namespace Magento\Backup\Model; use Magento\Framework\App\Filesystem\DirectoryList; +use Magento\Framework\Filesystem\DriverPool; /** * Backup file item model @@ -292,11 +293,10 @@ class Backup extends \Magento\Framework\Object implements \Magento\Framework\Bac try { /** @var \Magento\Framework\Filesystem\Directory\WriteInterface $varDirectory */ - $varDirectory = $this->_filesystem->getDirectoryWrite(DirectoryList::VAR_DIR); + $varDirectory = $this->_filesystem->getDirectoryWrite(DirectoryList::VAR_DIR, DriverPool::ZLIB); $this->_stream = $varDirectory->openFile( $this->_getFilePath(), - $mode, - \Magento\Framework\Filesystem\DriverPool::ZLIB + $mode ); } catch (\Magento\Framework\Filesystem\FilesystemException $e) { throw new \Magento\Framework\Backup\Exception\NotEnoughPermissions( diff --git a/app/code/Magento/Bundle/Pricing/Adjustment/Calculator.php b/app/code/Magento/Bundle/Pricing/Adjustment/Calculator.php index 376a1c5f5e62828a6328f8ca0eebbd5afbc7313f..f59d63b4a5353adc68226b586c35b94e7ed6d43a 100644 --- a/app/code/Magento/Bundle/Pricing/Adjustment/Calculator.php +++ b/app/code/Magento/Bundle/Pricing/Adjustment/Calculator.php @@ -314,7 +314,7 @@ class Calculator implements BundleCalculatorInterface /** @var Store $store */ $store = $bundleProduct->getStore(); - $roundingMethod = $this->taxHelper->getCalculationAgorithm($store); + $roundingMethod = $this->taxHelper->getCalculationAlgorithm($store); foreach ($amountList as $amountInfo) { /** @var \Magento\Framework\Pricing\Amount\AmountInterface $itemAmount */ $itemAmount = $amountInfo['amount']; diff --git a/app/code/Magento/Catalog/Model/Product.php b/app/code/Magento/Catalog/Model/Product.php index 32a82364c17a05c2205d7bf31c22287dc19da62e..40a973f14949d90c38d2ba800f15cfdb507db7b9 100644 --- a/app/code/Magento/Catalog/Model/Product.php +++ b/app/code/Magento/Catalog/Model/Product.php @@ -777,8 +777,10 @@ class Product extends \Magento\Catalog\Model\AbstractModel implements */ public function setQty($qty) { - $this->setData('qty', $qty); - $this->reloadPriceInfo(); + if ($this->getData('qty') != $qty) { + $this->setData('qty', $qty); + $this->reloadPriceInfo(); + } return $this; } diff --git a/app/code/Magento/Checkout/Controller/Cart/Configure.php b/app/code/Magento/Checkout/Controller/Cart/Configure.php index 1a0fc1f3148f350051b14497ac9dd8fbec9daf99..0c09470858bd3bbf929fc9a5667b64a497bb1a57 100644 --- a/app/code/Magento/Checkout/Controller/Cart/Configure.php +++ b/app/code/Magento/Checkout/Controller/Cart/Configure.php @@ -44,18 +44,19 @@ class Configure extends \Magento\Checkout\Controller\Cart { // Extract item and product to configure $id = (int)$this->getRequest()->getParam('id'); + $productId = (int)$this->getRequest()->getParam('product_id'); $quoteItem = null; if ($id) { $quoteItem = $this->cart->getQuote()->getItemById($id); } - if (!$quoteItem) { - $this->messageManager->addError(__("We can't find the quote item.")); - $this->_redirect('checkout/cart'); - return; - } - try { + if (!$quoteItem || $productId != $quoteItem->getProduct()->getId()) { + $this->messageManager->addError(__("We can't find the quote item.")); + $this->_redirect('checkout/cart'); + return; + } + $params = new \Magento\Framework\Object(); $params->setCategoryId(false); $params->setConfigureMode(true); diff --git a/app/code/Magento/Checkout/Controller/Cart/Index.php b/app/code/Magento/Checkout/Controller/Cart/Index.php index cd0bb023dcaab629d303f7366b492e10be72d7df..456cb28e563e3c7cc8ba49188b9873f5a864838a 100644 --- a/app/code/Magento/Checkout/Controller/Cart/Index.php +++ b/app/code/Magento/Checkout/Controller/Cart/Index.php @@ -15,6 +15,7 @@ class Index extends \Magento\Checkout\Controller\Cart */ public function execute() { + $this->_eventManager->dispatch('collect_totals_failed_items'); if ($this->cart->getQuote()->getItemsCount()) { $this->cart->init(); $this->cart->save(); diff --git a/app/code/Magento/Checkout/view/frontend/layout/checkout_onepage_success.xml b/app/code/Magento/Checkout/view/frontend/layout/checkout_onepage_success.xml index 22ca2df12cec6add0680d95fcd284acc646ce85f..3fdbfc2c3cabc3be035e98cabd7a2f36cbb42456 100644 --- a/app/code/Magento/Checkout/view/frontend/layout/checkout_onepage_success.xml +++ b/app/code/Magento/Checkout/view/frontend/layout/checkout_onepage_success.xml @@ -6,6 +6,9 @@ */ --> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" layout="1column" xsi:noNamespaceSchemaLocation="../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd"> + <head> + <title>Success Page</title> + </head> <body> <referenceBlock name="page.main.title"> <block class="Magento\Checkout\Block\Onepage\Success" name="checkout.success.print.button" template="button.phtml"/> diff --git a/app/code/Magento/Core/etc/di.xml b/app/code/Magento/Core/etc/di.xml index cc73a8a5b388c8f7b565c7f114e408f4f851146e..3b6eb72b2b36b6088129f44d1e8a9be0a83e1da4 100644 --- a/app/code/Magento/Core/etc/di.xml +++ b/app/code/Magento/Core/etc/di.xml @@ -14,14 +14,12 @@ <preference for="Magento\Framework\Authorization\PolicyInterface" type="Magento\Framework\Authorization\Policy\DefaultPolicy" /> <preference for="Magento\Framework\Authorization\RoleLocatorInterface" type="Magento\Framework\Authorization\RoleLocator\DefaultRoleLocator" /> <preference for="Magento\Framework\Session\SessionManagerInterface" type="Magento\Framework\Session\Generic" /> - <preference for="Magento\Core\Model\DataService\ConfigInterface" type="Magento\Core\Model\DataService\Config" /> <preference for="Magento\Framework\App\Config\ScopeConfigInterface" type="Magento\Framework\App\Config" /> <preference for="Magento\Framework\App\Config\ReinitableConfigInterface" type="Magento\Framework\App\ReinitableConfig" /> <preference for="Magento\Framework\App\Config\MutableScopeConfigInterface" type="Magento\Framework\App\MutableScopeConfig" /> <preference for="Magento\Framework\App\Config\Storage\WriterInterface" type="Magento\Framework\App\Config\Storage\Writer" /> <preference for="Magento\Framework\View\Design\Theme\FileInterface" type="Magento\Core\Model\Theme\File" /> <preference for="Magento\Framework\Config\ConverterInterface" type="Magento\Framework\Config\Converter\Dom"/> - <preference for="Magento\Core\Model\Url\SecurityInfoInterface" type="Magento\Core\Model\Url\SecurityInfo\Proxy" /> <preference for="Magento\Framework\App\DefaultPathInterface" type="Magento\Framework\App\DefaultPath\DefaultPath" /> <preference for="Magento\Framework\Encryption\EncryptorInterface" type="Magento\Framework\Encryption\Encryptor" /> <preference for="Magento\Framework\Filter\Encrypt\AdapterInterface" type="Magento\Framework\Filter\Encrypt\Basic" /> diff --git a/app/code/Magento/Customer/Model/Resource/Address.php b/app/code/Magento/Customer/Model/Resource/Address.php index bec7eec4634435e086829198f20f6284aea49c25..c047a54d3eeb81ef3976e7041ff68b8e382d1ae2 100644 --- a/app/code/Magento/Customer/Model/Resource/Address.php +++ b/app/code/Magento/Customer/Model/Resource/Address.php @@ -12,7 +12,7 @@ use Magento\Framework\Exception\InputException; class Address extends \Magento\Eav\Model\Entity\AbstractEntity { /** - * @var \Magento\Core\Model\Validator\Factory + * @var \Magento\Framework\Validator\Factory */ protected $_validatorFactory; @@ -28,7 +28,7 @@ class Address extends \Magento\Eav\Model\Entity\AbstractEntity * @param \Magento\Framework\Locale\FormatInterface $localeFormat * @param \Magento\Eav\Model\Resource\Helper $resourceHelper * @param \Magento\Framework\Validator\UniversalFactory $universalFactory - * @param \Magento\Core\Model\Validator\Factory $validatorFactory + * @param \Magento\Framework\Validator\Factory $validatorFactory * @param \Magento\Customer\Model\CustomerFactory $customerFactory * @param array $data */ @@ -39,7 +39,7 @@ class Address extends \Magento\Eav\Model\Entity\AbstractEntity \Magento\Framework\Locale\FormatInterface $localeFormat, \Magento\Eav\Model\Resource\Helper $resourceHelper, \Magento\Framework\Validator\UniversalFactory $universalFactory, - \Magento\Core\Model\Validator\Factory $validatorFactory, + \Magento\Framework\Validator\Factory $validatorFactory, \Magento\Customer\Model\CustomerFactory $customerFactory, $data = [] ) { diff --git a/app/code/Magento/Customer/Model/Resource/Customer.php b/app/code/Magento/Customer/Model/Resource/Customer.php index 9e250f63655976dc000b2fd8a4ee571d918d2574..3b406e0ff3902fe5675882bff56b67d7a010754a 100644 --- a/app/code/Magento/Customer/Model/Resource/Customer.php +++ b/app/code/Magento/Customer/Model/Resource/Customer.php @@ -13,7 +13,7 @@ use Magento\Framework\Exception\InputException; class Customer extends \Magento\Eav\Model\Entity\AbstractEntity { /** - * @var \Magento\Core\Model\Validator\Factory + * @var \Magento\Framework\Validator\Factory */ protected $_validatorFactory; @@ -37,7 +37,7 @@ class Customer extends \Magento\Eav\Model\Entity\AbstractEntity * @param \Magento\Eav\Model\Resource\Helper $resourceHelper * @param \Magento\Framework\Validator\UniversalFactory $universalFactory * @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig - * @param \Magento\Core\Model\Validator\Factory $validatorFactory + * @param \Magento\Framework\Validator\Factory $validatorFactory * @param \Magento\Framework\Stdlib\DateTime $dateTime * @param array $data */ @@ -49,7 +49,7 @@ class Customer extends \Magento\Eav\Model\Entity\AbstractEntity \Magento\Eav\Model\Resource\Helper $resourceHelper, \Magento\Framework\Validator\UniversalFactory $universalFactory, \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig, - \Magento\Core\Model\Validator\Factory $validatorFactory, + \Magento\Framework\Validator\Factory $validatorFactory, \Magento\Framework\Stdlib\DateTime $dateTime, $data = [] ) { diff --git a/app/code/Magento/Directory/Model/PriceCurrency.php b/app/code/Magento/Directory/Model/PriceCurrency.php index 6e6b5872f379550ac670f24d3a4b846eb7fab12b..8232d9220b4128888b13b215597efa9a22e3c601 100644 --- a/app/code/Magento/Directory/Model/PriceCurrency.php +++ b/app/code/Magento/Directory/Model/PriceCurrency.php @@ -58,18 +58,12 @@ class PriceCurrency implements \Magento\Framework\Pricing\PriceCurrencyInterface } /** - * Convert and round price value for specified store or passed currency - * - * @param float $amount - * @param null|string|bool|int|\Magento\Store\Model\Store $store - * @param Currency|string|null $currency - * @param int $precision - * @return float + * {@inheritdoc} */ - public function convertAndRound($amount, $store = null, $currency = null, $precision = self::DEFAULT_PRECISION) + public function convertAndRound($amount, $scope = null, $currency = null, $precision = self::DEFAULT_PRECISION) { - $currentCurrency = $this->getCurrency($store, $currency); - $convertedValue = $this->getStore($store)->getBaseCurrency()->convert($amount, $currentCurrency); + $currentCurrency = $this->getCurrency($scope, $currency); + $convertedValue = $this->getStore($scope)->getBaseCurrency()->convert($amount, $currentCurrency); return round($convertedValue, $precision); } diff --git a/app/code/Magento/Email/Model/AbstractTemplate.php b/app/code/Magento/Email/Model/AbstractTemplate.php index ca38c73e7c6243ea8e1610b4b5aba0425f9876d9..dbc58086db9bc348c5b92496c4c489e4b68cdc7f 100644 --- a/app/code/Magento/Email/Model/AbstractTemplate.php +++ b/app/code/Magento/Email/Model/AbstractTemplate.php @@ -56,7 +56,7 @@ abstract class AbstractTemplate extends AbstractModel implements TemplateTypesIn protected $_design = null; /** - * @var \Magento\Core\Model\App\Emulation + * @var \Magento\Store\Model\App\Emulation */ protected $_appEmulation; @@ -69,7 +69,7 @@ abstract class AbstractTemplate extends AbstractModel implements TemplateTypesIn * @param \Magento\Framework\Model\Context $context * @param \Magento\Framework\View\DesignInterface $design * @param \Magento\Framework\Registry $registry - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param array $data */ @@ -77,7 +77,7 @@ abstract class AbstractTemplate extends AbstractModel implements TemplateTypesIn \Magento\Framework\Model\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Registry $registry, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Store\Model\StoreManagerInterface $storeManager, array $data = [] ) { diff --git a/app/code/Magento/Email/Model/BackendTemplate.php b/app/code/Magento/Email/Model/BackendTemplate.php index abc963099c9b558588bf5580684ba0700116a2f4..27c6084b4382fb0ac0aad564a7d5edf92742ebad 100644 --- a/app/code/Magento/Email/Model/BackendTemplate.php +++ b/app/code/Magento/Email/Model/BackendTemplate.php @@ -21,7 +21,7 @@ class BackendTemplate extends Template * @param \Magento\Framework\Model\Context $context * @param \Magento\Framework\View\DesignInterface $design * @param \Magento\Framework\Registry $registry - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Framework\Filesystem $filesystem * @param \Magento\Framework\View\Asset\Repository $assetRepo @@ -38,7 +38,7 @@ class BackendTemplate extends Template \Magento\Framework\Model\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Registry $registry, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Framework\Filesystem $filesystem, \Magento\Framework\View\Asset\Repository $assetRepo, diff --git a/app/code/Magento/Email/Model/Template.php b/app/code/Magento/Email/Model/Template.php index a397317ff4cd9474192f26d83d8a35f0a30fe07f..e3b52978ca6541b3004af2ed20b1d42fe9ab9575 100644 --- a/app/code/Magento/Email/Model/Template.php +++ b/app/code/Magento/Email/Model/Template.php @@ -157,7 +157,7 @@ class Template extends \Magento\Email\Model\AbstractTemplate implements \Magento * @param \Magento\Framework\Model\Context $context * @param \Magento\Framework\View\DesignInterface $design * @param \Magento\Framework\Registry $registry - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Framework\Filesystem $filesystem * @param \Magento\Framework\View\Asset\Repository $assetRepo @@ -173,7 +173,7 @@ class Template extends \Magento\Email\Model\AbstractTemplate implements \Magento \Magento\Framework\Model\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Registry $registry, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, StoreManagerInterface $storeManager, \Magento\Framework\Filesystem $filesystem, \Magento\Framework\View\Asset\Repository $assetRepo, diff --git a/app/code/Magento/Multishipping/view/frontend/layout/multishipping_checkout_success.xml b/app/code/Magento/Multishipping/view/frontend/layout/multishipping_checkout_success.xml index 5ea53255269edf7ca4d32b50a0b90fe176d3c146..e9bca9477d829c01fe0c92260310c6378b5a71ac 100644 --- a/app/code/Magento/Multishipping/view/frontend/layout/multishipping_checkout_success.xml +++ b/app/code/Magento/Multishipping/view/frontend/layout/multishipping_checkout_success.xml @@ -7,6 +7,9 @@ --> <page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd"> <update handle="multishipping_checkout"/> + <head> + <title>Success Page</title> + </head> <body> <referenceBlock name="page.main.title"> <action method="setPageTitle"> diff --git a/app/code/Magento/Newsletter/Model/Queue.php b/app/code/Magento/Newsletter/Model/Queue.php index cb84858cfff0b77e1b3e28a75d8f553df892a206..85b50fa153d49d3d1f3796adf69afb657661052c 100644 --- a/app/code/Magento/Newsletter/Model/Queue.php +++ b/app/code/Magento/Newsletter/Model/Queue.php @@ -114,7 +114,7 @@ class Queue extends \Magento\Email\Model\AbstractTemplate * @param \Magento\Framework\Model\Context $context * @param \Magento\Framework\View\DesignInterface $design * @param \Magento\Framework\Registry $registry - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Newsletter\Model\Template\Filter $templateFilter * @param \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate @@ -129,7 +129,7 @@ class Queue extends \Magento\Email\Model\AbstractTemplate \Magento\Framework\Model\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Registry $registry, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Newsletter\Model\Template\Filter $templateFilter, \Magento\Framework\Stdlib\DateTime\TimezoneInterface $localeDate, diff --git a/app/code/Magento/Newsletter/Model/Template.php b/app/code/Magento/Newsletter/Model/Template.php index ddb12607ece31ab8514cd981bfdedfb16f2852cc..46f0270e193b49931f9dafc7b2534d3d4c023b78 100644 --- a/app/code/Magento/Newsletter/Model/Template.php +++ b/app/code/Magento/Newsletter/Model/Template.php @@ -93,7 +93,7 @@ class Template extends \Magento\Email\Model\AbstractTemplate * @param \Magento\Framework\Model\Context $context * @param \Magento\Framework\View\DesignInterface $design * @param \Magento\Framework\Registry $registry - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Framework\App\RequestInterface $request * @param \Magento\Newsletter\Model\Template\Filter $filter @@ -106,7 +106,7 @@ class Template extends \Magento\Email\Model\AbstractTemplate \Magento\Framework\Model\Context $context, \Magento\Framework\View\DesignInterface $design, \Magento\Framework\Registry $registry, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Framework\App\RequestInterface $request, \Magento\Newsletter\Model\Template\Filter $filter, diff --git a/app/code/Magento/OfflinePayments/Block/Form/AbstractInstruction.php b/app/code/Magento/OfflinePayments/Block/Form/AbstractInstruction.php new file mode 100644 index 0000000000000000000000000000000000000000..4ad7357cfdad92245256ae974a65cdc7ab7497b5 --- /dev/null +++ b/app/code/Magento/OfflinePayments/Block/Form/AbstractInstruction.php @@ -0,0 +1,32 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Block\Form; + +/** + * Abstract class for Cash On Delivery and Bank Transfer payment method form + */ +abstract class AbstractInstruction extends \Magento\Payment\Block\Form +{ + /** + * Instructions text + * + * @var string + */ + protected $_instructions; + + /** + * Get instructions text from config + * + * @return string + */ + public function getInstructions() + { + if (is_null($this->_instructions)) { + $this->_instructions = $this->getMethod()->getInstructions(); + } + return $this->_instructions; + } +} diff --git a/app/code/Magento/OfflinePayments/Block/Form/Banktransfer.php b/app/code/Magento/OfflinePayments/Block/Form/Banktransfer.php index 1693929cdaabdc74e1661aee498d1d1bbf13765b..d71654418a38f9dc5a8939c6fa0952a0f3ab4edf 100644 --- a/app/code/Magento/OfflinePayments/Block/Form/Banktransfer.php +++ b/app/code/Magento/OfflinePayments/Block/Form/Banktransfer.php @@ -8,32 +8,12 @@ namespace Magento\OfflinePayments\Block\Form; /** * Block for Bank Transfer payment method form */ -class Banktransfer extends \Magento\Payment\Block\Form +class Banktransfer extends \Magento\OfflinePayments\Block\Form\AbstractInstruction { - /** - * Instructions text - * - * @var string - */ - protected $_instructions; - /** * Bank transfer template * * @var string */ protected $_template = 'form/banktransfer.phtml'; - - /** - * Get instructions text from config - * - * @return string - */ - public function getInstructions() - { - if (is_null($this->_instructions)) { - $this->_instructions = $this->getMethod()->getInstructions(); - } - return $this->_instructions; - } } diff --git a/app/code/Magento/OfflinePayments/Block/Form/Cashondelivery.php b/app/code/Magento/OfflinePayments/Block/Form/Cashondelivery.php index af0850e5860b8a762eb3b5ae0ce13ae1950aeea6..1e14cabb9ba2b08204d3b62a029f2aa793f22d62 100644 --- a/app/code/Magento/OfflinePayments/Block/Form/Cashondelivery.php +++ b/app/code/Magento/OfflinePayments/Block/Form/Cashondelivery.php @@ -8,32 +8,12 @@ namespace Magento\OfflinePayments\Block\Form; /** * Block for Cash On Delivery payment method form */ -class Cashondelivery extends \Magento\Payment\Block\Form +class Cashondelivery extends \Magento\OfflinePayments\Block\Form\AbstractInstruction { - /** - * Instructions text - * - * @var string - */ - protected $_instructions; - /** * Cash on delivery template * * @var string */ protected $_template = 'form/cashondelivery.phtml'; - - /** - * Get instructions text from config - * - * @return string - */ - public function getInstructions() - { - if (is_null($this->_instructions)) { - $this->_instructions = $this->getMethod()->getInstructions(); - } - return $this->_instructions; - } } diff --git a/app/code/Magento/OfflinePayments/Model/Banktransfer.php b/app/code/Magento/OfflinePayments/Model/Banktransfer.php index 044dd3301ba602fa85727bd7e6f9a71d5e816d75..4cc48a575272039644fe0c1211c4172249647f60 100644 --- a/app/code/Magento/OfflinePayments/Model/Banktransfer.php +++ b/app/code/Magento/OfflinePayments/Model/Banktransfer.php @@ -39,14 +39,4 @@ class Banktransfer extends \Magento\Payment\Model\Method\AbstractMethod * @var bool */ protected $_isOffline = true; - - /** - * Get instructions text from config - * - * @return string - */ - public function getInstructions() - { - return trim($this->getConfigData('instructions')); - } } diff --git a/app/code/Magento/OfflinePayments/Model/Observer.php b/app/code/Magento/OfflinePayments/Model/Observer.php index 61fc00d538940128a62e8aecafed8b3c22a7c433..1cb45ac753f568f3ffca0f55a33ea4a8a14d2000 100644 --- a/app/code/Magento/OfflinePayments/Model/Observer.php +++ b/app/code/Magento/OfflinePayments/Model/Observer.php @@ -21,9 +21,11 @@ class Observer { /** @var \Magento\Sales\Model\Order\Payment $payment */ $payment = $observer->getEvent()->getPayment(); - $banktransfer = \Magento\OfflinePayments\Model\Banktransfer::PAYMENT_METHOD_BANKTRANSFER_CODE; - if ($payment->getMethod() === $banktransfer) { - $payment->setAdditionalInformation('instructions', $payment->getMethodInstance()->getInstructions()); + if ($payment->getMethod() === Banktransfer::PAYMENT_METHOD_BANKTRANSFER_CODE) { + $payment->setAdditionalInformation( + 'instructions', + $payment->getMethodInstance()->getConfigData('instructions') + ); } } } diff --git a/app/code/Magento/OfflineShipping/Model/Config/Backend/Tablerate.php b/app/code/Magento/OfflineShipping/Model/Config/Backend/Tablerate.php index 6056d7dbbb79206acb1bbc821790824db609a667..c0b311a1073addee40ce31187c130a2d8f7dfc98 100644 --- a/app/code/Magento/OfflineShipping/Model/Config/Backend/Tablerate.php +++ b/app/code/Magento/OfflineShipping/Model/Config/Backend/Tablerate.php @@ -46,6 +46,8 @@ class Tablerate extends \Magento\Framework\App\Config\Value */ public function afterSave() { - $this->_tablerateFactory->create()->uploadAndImport($this); + /** @var \Magento\OfflineShipping\Model\Resource\Carrier\Tablerate $tableRate */ + $tableRate = $this->_tablerateFactory->create(); + $tableRate->uploadAndImport($this); } } diff --git a/app/code/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTab.php b/app/code/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTab.php index b1e56563d747751aa40a5e68d34fbf05dee31348..10068f3d7e548a1d290ddc5dcc98a4e934dcab03 100644 --- a/app/code/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTab.php +++ b/app/code/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTab.php @@ -24,22 +24,24 @@ class ActionsTab $form = $observer->getForm(); foreach ($form->getElements() as $element) { /** @var \Magento\Framework\Data\Form\Element\AbstractElement $element */ - if ($element->getId() == 'action_fieldset') { - $element->addField( - 'simple_free_shipping', - 'select', - [ - 'label' => __('Free Shipping'), - 'title' => __('Free Shipping'), - 'name' => 'simple_free_shipping', - 'options' => [ - 0 => __('No'), - Rule::FREE_SHIPPING_ITEM => __('For matching items only'), - Rule::FREE_SHIPPING_ADDRESS => __('For shipment with matching items'), - ] - ] - ); + if ($element->getId() != 'action_fieldset') { + continue; } + + $element->addField( + 'simple_free_shipping', + 'select', + [ + 'label' => __('Free Shipping'), + 'title' => __('Free Shipping'), + 'name' => 'simple_free_shipping', + 'options' => [ + 0 => __('No'), + Rule::FREE_SHIPPING_ITEM => __('For matching items only'), + Rule::FREE_SHIPPING_ADDRESS => __('For shipment with matching items'), + ] + ] + ); } } } diff --git a/app/code/Magento/Payment/Block/Info/Instructions.php b/app/code/Magento/Payment/Block/Info/Instructions.php index 2caeeb5f2f9e65098cdbc7ea5876b7f30ebc4771..55ffee89fa13694ff993d40637e4a2e14c2ba205 100644 --- a/app/code/Magento/Payment/Block/Info/Instructions.php +++ b/app/code/Magento/Payment/Block/Info/Instructions.php @@ -33,7 +33,7 @@ class Instructions extends \Magento\Payment\Block\Info if (is_null($this->_instructions)) { $this->_instructions = $this->getInfo()->getAdditionalInformation( 'instructions' - ) ?: $this->getMethod()->getInstructions(); + ) ?: $this->getMethod()->getConfigData('instructions'); } return $this->_instructions; } diff --git a/app/code/Magento/Payment/Helper/Data.php b/app/code/Magento/Payment/Helper/Data.php index ea221a6b8d3843863b4d70ce460e8f6ba5075812..2cdabe15c30e0d38260f48a737e84a88fad9e3bc 100644 --- a/app/code/Magento/Payment/Helper/Data.php +++ b/app/code/Magento/Payment/Helper/Data.php @@ -52,7 +52,7 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper /** * App emulation model * - * @var \Magento\Core\Model\App\Emulation + * @var \Magento\Store\Model\App\Emulation */ protected $_appEmulation; @@ -68,7 +68,7 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper * @param \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig * @param LayoutFactory $layoutFactory * @param \Magento\Payment\Model\Method\Factory $paymentMethodFactory - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Payment\Model\Config $paymentConfig * @param \Magento\Framework\App\Config\Initial $initialConfig */ @@ -77,7 +77,7 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper \Magento\Framework\App\Config\ScopeConfigInterface $scopeConfig, LayoutFactory $layoutFactory, \Magento\Payment\Model\Method\Factory $paymentMethodFactory, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Payment\Model\Config $paymentConfig, \Magento\Framework\App\Config\Initial $initialConfig ) { diff --git a/app/code/Magento/ProductAlert/Model/Email.php b/app/code/Magento/ProductAlert/Model/Email.php index f90b089bfdead24d0a6385e43eb05fed9ba4eb08..cc7842121d556b0329f8d8e494ec99a54127d85e 100644 --- a/app/code/Magento/ProductAlert/Model/Email.php +++ b/app/code/Magento/ProductAlert/Model/Email.php @@ -92,7 +92,7 @@ class Email extends \Magento\Framework\Model\AbstractModel protected $customerRepository; /** - * @var \Magento\Core\Model\App\Emulation + * @var \Magento\Store\Model\App\Emulation */ protected $_appEmulation; @@ -114,7 +114,7 @@ class Email extends \Magento\Framework\Model\AbstractModel * @param \Magento\Store\Model\StoreManagerInterface $storeManager * @param \Magento\Customer\Api\CustomerRepositoryInterface $customerRepository * @param \Magento\Customer\Helper\View $customerHelper - * @param \Magento\Core\Model\App\Emulation $appEmulation + * @param \Magento\Store\Model\App\Emulation $appEmulation * @param \Magento\Framework\Mail\Template\TransportBuilder $transportBuilder * @param \Magento\Framework\Model\Resource\AbstractResource $resource * @param \Magento\Framework\Data\Collection\Db $resourceCollection @@ -128,7 +128,7 @@ class Email extends \Magento\Framework\Model\AbstractModel \Magento\Store\Model\StoreManagerInterface $storeManager, \Magento\Customer\Api\CustomerRepositoryInterface $customerRepository, \Magento\Customer\Helper\View $customerHelper, - \Magento\Core\Model\App\Emulation $appEmulation, + \Magento\Store\Model\App\Emulation $appEmulation, \Magento\Framework\Mail\Template\TransportBuilder $transportBuilder, \Magento\Framework\Model\Resource\AbstractResource $resource = null, \Magento\Framework\Data\Collection\Db $resourceCollection = null, diff --git a/app/code/Magento/Sales/Model/Order/Invoice/Total/Subtotal.php b/app/code/Magento/Sales/Model/Order/Invoice/Total/Subtotal.php index b36e7cfabfefa62251a43c301d2cdce0ffeb87b5..1b10667eaaddd1c8abcde92cd9b08e5f8d46a2b3 100644 --- a/app/code/Magento/Sales/Model/Order/Invoice/Total/Subtotal.php +++ b/app/code/Magento/Sales/Model/Order/Invoice/Total/Subtotal.php @@ -37,46 +37,15 @@ class Subtotal extends AbstractTotal $allowedSubtotal = $order->getSubtotal() - $order->getSubtotalInvoiced(); $baseAllowedSubtotal = $order->getBaseSubtotal() - $order->getBaseSubtotalInvoiced(); - $allowedSubtotalInclTax = $allowedSubtotal + - $order->getHiddenTaxAmount() + - $order->getTaxAmount() - - $order->getTaxInvoiced() - - $order->getHiddenTaxInvoiced(); - $baseAllowedSubtotalInclTax = $baseAllowedSubtotal + - $order->getBaseHiddenTaxAmount() + - $order->getBaseTaxAmount() - - $order->getBaseTaxInvoiced() - - $order->getBaseHiddenTaxInvoiced(); - - /** - * Check if shipping tax calculation is included to current invoice. - */ - $includeShippingTax = true; - foreach ($invoice->getOrder()->getInvoiceCollection() as $previousInvoice) { - if ($previousInvoice->getShippingAmount() && !$previousInvoice->isCanceled()) { - $includeShippingTax = false; - break; - } - } - - if ($includeShippingTax) { - $allowedSubtotalInclTax -= $order->getShippingTaxAmount(); - $baseAllowedSubtotalInclTax -= $order->getBaseShippingTaxAmount(); - } else { - $allowedSubtotalInclTax += $order->getShippingHiddenTaxAmount(); - $baseAllowedSubtotalInclTax += $order->getBaseShippingHiddenTaxAmount(); - } + //Note: The $subtotalInclTax and $baseSubtotalInclTax are not adjusted from those provide by the line items + //because the "InclTax" is displayed before any tax adjustments based on discounts, shipping, etc. if ($invoice->isLast()) { $subtotal = $allowedSubtotal; $baseSubtotal = $baseAllowedSubtotal; - $subtotalInclTax = $allowedSubtotalInclTax; - $baseSubtotalInclTax = $baseAllowedSubtotalInclTax; } else { $subtotal = min($allowedSubtotal, $subtotal); $baseSubtotal = min($baseAllowedSubtotal, $baseSubtotal); - $subtotalInclTax = min($allowedSubtotalInclTax, $subtotalInclTax); - $baseSubtotalInclTax = min($baseAllowedSubtotalInclTax, $baseSubtotalInclTax); } $invoice->setSubtotal($subtotal); diff --git a/app/code/Magento/SalesRule/Model/Rule/Action/Discount/ByPercent.php b/app/code/Magento/SalesRule/Model/Rule/Action/Discount/ByPercent.php index 59bc27a01ce7ffa1193b4de3b6dd344bfe5c88c6..19e2f81d657c3c5232fd484eb4cc12eb4750a2cf 100644 --- a/app/code/Magento/SalesRule/Model/Rule/Action/Discount/ByPercent.php +++ b/app/code/Magento/SalesRule/Model/Rule/Action/Discount/ByPercent.php @@ -57,7 +57,9 @@ class ByPercent extends AbstractDiscount $discountData->setAmount(($qty * $itemPrice - $item->getDiscountAmount()) * $_rulePct); $discountData->setBaseAmount(($qty * $baseItemPrice - $item->getBaseDiscountAmount()) * $_rulePct); $discountData->setOriginalAmount(($qty * $itemOriginalPrice - $item->getDiscountAmount()) * $_rulePct); - $discountData->setBaseOriginalAmount(($qty * $baseItemOriginalPrice - $item->getDiscountAmount()) * $_rulePct); + $discountData->setBaseOriginalAmount( + ($qty * $baseItemOriginalPrice - $item->getBaseDiscountAmount()) * $_rulePct + ); if (!$rule->getDiscountQty() || $rule->getDiscountQty() > $qty) { $discountPercent = min(100, $item->getDiscountPercent() + $rulePercent); diff --git a/app/code/Magento/Core/Model/App/Emulation.php b/app/code/Magento/Store/Model/App/Emulation.php similarity index 98% rename from app/code/Magento/Core/Model/App/Emulation.php rename to app/code/Magento/Store/Model/App/Emulation.php index 85f57ad61706303c0d05926efde1d96c1126a7a5..5b64511218ac279cc0bc1bb8c56a4e73436d9f8a 100644 --- a/app/code/Magento/Core/Model/App/Emulation.php +++ b/app/code/Magento/Store/Model/App/Emulation.php @@ -9,8 +9,9 @@ * * @author Magento Core Team <core@magentocommerce.com> */ -namespace Magento\Core\Model\App; +namespace Magento\Store\Model\App; +use Magento\Framework\Object; use Magento\Framework\Translate\Inline\ConfigInterface; class Emulation extends \Magento\Framework\Object @@ -145,7 +146,7 @@ class Emulation extends \Magento\Framework\Object * * Function restores initial store environment * - * @return \Magento\Core\Model\App\Emulation + * @return \Magento\Store\Model\App\Emulation */ public function stopEnvironmentEmulation() { diff --git a/app/code/Magento/Tax/Helper/Data.php b/app/code/Magento/Tax/Helper/Data.php index 38be2cfd6769e4afd5ff0e225e5e1cf7d8b8da7a..8d824e169c8881c5f5dc3d9583505050b0caada2 100644 --- a/app/code/Magento/Tax/Helper/Data.php +++ b/app/code/Magento/Tax/Helper/Data.php @@ -629,7 +629,7 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper * @param null|string|bool|int|Store $store * @return string */ - public function getCalculationAgorithm($store = null) + public function getCalculationAlgorithm($store = null) { return $this->_config->getAlgorithm($store); } @@ -797,23 +797,6 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper $orderTaxDetails = $this->orderTaxManagement->getOrderTaxDetails($order->getId()); - // Apply any taxes for shipping - $shippingTaxAmount = $salesItem->getShippingTaxAmount(); - $originalShippingTaxAmount = $order->getShippingTaxAmount(); - if ($shippingTaxAmount && $originalShippingTaxAmount && - $shippingTaxAmount != 0 && floatval($originalShippingTaxAmount) - ) { - //An invoice or credit memo can have a different qty than its order - $shippingRatio = $shippingTaxAmount / $originalShippingTaxAmount; - $itemTaxDetails = $orderTaxDetails->getItems(); - foreach ($itemTaxDetails as $itemTaxDetail) { - //Aggregate taxable items associated with shipping - if ($itemTaxDetail->getType() == \Magento\Quote\Model\Quote\Address::TYPE_SHIPPING) { - $taxClassAmount = $this->_aggregateTaxes($taxClassAmount, $itemTaxDetail, $shippingRatio); - } - } - } - // Apply any taxes for the items /** @var $item \Magento\Sales\Model\Order\Invoice\Item|\Magento\Sales\Model\Order\Creditmemo\Item */ foreach ($salesItem->getItems() as $item) { @@ -845,6 +828,23 @@ class Data extends \Magento\Framework\App\Helper\AbstractHelper } } + // Apply any taxes for shipping + $shippingTaxAmount = $salesItem->getShippingTaxAmount(); + $originalShippingTaxAmount = $order->getShippingTaxAmount(); + if ($shippingTaxAmount && $originalShippingTaxAmount && + $shippingTaxAmount != 0 && floatval($originalShippingTaxAmount) + ) { + //An invoice or credit memo can have a different qty than its order + $shippingRatio = $shippingTaxAmount / $originalShippingTaxAmount; + $itemTaxDetails = $orderTaxDetails->getItems(); + foreach ($itemTaxDetails as $itemTaxDetail) { + //Aggregate taxable items associated with shipping + if ($itemTaxDetail->getType() == \Magento\Quote\Model\Quote\Address::TYPE_SHIPPING) { + $taxClassAmount = $this->_aggregateTaxes($taxClassAmount, $itemTaxDetail, $shippingRatio); + } + } + } + return $taxClassAmount; } } diff --git a/app/code/Magento/Tax/Model/Config.php b/app/code/Magento/Tax/Model/Config.php index 6dce2c84bb3dbcda27143c869a643f9268f356cd..a02796b698d1af44814ff0764f6bc33e0b1868bb 100644 --- a/app/code/Magento/Tax/Model/Config.php +++ b/app/code/Magento/Tax/Model/Config.php @@ -270,7 +270,7 @@ class Config } /** - * Get defined tax calculation agorithm + * Get defined tax calculation algorithm * * @param null|string|bool|int|Store $store * @return string diff --git a/app/code/Magento/Tax/Model/Observer.php b/app/code/Magento/Tax/Model/Observer.php index 6780ad5bae60acd2e7d4284e5295bbf706aacfdc..f7143a62112c1c450109dbda1c6737a44993f9c3 100644 --- a/app/code/Magento/Tax/Model/Observer.php +++ b/app/code/Magento/Tax/Model/Observer.php @@ -300,7 +300,7 @@ class Observer return $this; } - $algorithm = $this->_taxData->getCalculationAgorithm(); + $algorithm = $this->_taxData->getCalculationAlgorithm(); $options['calculationAlgorithm'] = $algorithm; // prepare correct template for options render if ($this->_taxData->displayBothPrices()) { diff --git a/app/code/Magento/Theme/Block/Html/Topmenu.php b/app/code/Magento/Theme/Block/Html/Topmenu.php index 0bf0a680ff46b9f11acc3435cf6b486e5bea84a2..5588cbbd6241c96bb854328f5ef1ce76cbcfa7d4 100644 --- a/app/code/Magento/Theme/Block/Html/Topmenu.php +++ b/app/code/Magento/Theme/Block/Html/Topmenu.php @@ -62,6 +62,7 @@ class Topmenu extends Template implements IdentityInterface 'page_block_html_topmenu_gethtml_after', ['menu' => $this->_menu, 'transportObject' => $transportObject] ); + $html = $transportObject->getHtml(); return $html; } diff --git a/composer.json b/composer.json index 675ca726dafc5f9ac4f57b9d8ac122d5b1e03644..64f4d82c9d865f6e72914ece47865acfa5d54131 100644 --- a/composer.json +++ b/composer.json @@ -143,7 +143,6 @@ "magento/language-pt_br": "self.version", "magento/language-zh_cn": "self.version", "magento/framework": "self.version", - "magento/project-setup": "0.1.0", "oyejorge/less.php": "1.7.0", "trentrichardson/jquery-timepicker-addon": "1.4.3", "components/handlebars.js": "1.3.0", diff --git a/composer.lock b/composer.lock index d9dde5fab26f383959bee5f375672ca6dc80df7d..7b97eaf296a318fe02d104c15f032bca9537ba42 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", "This file is @generated automatically" ], - "hash": "26d01745182292ebe1704daed40c6d4a", + "hash": "b2434120b753fdef32c2584eade97c9d", "packages": [ { "name": "composer/composer", @@ -1821,16 +1821,16 @@ }, { "name": "fabpot/php-cs-fixer", - "version": "v1.3", + "version": "v1.4", "source": { "type": "git", "url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git", - "reference": "653cefbf33241185b58f7323157f1829552e370d" + "reference": "72a8c34210c0fbd8caa007fccea87a59f6f0a4d3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/653cefbf33241185b58f7323157f1829552e370d", - "reference": "653cefbf33241185b58f7323157f1829552e370d", + "url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/72a8c34210c0fbd8caa007fccea87a59f6f0a4d3", + "reference": "72a8c34210c0fbd8caa007fccea87a59f6f0a4d3", "shasum": "" }, "require": { @@ -1843,15 +1843,13 @@ "symfony/process": "~2.3", "symfony/stopwatch": "~2.5" }, + "require-dev": { + "satooshi/php-coveralls": "0.7.*@dev" + }, "bin": [ "php-cs-fixer" ], "type": "application", - "extra": { - "branch-alias": { - "dev-master": "1.3-dev" - } - }, "autoload": { "psr-4": { "Symfony\\CS\\": "Symfony/CS/" @@ -1872,20 +1870,20 @@ } ], "description": "A script to automatically fix Symfony Coding Standard", - "time": "2014-12-12 06:09:01" + "time": "2015-01-12 21:28:53" }, { "name": "league/climate", - "version": "2.6.0", + "version": "2.6.1", "source": { "type": "git", "url": "https://github.com/thephpleague/climate.git", - "reference": "776b6c3b32837832a9f6d94f134b55cb7910ece6" + "reference": "28851c909017424f61cc6a62089316313c645d1c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/thephpleague/climate/zipball/776b6c3b32837832a9f6d94f134b55cb7910ece6", - "reference": "776b6c3b32837832a9f6d94f134b55cb7910ece6", + "url": "https://api.github.com/repos/thephpleague/climate/zipball/28851c909017424f61cc6a62089316313c645d1c", + "reference": "28851c909017424f61cc6a62089316313c645d1c", "shasum": "" }, "require": { @@ -1921,7 +1919,7 @@ "php", "terminal" ], - "time": "2015-01-08 02:28:23" + "time": "2015-01-18 14:31:58" }, { "name": "lusitanian/oauth", @@ -2261,16 +2259,16 @@ }, { "name": "phpunit/php-token-stream", - "version": "1.3.0", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-token-stream.git", - "reference": "f8d5d08c56de5cfd592b3340424a81733259a876" + "reference": "db32c18eba00b121c145575fcbcd4d4d24e6db74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/f8d5d08c56de5cfd592b3340424a81733259a876", - "reference": "f8d5d08c56de5cfd592b3340424a81733259a876", + "url": "https://api.github.com/repos/sebastianbergmann/php-token-stream/zipball/db32c18eba00b121c145575fcbcd4d4d24e6db74", + "reference": "db32c18eba00b121c145575fcbcd4d4d24e6db74", "shasum": "" }, "require": { @@ -2283,7 +2281,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.3-dev" + "dev-master": "1.4-dev" } }, "autoload": { @@ -2306,7 +2304,7 @@ "keywords": [ "tokenizer" ], - "time": "2014-08-31 06:12:13" + "time": "2015-01-17 09:51:32" }, { "name": "phpunit/phpunit", diff --git a/dev/tests/functional/.gitignore b/dev/tests/functional/.gitignore index d3b32c5f1d405f9a8bb0a4b6ba742409c6f6050b..a415b0cffbf047e222eb3fa16734eeb8c1382409 100755 --- a/dev/tests/functional/.gitignore +++ b/dev/tests/functional/.gitignore @@ -8,4 +8,4 @@ !/config/isolation.yml.dist !/config/server.yml.dist phpunit.xml -/lib/Mtf/Util/Generate/testcase.xml +/lib/Magento/Mtf/Util/Generate/testcase.xml diff --git a/dev/tests/functional/composer.json b/dev/tests/functional/composer.json index 8d1cee6c7cd6d7b434978d21c193e86872d8b04f..0cd1467c6a9172fd9cfd7fd36d7d48557c9256a2 100644 --- a/dev/tests/functional/composer.json +++ b/dev/tests/functional/composer.json @@ -1,15 +1,17 @@ { "require": { - "magento/mtf": "1.0.0-rc12", + "magento/mtf": "1.0.0-rc14", "php": ">=5.4.0", "phpunit/phpunit": "4.1.0", "phpunit/phpunit-selenium": ">=1.2", "netwing/selenium-server-standalone": ">=2.35" }, + "suggest": { + "facebook/webdriver": "dev-master" + }, "autoload": { "psr-4": { - "Mtf\\": ["lib/Mtf/", "generated/Mtf/", "testsuites/Mtf/"], - "Magento\\": ["generated/Magento/", "tests/app/Magento/"], + "Magento\\": ["lib/Magento/", "testsuites/Magento", "generated/Magento/", "tests/app/Magento/"], "Test\\": "generated/Test/" } } diff --git a/dev/tests/functional/composer.json.dist b/dev/tests/functional/composer.json.dist index 2ea37c5b4a7aad5482f3df3812de7030e6684306..81d984634e945462ad6b3f79fe23d305d9b14bad 100644 --- a/dev/tests/functional/composer.json.dist +++ b/dev/tests/functional/composer.json.dist @@ -6,10 +6,12 @@ "phpunit/phpunit-selenium": ">=1.2", "netwing/selenium-server-standalone": ">=2.35" }, + "suggest": { + "facebook/webdriver": "dev-master" + }, "autoload": { "psr-4": { - "Mtf\\": ["lib/Mtf/", "generated/Mtf/", "testsuites/Mtf/"], - "Magento\\": ["generated/Magento/", "tests/app/Magento/"], + "Magento\\": ["lib/Magento/", "testsuites/Magento", "generated/Magento/", "tests/app/Magento/"], "Test\\": "generated/Test/" } } diff --git a/dev/tests/functional/etc/global/di.xml b/dev/tests/functional/etc/global/di.xml index e4cd6218292aead4caf9cdea7fac747ca44956d2..034b05ab359dbc1b48e241a95db5096de1e2678f 100644 --- a/dev/tests/functional/etc/global/di.xml +++ b/dev/tests/functional/etc/global/di.xml @@ -6,6 +6,6 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../lib/internal/Magento/Framework/ObjectManager/etc/config.xsd"> - <preference for="Mtf\Util\Generate\Fixture\FieldsProviderInterface" type="Mtf\Util\Generate\Fixture\FieldsProvider" /> - <preference for="Mtf\Util\Generate\Repository\CollectionProviderInterface" type="Mtf\Util\Generate\Repository\CollectionProvider" /> + <preference for="Magento\Mtf\Util\Generate\Fixture\FieldsProviderInterface" type="Magento\Mtf\Util\Generate\Fixture\FieldsProvider" /> + <preference for="Magento\Mtf\Util\Generate\Repository\CollectionProviderInterface" type="Magento\Mtf\Util\Generate\Repository\CollectionProvider" /> </config> diff --git a/dev/tests/functional/lib/Mtf/App/State/AbstractState.php b/dev/tests/functional/lib/Magento/Mtf/App/State/AbstractState.php similarity index 93% rename from dev/tests/functional/lib/Mtf/App/State/AbstractState.php rename to dev/tests/functional/lib/Magento/Mtf/App/State/AbstractState.php index f1c47546ed044ca9c870b7e52c75afa7fb11550c..ef8d88494f1aebb463c210ce18e7c00959ab4dbc 100644 --- a/dev/tests/functional/lib/Mtf/App/State/AbstractState.php +++ b/dev/tests/functional/lib/Magento/Mtf/App/State/AbstractState.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\App\State; +namespace Magento\Mtf\App\State; use Magento\Framework\App\DeploymentConfig\DbConfig; use Magento\Framework\App\Filesystem\DirectoryList; @@ -39,7 +39,8 @@ abstract class AbstractState implements StateInterface */ public function clearInstance() { - $dirList = \Mtf\ObjectManagerFactory::getObjectManager()->get('Magento\Framework\Filesystem\DirectoryList'); + $dirList = \Magento\Mtf\ObjectManagerFactory::getObjectManager() + ->get('Magento\Framework\Filesystem\DirectoryList'); $deploymentConfig = new \Magento\Framework\App\DeploymentConfig( new \Magento\Framework\App\DeploymentConfig\Reader($dirList), [] diff --git a/dev/tests/functional/lib/Mtf/App/State/State1.php b/dev/tests/functional/lib/Magento/Mtf/App/State/State1.php similarity index 93% rename from dev/tests/functional/lib/Mtf/App/State/State1.php rename to dev/tests/functional/lib/Magento/Mtf/App/State/State1.php index 59d8ecced3bc7a25cf283b279d9a128b7652e6c5..a5422ee0884ce75233a85e3a1d7132a09f56f659 100644 --- a/dev/tests/functional/lib/Mtf/App/State/State1.php +++ b/dev/tests/functional/lib/Magento/Mtf/App/State/State1.php @@ -4,10 +4,10 @@ * See COPYING.txt for license details. */ -namespace Mtf\App\State; +namespace Magento\Mtf\App\State; -use Mtf\ObjectManager; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Fixture\FixtureFactory; use Magento\Core\Test\Fixture\ConfigData; /** diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/ConditionsElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/ConditionsElement.php similarity index 86% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/ConditionsElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/ConditionsElement.php index 6f755fd6d159c48c73a072a0a6f8dc40743a0b7a..ea8d59e184ec1bf120c411d0665803e4d132652a 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/ConditionsElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/ConditionsElement.php @@ -4,12 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element as AbstractElement; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\ObjectManager; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\ElementInterface; /** * Class ConditionsElement @@ -37,7 +36,7 @@ use Mtf\ObjectManager; * * @SuppressWarnings(PHPMD.TooManyFields) */ -class ConditionsElement extends AbstractElement +class ConditionsElement extends SimpleElement { /** * Main condition @@ -86,7 +85,7 @@ class ConditionsElement extends AbstractElement * * @var string */ - protected $created = './/preceding-sibling::li[1]'; + protected $created = './ul/li[span[contains(@class,"rule-param-new-child")]]/preceding-sibling::li[1]'; /** * Children condition @@ -100,7 +99,7 @@ class ConditionsElement extends AbstractElement * * @var string */ - protected $param = './span[@class="rule-param"]/span/*[substring(@id,(string-length(@id)-%d+1))="%s"]/../..'; + protected $param = './span[span[*[substring(@id,(string-length(@id)-%d+1))="%s"]]]'; /** * Key of last find param @@ -187,19 +186,19 @@ class ConditionsElement extends AbstractElement * Add condition combination * * @param string $condition - * @param Element $context - * @return Element + * @param ElementInterface $context + * @return ElementInterface */ - protected function addConditionsCombination($condition, Element $context) + protected function addConditionsCombination($condition, ElementInterface $context) { $condition = $this->parseCondition($condition); $newCondition = $context->find($this->newCondition, Locator::SELECTOR_XPATH); $newCondition->find($this->addNew, Locator::SELECTOR_XPATH)->click(); $typeNewCondition = $newCondition->find($this->typeNew, Locator::SELECTOR_XPATH, 'select'); $typeNewCondition->setValue($condition['type']); - $this->ruleParamWait(); - $createdCondition = $newCondition->find($this->created, Locator::SELECTOR_XPATH); + $createdCondition = $context->find($this->created, Locator::SELECTOR_XPATH); + $this->waitForCondition($createdCondition); if (!empty($condition['rules'])) { $this->fillCondition($condition['rules'], $createdCondition); } @@ -210,10 +209,10 @@ class ConditionsElement extends AbstractElement * Add conditions * * @param array $conditions - * @param Element $context + * @param ElementInterface $context * @return void */ - protected function addMultipleCondition(array $conditions, Element $context) + protected function addMultipleCondition(array $conditions, ElementInterface $context) { foreach ($conditions as $key => $condition) { $elementContext = is_numeric($key) ? $context : $this->addConditionsCombination($key, $context); @@ -229,10 +228,10 @@ class ConditionsElement extends AbstractElement * Add single Condition * * @param string $condition - * @param Element $context + * @param ElementInterface $context * @return void */ - protected function addSingleCondition($condition, Element $context) + protected function addSingleCondition($condition, ElementInterface $context) { $condition = $this->parseCondition($condition); @@ -246,9 +245,8 @@ class ConditionsElement extends AbstractElement } ); $newCondition->find($this->typeNew, Locator::SELECTOR_XPATH, 'select')->setValue($condition['type']); - $this->ruleParamWait(); - - $createdCondition = $newCondition->find($this->created, Locator::SELECTOR_XPATH); + $createdCondition = $context->find($this->created, Locator::SELECTOR_XPATH); + $this->waitForCondition($createdCondition); $this->fillCondition($condition['rules'], $createdCondition); } @@ -256,14 +254,15 @@ class ConditionsElement extends AbstractElement * Fill single condition * * @param array $rules - * @param Element $element + * @param ElementInterface $element * @return void * @throws \Exception */ - protected function fillCondition(array $rules, Element $element) + protected function fillCondition(array $rules, ElementInterface $element) { $this->resetKeyParam(); foreach ($rules as $rule) { + /** @var ElementInterface $param */ $param = $this->findNextParam($element); $param->find('a')->click(); @@ -287,13 +286,13 @@ class ConditionsElement extends AbstractElement return $element->isVisible() ? true : null; } ); - $value = $param->find('select', Locator::SELECTOR_CSS, 'select'); + $value = $param->find('select', Locator::SELECTOR_TAG_NAME, 'select'); if ($value->isVisible()) { $value->setValue($rule); $this->click(); continue; } - $value = $param->find('input'); + $value = $param->find('input', Locator::SELECTOR_TAG_NAME); if ($value->isVisible()) { $value->setValue($rule); @@ -356,11 +355,11 @@ class ConditionsElement extends AbstractElement /** * Find next param of condition for fill * - * @param Element $context - * @return Element + * @param ElementInterface $context + * @return ElementInterface * @throws \Exception */ - protected function findNextParam(Element $context) + protected function findNextParam(ElementInterface $context) { do { if (!isset($this->mapParams[$this->findKeyParam])) { @@ -389,14 +388,11 @@ class ConditionsElement extends AbstractElement * * @return void */ - protected function ruleParamWait() + protected function waitForCondition(ElementInterface $element) { - $browser = $this; - $ruleParamWait = $this->ruleParamWait; - $browser->waitUntil( - function () use ($browser, $ruleParamWait) { - $element = $browser->find($ruleParamWait, Locator::SELECTOR_XPATH); - return $element->isVisible() ? null : true; + $this->waitUntil( + function () use ($element) { + return $element->getAttribute('class') == 'rule-param-wait' ? null : true; } ); } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/DatepickerElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/DatepickerElement.php similarity index 94% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/DatepickerElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/DatepickerElement.php index 97c094b5b4cfba8f230402b33ec45c9495d348f1..06e569057153cfa433bf399daf28b93ecec41f9f 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/DatepickerElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/DatepickerElement.php @@ -4,15 +4,14 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * General class for datepicker elements. */ -class DatepickerElement extends Element +class DatepickerElement extends SimpleElement { /** * DatePicker button. diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/GlobalsearchElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/GlobalsearchElement.php similarity index 82% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/GlobalsearchElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/GlobalsearchElement.php index 5c934406a4d52d7d7272c0466eb35b05c15432fa..9d074a65d2c4a9b92458149c1854af30b7957bb4 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/GlobalsearchElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/GlobalsearchElement.php @@ -4,16 +4,21 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Client\Driver\Selenium\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\ElementInterface; /** * Typified element class for global search element. */ -class GlobalsearchElement extends Element +class GlobalsearchElement extends SimpleElement { + /** + * "Backspace" key code. + */ + const BACKSPACE = "\xEE\x80\x83"; + /** * Search icon selector. * @@ -49,11 +54,6 @@ class GlobalsearchElement extends Element */ protected $resultItem = 'li'; - /** - * "Backspace" key code. - */ - const BACKSPACE = "\xEE\x80\x83"; - /** * Set value. * @@ -62,7 +62,7 @@ class GlobalsearchElement extends Element */ public function setValue($value) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); $this->waitInitElement(); @@ -71,7 +71,7 @@ class GlobalsearchElement extends Element } $this->selectWindow(); $this->clear(); - $this->find($this->searchInput)->_getWrappedElement()->value($value); + $this->find($this->searchInput)->setValue($value); $this->selectWindow(); $this->waitResult(); @@ -86,7 +86,7 @@ class GlobalsearchElement extends Element { $element = $this->find($this->searchInput); while ('' != $element->getValue()) { - $element->keys([self::BACKSPACE]); + $element->setValue([self::BACKSPACE]); } } @@ -97,8 +97,7 @@ class GlobalsearchElement extends Element */ protected function selectWindow() { - $windowHandles = $this->_driver->windowHandles(); - $this->_driver->window(end($windowHandles)); + $this->driver->closeWindow(); } /** @@ -109,10 +108,10 @@ class GlobalsearchElement extends Element */ protected function waitInitElement() { - $browser = clone $this; $selector = $this->initializedSuggest; - $browser->waitUntil( + $browser = $this->driver; + $this->driver->waitUntil( function () use ($browser, $selector) { return $browser->find($selector, Locator::SELECTOR_XPATH)->isVisible() ? true : null; } @@ -126,10 +125,10 @@ class GlobalsearchElement extends Element */ public function waitResult() { - $browser = clone $this; $selector = $this->searchResult; + $browser = $this->driver; - $browser->waitUntil( + $this->driver->waitUntil( function () use ($browser, $selector) { if ($browser->find($selector)->isVisible()) { return true; @@ -174,12 +173,12 @@ class GlobalsearchElement extends Element */ protected function getSearchResults() { - /** @var Element $searchResult */ + /** @var ElementInterface $searchResult */ $searchResult = $this->find($this->searchResult); - $resultItems = $searchResult->find($this->resultItem)->getElements(); + $resultItems = $searchResult->getElements($this->resultItem); $resultArray = []; - /** @var Element $resultItem */ + /** @var ElementInterface $resultItem */ foreach ($resultItems as $resultItem) { $resultItemLink = $resultItem->find('a'); $resultText = $resultItemLink->isVisible() diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/JquerytreeElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/JquerytreeElement.php similarity index 95% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/JquerytreeElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/JquerytreeElement.php index f94db8b433ba4351f54d59a8bab33f92d7a982d6..e08b8a6adff03f71182cb7366445c3509970713e 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/JquerytreeElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/JquerytreeElement.php @@ -4,15 +4,13 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Element; +use Magento\Mtf\Client\ElementInterface; /** * Class JquerytreeElement * Typified element class for JqueryTree elements - * - * @package Mtf\Client\Element */ class JquerytreeElement extends Tree { @@ -64,11 +62,11 @@ class JquerytreeElement extends Tree /** * Recursive walks tree * - * @param Element $node + * @param ElementInterface $node * @param string $parentCssClass * @return array */ - protected function _getNodeContent($node, $parentCssClass) + protected function _getNodeContent(ElementInterface $node, $parentCssClass) { $counter = 1; $nextNodeSelector = $parentCssClass . " > " . $this->nodeSelector . ":nth-of-type($counter)"; diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/LiselectstoreElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/LiselectstoreElement.php similarity index 80% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/LiselectstoreElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/LiselectstoreElement.php index 1a513bc921fd12ad18afa1dc43284184629953c9..ee459e0ef5db890fa20c42666685e69d18a727ad 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/LiselectstoreElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/LiselectstoreElement.php @@ -4,16 +4,15 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class LiselectstoreElement * Typified element class for lists selectors */ -class LiselectstoreElement extends Element +class LiselectstoreElement extends SimpleElement { /** * Template for each element of option @@ -65,8 +64,8 @@ class LiselectstoreElement extends Element */ public function setValue($value) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); - $this->_context->find($this->toggleSelector)->click(); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->driver->find($this->toggleSelector)->click(); $value = explode('/', $value); $optionSelector = []; @@ -75,7 +74,7 @@ class LiselectstoreElement extends Element } $optionSelector = './/' . implode($this->optionMaskFollowing, $optionSelector) . '/a'; - $option = $this->_context->find($optionSelector, Locator::SELECTOR_XPATH); + $option = $this->driver->find($optionSelector, Locator::SELECTOR_XPATH); if (!$option->isVisible()) { throw new \Exception('[' . implode('/', $value) . '] option is not visible in store switcher.'); } @@ -89,13 +88,11 @@ class LiselectstoreElement extends Element */ protected function getLiElements() { - $this->_context->find($this->toggleSelector)->click(); - $criteria = new \PHPUnit_Extensions_Selenium2TestCase_ElementCriteria('css selector'); - $criteria->value('li'); - $elements = $this->_getWrappedElement()->elements($criteria); + $this->driver->find($this->toggleSelector)->click(); + $elements = $this->driver->getElements($this, 'li', Locator::SELECTOR_TAG_NAME); $dropdownData = []; foreach ($elements as $element) { - $class = $element->attribute('class'); + $class = $element->getAttribute('class'); $dropdownData[] = [ 'element' => $element, 'storeView' => $this->isSubstring($class, "store-switcher-store-view"), @@ -121,7 +118,7 @@ class LiselectstoreElement extends Element if ($dropdownElement['storeView']) { $data[] = $this->findNearestElement('website', $key, $dropdownData) . "/" . $this->findNearestElement('store', $key, $dropdownData) . "/" - . $dropdownElement['element']->text(); + . $dropdownElement['element']->getText(); } } return $data; @@ -151,7 +148,7 @@ class LiselectstoreElement extends Element { $elementText = false; while ($elementText == false) { - $elementText = $elements[$key][$criteria] == true ? $elements[$key]['element']->text() : false; + $elementText = $elements[$key][$criteria] == true ? $elements[$key]['element']->getText() : false; $key--; } return $elementText; @@ -165,18 +162,20 @@ class LiselectstoreElement extends Element */ public function getValue() { - $this->_eventManager->dispatchEvent(['get_value'], [(string)$this->_locator]); + $this->eventManager->dispatchEvent(['get_value'], [$this->getAbsoluteSelector()]); $elements = $this->getLiElements(); foreach ($elements as $key => $element) { if ($element['current'] == true) { if ($element['default_config'] == true) { - return $element['element']->text(); + return $element['element']->getText(); } $path = $this->findNearestElement('website', $key, $elements) . "/" . $this->findNearestElement('store', $key, $elements) . "/" - . $element['element']->text(); + . $element['element']->getText(); return $path; } } + + return ''; } } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectgrouplistElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectgrouplistElement.php similarity index 90% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectgrouplistElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectgrouplistElement.php index f54b1570870bba2da3a1c692beb61d1b44acb17a..88f9924f7ebf905594b2ca20994c0eaab1996443 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectgrouplistElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectgrouplistElement.php @@ -4,10 +4,10 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\ElementInterface; /** * Class MultiselectgrouplistElement @@ -105,7 +105,7 @@ class MultiselectgrouplistElement extends MultiselectElement */ public function setValue($values) { - $this->clearSelectedOptions(); + $this->deselectAll(); $values = is_array($values) ? $values : [$values]; foreach ($values as $value) { $this->selectOption($value); @@ -152,16 +152,17 @@ class MultiselectgrouplistElement extends MultiselectElement * Get optgroup * * @param string $value - * @param Element $context - * @return Element + * @param ElementInterface $context + * @return ElementInterface * @throws \Exception */ - protected function getOptgroup($value, Element $context) + protected function getOptgroup($value, ElementInterface $context) { $optgroup = $context->find(sprintf($this->optgroupByLabel, $value), Locator::SELECTOR_XPATH); if (!$optgroup->isVisible()) { throw new \Exception("Can't find group \"{$value}\"."); } + return $optgroup; } @@ -169,11 +170,11 @@ class MultiselectgrouplistElement extends MultiselectElement * Get child optgroup * * @param string $value - * @param Element $context - * @return Element + * @param ElementInterface $context + * @return ElementInterface * @throws \Exception */ - protected function getChildOptgroup($value, Element $context) + protected function getChildOptgroup($value, ElementInterface $context) { $childOptgroup = null; $count = 1; @@ -210,7 +211,7 @@ class MultiselectgrouplistElement extends MultiselectElement foreach ($this->getSelectedOptions() as $option) { $value = []; - /** @var Element $option */ + /** @var ElementInterface $option */ $optionText = $option->getText(); $optionValue = trim($optionText, $this->trim); $value[] = $optionValue; @@ -220,8 +221,8 @@ class MultiselectgrouplistElement extends MultiselectElement } $pathOptgroup = sprintf($this->parentOptgroup, $this->indent . $optionValue); - $optgroup = $this->_getWrappedElement()->byXPath($pathOptgroup); - $optgroupText = $optgroup->attribute('label'); + $optgroup = $this->find($pathOptgroup, Locator::SELECTOR_XPATH); + $optgroupText = $optgroup->getAttribute('label'); $optgroupValue = trim($optgroupText, $this->trim); $amountIndent = strlen($optgroupText) - strlen($optgroupValue); $amountIndent = $amountIndent ? ($amountIndent / strlen($this->indent)) : 0; @@ -235,8 +236,8 @@ class MultiselectgrouplistElement extends MultiselectElement $indent = $amountIndent ? str_repeat($this->indent, $amountIndent) : ''; $pathOptgroup .= sprintf($this->precedingOptgroup, $amountIndent * self::INDENT_LENGTH, $indent); while (0 <= $amountIndent && $this->find($pathOptgroup, Locator::SELECTOR_XPATH)->isVisible()) { - $optgroup = $this->_getWrappedElement()->byXPath($pathOptgroup); - $optgroupText = $optgroup->attribute('label'); + $optgroup = $this->find($pathOptgroup, Locator::SELECTOR_XPATH); + $optgroupText = $optgroup->getAttribute('label'); $optgroupValue = trim($optgroupText, $this->trim); $value[] = $optgroupValue; @@ -254,7 +255,7 @@ class MultiselectgrouplistElement extends MultiselectElement /** * Get options * - * @return array + * @return ElementInterface[] */ protected function getOptions() { @@ -288,6 +289,7 @@ class MultiselectgrouplistElement extends MultiselectElement ++$countOptgroup; $optgroup = $this->find(sprintf($this->optgroupByNumber, $countOptgroup), Locator::SELECTOR_XPATH); } + return $options; } @@ -300,11 +302,11 @@ class MultiselectgrouplistElement extends MultiselectElement { $options = []; foreach ($this->getOptions() as $option) { - /** Element $option */ if ($option->isSelected()) { $options[] = $option; } } + return $options; } } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectlistElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectlistElement.php similarity index 75% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectlistElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectlistElement.php index df89e94d040387c4246671d87fb5e271081ded40..d5d4539e1b4e0c022f7d89d495118da02b31cf42 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultiselectlistElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultiselectlistElement.php @@ -4,10 +4,9 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Typified element class for Multiple Select List elements @@ -28,21 +27,6 @@ class MultiselectlistElement extends MultiselectElement */ protected $optionCheckedElement = './/*[contains(@class, "mselect-checked")]/following-sibling::span'; - /** - * Return Wrapped Element. - * If element was not created before: - * 1. Context is defined. If context was not passed to constructor - test case (all page) is taken as context - * 2. Attempt to get selenium element is performed in loop - * that is terminated if element is found or after timeout set in configuration - * - * @param bool $waitForElementPresent - * @return \PHPUnit_Extensions_Selenium2TestCase_Element|\PHPUnit_Extensions_Selenium2TestCase_Element_Select - */ - protected function _getWrappedElement($waitForElementPresent = true) - { - return Element::_getWrappedElement($waitForElementPresent); - } - /** * Select options by values in multiple select list * @@ -55,7 +39,7 @@ class MultiselectlistElement extends MultiselectElement $values = is_array($values) ? $values : [$values]; foreach ($options as $option) { - /** @var Element $option */ + /** @var \Magento\Mtf\Client\ElementInterface $option */ $optionText = $option->getText(); $isChecked = $option->find($this->optionCheckedElement, Locator::SELECTOR_XPATH)->isVisible(); $inArray = in_array($optionText, $values); @@ -76,7 +60,7 @@ class MultiselectlistElement extends MultiselectElement $options = $this->getOptions(); foreach ($options as $option) { - /** @var Element $option */ + /** @var \Magento\Mtf\Client\ElementInterface $option */ $checkedOption = $option->find($this->optionCheckedElement, Locator::SELECTOR_XPATH); if ($checkedOption->isVisible()) { $checkedOptions[] = $checkedOption->getText(); @@ -117,7 +101,7 @@ class MultiselectlistElement extends MultiselectElement $options = $this->getOptions(); foreach ($options as $option) { - /** @var Element $option */ + /** @var \Magento\Mtf\Client\ElementInterface $option */ $optionsValue[] = $option->getText(); } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultisuggestElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultisuggestElement.php similarity index 65% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultisuggestElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/MultisuggestElement.php index d9a752f89798af8f76c9e24fb23e77c3f7ec9262..a2644d92930c429ef3aa16241e86a8f64fd0a7a8 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/MultisuggestElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/MultisuggestElement.php @@ -4,10 +4,9 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Typified element class for multi suggest element. @@ -15,74 +14,73 @@ use Mtf\Client\Element\Locator; class MultisuggestElement extends SuggestElement { /** - * Selector list choice. + * Selector list choice * * @var string */ protected $listChoice = './/ul[contains(@class,"mage-suggest-choices")]'; /** - * Selector choice item. + * Selector choice item * * @var string */ protected $choice = './/li/div[text()="%s"]/..'; /** - * Selector choice value. + * Selector choice value * * @var string */ protected $choiceValue = './/li[contains(@class,"mage-suggest-choice")]/div'; /** - * Selector remove choice item. + * Selector remove choice item * * @var string */ protected $choiceClose = '.mage-suggest-choice-close'; /** - * Set value. + * Set value * * @param array|string $values * @return void */ public function setValue($values) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); $this->clear(); foreach ((array)$values as $value) { if (!$this->isChoice($value)) { - $this->selectWindow(); parent::setValue($value); } } } /** - * Get value. + * Get value * * @return array */ public function getValue() { - $this->_eventManager->dispatchEvent(['get_value'], [(string) $this->_locator]); + $this->eventManager->dispatchEvent(['get_value'], [(string) $this->getAbsoluteSelector()]); $listChoice = $this->find($this->listChoice, Locator::SELECTOR_XPATH); - $choices = $listChoice->find($this->choiceValue, Locator::SELECTOR_XPATH)->getElements(); + $choices = $listChoice->getElements($this->choiceValue, Locator::SELECTOR_XPATH); $values = []; foreach ($choices as $choice) { - /** @var Element $choice */ + /** @var \Magento\Mtf\Client\ElementInterface $choice */ $values[] = $choice->getText(); } return $values; } /** - * Check exist selected item. + * Check exist selected item * * @param string $value * @return bool @@ -93,7 +91,7 @@ class MultisuggestElement extends SuggestElement } /** - * Clear element. + * Clear element * * @return void */ @@ -105,15 +103,4 @@ class MultisuggestElement extends SuggestElement $choiceClose = $this->find($this->choiceClose); } } - - /** - * Select to last window. - * - * @return void - */ - protected function selectWindow() - { - $windowHandles = $this->_driver->windowHandles(); - $this->_driver->window(end($windowHandles)); - } } diff --git a/dev/tests/functional/lib/Magento/Mtf/Client/Element/OptgroupselectElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/OptgroupselectElement.php new file mode 100644 index 0000000000000000000000000000000000000000..a8398f49316853599b3fd68b8a011f0b0e26efe7 --- /dev/null +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/OptgroupselectElement.php @@ -0,0 +1,51 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Mtf\Client\Element; + +use Magento\Mtf\Client\Locator; + +/** + * Class OptgroupselectElement + * Typified element class for option group selectors + */ +class OptgroupselectElement extends SelectElement +{ + /** + * Option group selector + * + * @var string + */ + protected $optGroup = 'optgroup[option[contains(.,"%s")]]'; + + /** + * Get the value of form element + * + * @return string + */ + public function getValue() + { + $this->eventManager->dispatchEvent(['get_value'], [(string)$this->getAbsoluteSelector()]); + $selectedLabel = trim(parent::getValue()); + $element = $this->find(sprintf($this->optGroup, $selectedLabel), Locator::SELECTOR_XPATH); + $value = trim($element->getAttribute('label'), chr(0xC2) . chr(0xA0)); + $value .= '/' . $selectedLabel; + return $value; + } + + /** + * Select value in dropdown which has option groups + * + * @param string $value + * @return void + */ + public function setValue($value) + { + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + list($group, $option) = explode('/', $value); + parent::setOptionGroupValue($group, $option); + } +} diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SelectstoreElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/SelectstoreElement.php similarity index 71% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SelectstoreElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/SelectstoreElement.php index 91555c65121da5e605dba95696f45503941bc6e0..32d1b11119a75fb1252240d97a4c0d98056f739f 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SelectstoreElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/SelectstoreElement.php @@ -4,10 +4,9 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Typified element class for option group selectors. @@ -35,14 +34,11 @@ class SelectstoreElement extends SelectElement */ public function getValue() { - $selectedLabel = trim($this->_getWrappedElement()->selectedLabel()); - $value = trim( - $this->_getWrappedElement()->byXPath(sprintf($this->website, $selectedLabel))->attribute('label') - ); - $value .= '/' . trim( - $this->_getWrappedElement()->byXPath(sprintf($this->storeGroup, $selectedLabel))->attribute('label'), - chr(0xC2) . chr(0xA0) - ); + $selectedLabel = trim(parent::getValue()); + $element = $this->find(sprintf($this->website, $selectedLabel), Locator::SELECTOR_XPATH); + $value = trim($element->getAttribute('label')); + $element = $this->find(sprintf($this->storeGroup, $selectedLabel), Locator::SELECTOR_XPATH); + $value .= '/' . trim($element->getAttribute('label'), chr(0xC2) . chr(0xA0)); $value .= '/' . $selectedLabel; return $value; } @@ -67,7 +63,7 @@ class SelectstoreElement extends SelectElement . $pieces[2] . '")]'; } - $option = $this->_context->find($optionLocator, Locator::SELECTOR_XPATH); + $option = $this->context->find($optionLocator, Locator::SELECTOR_XPATH); if (!$option->isVisible()) { throw new \Exception('[' . implode('/', $pieces) . '] option is not visible in store switcher.'); } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SuggestElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/SuggestElement.php old mode 100755 new mode 100644 similarity index 84% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SuggestElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/SuggestElement.php index 5eff1d3acb6affaefa72c864414d3dfe3949cf42..a44151e5a9829d8f32829b611e60188c0facbf2c --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/SuggestElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/SuggestElement.php @@ -4,16 +4,15 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class SuggestElement * General class for suggest elements. */ -class SuggestElement extends Element +class SuggestElement extends SimpleElement { /** * "Backspace" key code. @@ -56,12 +55,13 @@ class SuggestElement extends Element */ public function setValue($value) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); $this->clear(); foreach (str_split($value) as $symbol) { - $this->find($this->suggest)->click(); - $this->_driver->keys($symbol); + $input = $this->find($this->suggest); + $input->click(); + $input->keys([$symbol]); $this->waitResult(); $searchedItem = $this->find(sprintf($this->resultItem, $value), Locator::SELECTOR_XPATH); if ($searchedItem->isVisible()) { @@ -91,7 +91,7 @@ class SuggestElement extends Element */ public function waitResult() { - $browser = clone $this; + $browser = $this; $selector = $this->suggestStateLoader; $browser->waitUntil( function () use ($browser, $selector) { @@ -108,7 +108,7 @@ class SuggestElement extends Element */ public function getValue() { - $this->_eventManager->dispatchEvent(['get_value'], [(string)$this->_locator]); + $this->eventManager->dispatchEvent(['get_value'], [__METHOD__, $this->getAbsoluteSelector()]); return $this->find($this->suggest)->getValue(); } @@ -128,6 +128,7 @@ class SuggestElement extends Element if (!$searchResult->isVisible()) { return false; } + return $searchResult->find(sprintf($this->resultItem, $value), Locator::SELECTOR_XPATH)->isVisible(); } } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/Tree.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/Tree.php similarity index 80% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/Tree.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/Tree.php index d017dd2efd165d76f3fced6f056471d3a0832bfc..00c3d41ffe2bca015596392b0b6a30616fc1da9a 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/Tree.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/Tree.php @@ -4,18 +4,15 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element as ElementInterface; +use Magento\Mtf\Client\ElementInterface; /** * Class Tree * General class for tree elements. Holds general implementation of methods, which overrides in child classes. - * - * @package Mtf\Client\Driver\Selenium\Element */ -abstract class Tree extends Element +abstract class Tree extends SimpleElement { /** * Css class for finding tree nodes @@ -44,27 +41,26 @@ abstract class Tree extends Element abstract public function getStructure(); /** - * Drag'n'drop method is not accessible in this class. - * Throws exception if used. + * Drag and drop element to(between) another element(s) * * @param ElementInterface $target - * @throws \BadMethodCallException + * @throws \Exception * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ public function dragAndDrop(ElementInterface $target) { - throw new \BadMethodCallException('Not applicable for this class of elements (TreeElement)'); + throw new \Exception('Not applicable for this class of elements (TreeElement)'); } /** * getValue method is not accessible in this class. * Throws exception if used. * - * @throws \BadMethodCallException + * @throws \Exception */ public function getValue() { - throw new \BadMethodCallException('Not applicable for this class of elements (TreeElement)'); + throw new \Exception('Not applicable for this class of elements (TreeElement)'); } /** @@ -72,12 +68,12 @@ abstract class Tree extends Element * Throws exception if used. * * @param array $keys - * @throws \BadMethodCallException + * @throws \Exception * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ public function keys(array $keys) { - throw new \BadMethodCallException('Not applicable for this class of elements (TreeElement)'); + throw new \Exception('Not applicable for this class of elements (TreeElement)'); } /** @@ -99,6 +95,7 @@ abstract class Tree extends Element ++$pathChunkCounter; } if ($structureChunk) { + /** @var ElementInterface $needleElement */ $needleElement = $structureChunk->find($this->nodeName); $needleElement->click(); } else { @@ -112,7 +109,7 @@ abstract class Tree extends Element * * @param string $pathChunk * @param array $structureChunk - * @return array|Element||false + * @return array|ElementInterface|false */ protected function deep($pathChunk, $structureChunk) { @@ -124,17 +121,18 @@ abstract class Tree extends Element } } } + return false; } /** * Recursive walks tree * - * @param Element $node + * @param ElementInterface $node * @param string $parentCssClass * @return array */ - protected function _getNodeContent($node, $parentCssClass) + protected function _getNodeContent(ElementInterface $node, $parentCssClass) { $nodeArray = []; $nodeList = []; @@ -148,7 +146,7 @@ abstract class Tree extends Element } //Write to array values of current node foreach ($nodeList as $currentNode) { - /** @var Element $currentNode */ + /** @var ElementInterface $currentNode */ $nodesNames = $currentNode->find($this->nodeName); $nodesContents = $currentNode->find($this->nodeCssClass); $text = ltrim($nodesNames->getText()); @@ -156,9 +154,10 @@ abstract class Tree extends Element 'name' => $text, 'element' => $currentNode, 'subnodes' => $nodesContents->isVisible() ? - $this->_getNodeContent($nodesContents, $this->nodeCssClass) : null, + $this->_getNodeContent($nodesContents, $this->nodeCssClass) : null, ]; } + return $nodeArray; } } diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/TreeElement.php b/dev/tests/functional/lib/Magento/Mtf/Client/Element/TreeElement.php similarity index 94% rename from dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/TreeElement.php rename to dev/tests/functional/lib/Magento/Mtf/Client/Element/TreeElement.php index d373a6de315daeff05eb5e093104a11ed375985a..09995686b04c96c3dd4378b3ec3bb93eb2d23780 100644 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/TreeElement.php +++ b/dev/tests/functional/lib/Magento/Mtf/Client/Element/TreeElement.php @@ -4,12 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf\Client\Driver\Selenium\Element; +namespace Magento\Mtf\Client\Element; /** * Class TreeElement * Typified element class for Tree elements - * */ class TreeElement extends Tree { diff --git a/dev/tests/functional/lib/Mtf/Constraint/AbstractAssertForm.php b/dev/tests/functional/lib/Magento/Mtf/Constraint/AbstractAssertForm.php old mode 100755 new mode 100644 similarity index 99% rename from dev/tests/functional/lib/Mtf/Constraint/AbstractAssertForm.php rename to dev/tests/functional/lib/Magento/Mtf/Constraint/AbstractAssertForm.php index e6b0d60d131644719acaab483e79171625cb2dc2..a26ff55f584f007b927d78636cc12d1f171c7bcb --- a/dev/tests/functional/lib/Mtf/Constraint/AbstractAssertForm.php +++ b/dev/tests/functional/lib/Magento/Mtf/Constraint/AbstractAssertForm.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Constraint; +namespace Magento\Mtf\Constraint; /** * Class AssertForm diff --git a/dev/tests/functional/lib/Mtf/EntryPoint/EntryPoint.php b/dev/tests/functional/lib/Magento/Mtf/EntryPoint/EntryPoint.php similarity index 91% rename from dev/tests/functional/lib/Mtf/EntryPoint/EntryPoint.php rename to dev/tests/functional/lib/Magento/Mtf/EntryPoint/EntryPoint.php index f991ae7b6b159533ac5206e1af9956f5dfb8c207..701897c456230df2b680c45b78491657e6531d27 100644 --- a/dev/tests/functional/lib/Mtf/EntryPoint/EntryPoint.php +++ b/dev/tests/functional/lib/Magento/Mtf/EntryPoint/EntryPoint.php @@ -4,9 +4,9 @@ * See COPYING.txt for license details. */ -namespace Mtf\EntryPoint; +namespace Magento\Mtf\EntryPoint; -use Mtf\ObjectManager; +use Magento\Mtf\ObjectManager; /** * Class EntryPoint @@ -60,7 +60,7 @@ class EntryPoint { try { if (!$this->_locator) { - $locatorFactory = new \Mtf\ObjectManagerFactory(); + $locatorFactory = new \Magento\Mtf\ObjectManagerFactory(); $this->_locator = $locatorFactory->create(); } return $this->_locator->create($applicationName, $arguments)->launch(); diff --git a/dev/tests/functional/lib/Mtf/ObjectManagerFactory.php b/dev/tests/functional/lib/Magento/Mtf/ObjectManagerFactory.php similarity index 56% rename from dev/tests/functional/lib/Mtf/ObjectManagerFactory.php rename to dev/tests/functional/lib/Magento/Mtf/ObjectManagerFactory.php index 62524b92770f5646218198946ea1d465afe929e5..9811a2e9f844b0f99839fca83713f7fd3c5043e8 100644 --- a/dev/tests/functional/lib/Mtf/ObjectManagerFactory.php +++ b/dev/tests/functional/lib/Magento/Mtf/ObjectManagerFactory.php @@ -4,13 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf; +namespace Magento\Mtf; -use Magento\Framework\App\Filesystem\DirectoryList; -use Magento\Framework\ObjectManagerInterface as MagentoObjectManager; -use Magento\Framework\Stdlib\BooleanUtils; -use Mtf\ObjectManager\Factory; -use Mtf\System\Config as SystemConfig; +use Magento\Mtf\ObjectManagerInterface as MagentoObjectManager; +use Magento\Mtf\Stdlib\BooleanUtils; +use Magento\Mtf\ObjectManager\Factory; /** * Class ObjectManagerFactory @@ -25,14 +23,14 @@ class ObjectManagerFactory * * @var string */ - protected $locatorClassName = '\Mtf\ObjectManager'; + protected $locatorClassName = '\Magento\Mtf\ObjectManager'; /** * DI Config class name * * @var string */ - protected $configClassName = '\Mtf\ObjectManager\Config'; + protected $configClassName = '\Magento\Mtf\ObjectManager\Config'; /** * Create Object Manager @@ -46,18 +44,15 @@ class ObjectManagerFactory define('MTF_TESTS_PATH', MTF_BP . '/tests/app/'); } if (!defined('MTF_STATES_PATH')) { - define('MTF_STATES_PATH', MTF_BP . '/lib/Mtf/App/State/'); + define('MTF_STATES_PATH', MTF_BP . '/lib/Magento/Mtf/App/State/'); } $diConfig = new $this->configClassName(); - $systemConfig = new SystemConfig(); - $configuration = $systemConfig->getConfigParam(); - $diConfig->extend($configuration); $factory = new Factory($diConfig); $argInterpreter = $this->createArgumentInterpreter(new BooleanUtils()); - $argumentMapper = new \Magento\Framework\ObjectManager\Config\Mapper\Dom($argInterpreter); + $argumentMapper = new \Magento\Mtf\ObjectManager\Config\Mapper\Dom($argInterpreter); - $sharedInstances['Magento\Framework\ObjectManager\Config\Mapper\Dom'] = $argumentMapper; + $sharedInstances['Magento\Mtf\ObjectManager\Config\Mapper\Dom'] = $argumentMapper; $objectManager = new $this->locatorClassName($factory, $diConfig, $sharedInstances); $factory->setObjectManager($objectManager); @@ -79,38 +74,39 @@ class ObjectManagerFactory \Magento\Framework\App\Filesystem\DirectoryList $directoryList, array $arguments ) { + $data = isset($arguments[\Magento\Framework\App\Arguments\Loader::PARAM_CUSTOM_FILE]) + ? $arguments[\Magento\Framework\App\Arguments\Loader::PARAM_CUSTOM_FILE] + : null; return new \Magento\Framework\App\DeploymentConfig( new \Magento\Framework\App\DeploymentConfig\Reader($directoryList), - isset($arguments[\Magento\Framework\App\Arguments\Loader::PARAM_CUSTOM_FILE]) - ? $arguments[\Magento\Framework\App\Arguments\Loader::PARAM_CUSTOM_FILE] - : null + $data ); } /** * Return newly created instance on an argument interpreter, suitable for processing DI arguments * - * @param \Magento\Framework\Stdlib\BooleanUtils $booleanUtils - * @return \Magento\Framework\Data\Argument\InterpreterInterface + * @param \Magento\Mtf\Stdlib\BooleanUtils $booleanUtils + * @return \Magento\Mtf\Data\Argument\InterpreterInterface */ protected function createArgumentInterpreter( - \Magento\Framework\Stdlib\BooleanUtils $booleanUtils + \Magento\Mtf\Stdlib\BooleanUtils $booleanUtils ) { - $constInterpreter = new \Magento\Framework\Data\Argument\Interpreter\Constant(); - $result = new \Magento\Framework\Data\Argument\Interpreter\Composite( + $constInterpreter = new \Magento\Mtf\Data\Argument\Interpreter\Constant(); + $result = new \Magento\Mtf\Data\Argument\Interpreter\Composite( [ - 'boolean' => new \Magento\Framework\Data\Argument\Interpreter\Boolean($booleanUtils), - 'string' => new \Magento\Framework\Data\Argument\Interpreter\String($booleanUtils), - 'number' => new \Magento\Framework\Data\Argument\Interpreter\Number(), - 'null' => new \Magento\Framework\Data\Argument\Interpreter\NullType(), + 'boolean' => new \Magento\Mtf\Data\Argument\Interpreter\Boolean($booleanUtils), + 'string' => new \Magento\Mtf\Data\Argument\Interpreter\String($booleanUtils), + 'number' => new \Magento\Mtf\Data\Argument\Interpreter\Number(), + 'null' => new \Magento\Mtf\Data\Argument\Interpreter\NullType(), 'const' => $constInterpreter, - 'object' => new \Magento\Framework\Data\Argument\Interpreter\Object($booleanUtils), - 'init_parameter' => new \Magento\Framework\App\Arguments\ArgumentInterpreter($constInterpreter), + 'object' => new \Magento\Mtf\Data\Argument\Interpreter\Object($booleanUtils), + 'init_parameter' => new \Magento\Mtf\Data\Argument\Interpreter\Argument($constInterpreter), ], - \Magento\Framework\ObjectManager\Config\Reader\Dom::TYPE_ATTRIBUTE + \Magento\Mtf\ObjectManager\Config\Reader\Dom::TYPE_ATTRIBUTE ); // Add interpreters that reference the composite - $result->addInterpreter('array', new \Magento\Framework\Data\Argument\Interpreter\ArrayType($result)); + $result->addInterpreter('array', new \Magento\Mtf\Data\Argument\Interpreter\ArrayType($result)); return $result; } @@ -138,19 +134,19 @@ class ObjectManagerFactory public static function configure(MagentoObjectManager $objectManager) { $objectManager->configure( - $objectManager->get('Mtf\ObjectManager\ConfigLoader\Primary')->load() + $objectManager->get('Magento\Mtf\ObjectManager\ConfigLoader\Primary')->load() ); $objectManager->configure( - $objectManager->get('Mtf\ObjectManager\ConfigLoader\Module')->load() + $objectManager->get('Magento\Mtf\ObjectManager\ConfigLoader\Module')->load() ); $objectManager->configure( - $objectManager->get('Mtf\ObjectManager\ConfigLoader\Module')->load('etc/ui') + $objectManager->get('Magento\Mtf\ObjectManager\ConfigLoader\Module')->load('etc/ui') ); $objectManager->configure( - $objectManager->get('Mtf\ObjectManager\ConfigLoader\Module')->load('etc/curl') + $objectManager->get('Magento\Mtf\ObjectManager\ConfigLoader\Module')->load('etc/curl') ); } } diff --git a/dev/tests/functional/lib/Mtf/Page/BackendPage.php b/dev/tests/functional/lib/Magento/Mtf/Page/BackendPage.php similarity index 91% rename from dev/tests/functional/lib/Mtf/Page/BackendPage.php rename to dev/tests/functional/lib/Magento/Mtf/Page/BackendPage.php index 47999dd68527526e15df5a99b241f686a8de8d2b..e5b6c09f905383cb25fd2875245fc6100fd9f87d 100644 --- a/dev/tests/functional/lib/Mtf/Page/BackendPage.php +++ b/dev/tests/functional/lib/Magento/Mtf/Page/BackendPage.php @@ -3,9 +3,9 @@ * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Mtf\Page; +namespace Magento\Mtf\Page; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class BackendPage diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory.php index 5f87958798dadf6b3cc7ebdbb35972e38f869918..6083b509f9a72918d0be626a24997dcc22b8b663 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate; +namespace Magento\Mtf\Util\Generate; use Magento\Framework\App; use Magento\Framework\ObjectManagerInterface; diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/AbstractFactory.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/AbstractFactory.php similarity index 94% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/AbstractFactory.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/AbstractFactory.php index 5239975f965d3dc63d61b8595f90d867b02f54b4..df7b6c873c5397623e97c7067041c0ac0222b347 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/AbstractFactory.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/AbstractFactory.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class AbstractFactory @@ -37,7 +37,7 @@ abstract class AbstractFactory $this->endFactory($this->type); - \Mtf\Util\Generate\GenerateResult::addResult($this->type, $this->cnt); + \Magento\Mtf\Util\Generate\GenerateResult::addResult($this->type, $this->cnt); } abstract protected function generateContent(); @@ -50,15 +50,15 @@ abstract class AbstractFactory protected function startFactory($type) { $this->factoryContent = "<?php\n\n"; - $this->factoryContent .= "namespace Mtf\\{$type}; \n\n"; - $this->factoryContent .= "use Mtf\\Fixture\\FixtureInterface; \n\n"; + $this->factoryContent .= "namespace Magento\Mtf\\{$type}; \n\n"; + $this->factoryContent .= "use Magento\Mtf\\Fixture\\FixtureInterface; \n\n"; $this->factoryContent .= "class {$type}FactoryDeprecated\n"; $this->factoryContent .= "{\n"; $this->factoryContent .= " /** * Object Manager * - * @var \\Mtf\\ObjectManager + * @var \\Magento\Mtf\\ObjectManager */ protected \$objectManager; @@ -68,7 +68,7 @@ abstract class AbstractFactory */ public function __construct() { - \$this->objectManager = \\Mtf\\ObjectManager::getInstance(); + \$this->objectManager = \\Magento\Mtf\\ObjectManager::getInstance(); }\n"; } @@ -85,11 +85,11 @@ abstract class AbstractFactory return $this; } - $this->checkAndCreateFolder(MTF_BP . "/generated/Mtf/{$type}"); + $this->checkAndCreateFolder(MTF_BP . "/generated/Magento/Mtf/{$type}"); $this->factoryContent .= "}\n"; - $file = MTF_BP . "/generated/Mtf/{$type}/{$type}FactoryDeprecated.php"; + $file = MTF_BP . "/generated/Magento/Mtf/{$type}/{$type}FactoryDeprecated.php"; if (false === file_put_contents($file, $this->factoryContent)) { throw new \RuntimeException("Can't write content to {$file} file"); } diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Block.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Block.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/Block.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Block.php index 24bdbf29f8a28b3bf2618cc5d79cfe82f360aca8..b564d6aca69dc246797e28702771ad643b6c90ab 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Block.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Block.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class Block diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Fixture.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Fixture.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/Fixture.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Fixture.php index 1d9425f68e16d5f4c8ac31e4bc9ae170bbc438a7..174a17a271875b41f30c9527f2c459859977f016 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Fixture.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Fixture.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class Fixture diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Handler.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Handler.php similarity index 98% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/Handler.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Handler.php index c8c0b42a3e530c91a704992e4a46011ab65b65db..2dbced547a606e1fe6d77b2c64b35e44cc5bacd7 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Handler.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Handler.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class Handler diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Page.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Page.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/Page.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Page.php index b557cb15d2e8c8b28c4b1cef1880f2bb08a8b611..c1cb6f22762be2cd5da35ed33c425a71fe2e9aab 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Page.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Page.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class Page diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Repository.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Repository.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Generate/Factory/Repository.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Repository.php index ea6f30c9c8a5ba8037898d4f658797ada85e2c2c..79facfdcb13f3c839f394f3ddd6dd1a244de7d04 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Factory/Repository.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Factory/Repository.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Factory; +namespace Magento\Mtf\Util\Generate\Factory; /** * Class Repository diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Fixture/FieldsProvider.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Fixture/FieldsProvider.php similarity index 98% rename from dev/tests/functional/lib/Mtf/Util/Generate/Fixture/FieldsProvider.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Fixture/FieldsProvider.php index b0ae3b9eade06d0a31dd31c4e5925e917c8f3343..fa8923f4ba0158403f86ebe4b5672e623471b259 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Fixture/FieldsProvider.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Fixture/FieldsProvider.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Fixture; +namespace Magento\Mtf\Util\Generate\Fixture; use Magento\Framework\App\Resource; use Magento\Framework\ObjectManagerInterface; diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/CollectionProvider.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/CollectionProvider.php similarity index 95% rename from dev/tests/functional/lib/Mtf/Util/Generate/Repository/CollectionProvider.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/CollectionProvider.php index 5088d06530b63b90faa8fc6937756a88ecb7d339..a02df91cb8a3d07f41f7f214f8a5541b65d9579c 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/CollectionProvider.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/CollectionProvider.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Repository; +namespace Magento\Mtf\Util\Generate\Repository; use Magento\Framework\ObjectManagerInterface; @@ -69,7 +69,7 @@ class CollectionProvider implements CollectionProviderInterface { $collection = $fixture['collection']; $collection = $this->objectManager->create($collection, ['fixture' => $fixture]); - /** @var $collection \Mtf\Util\Generate\Repository\TableCollection */ + /** @var $collection \Magento\Mtf\Util\Generate\Repository\TableCollection */ return $collection->getItems(); } diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/Resource.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/Resource.php similarity index 95% rename from dev/tests/functional/lib/Mtf/Util/Generate/Repository/Resource.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/Resource.php index 3df60fd5bc9abac7c2299a9d0010c8d882035510..f366bbc74009cee589f3ba1043a4846dbd054994 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/Resource.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/Resource.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Repository; +namespace Magento\Mtf\Util\Generate\Repository; /** * Class Resource diff --git a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/TableCollection.php b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/TableCollection.php similarity index 89% rename from dev/tests/functional/lib/Mtf/Util/Generate/Repository/TableCollection.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/TableCollection.php index 35d36c1a0510682b9586cfc4a69f298c9c3a633f..9c4ed81e91f72451e9be3ed67a824181b0f4c1b4 100644 --- a/dev/tests/functional/lib/Mtf/Util/Generate/Repository/TableCollection.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Generate/Repository/TableCollection.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Generate\Repository; +namespace Magento\Mtf\Util\Generate\Repository; use Magento\Framework\Model\Resource\Db\Collection\AbstractCollection; @@ -39,7 +39,7 @@ class TableCollection extends AbstractCollection array $fixture = [] ) { $this->setModel('Magento\Framework\Object'); - $this->setResourceModel('Mtf\Util\Generate\Repository\Resource'); + $this->setResourceModel('Magento\Mtf\Util\Generate\Repository\Resource'); $resource = $this->getResource(); $resource->setFixture($fixture); @@ -50,7 +50,7 @@ class TableCollection extends AbstractCollection /** * Get resource instance * - * @return \Mtf\Util\Generate\Repository\Resource + * @return \Magento\Mtf\Util\Generate\Repository\Resource */ public function getResource() { diff --git a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlInterface.php b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlInterface.php similarity index 96% rename from dev/tests/functional/lib/Mtf/Util/Protocol/CurlInterface.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlInterface.php index f3233d88817ad930fc19cbc068e5776558589e4b..63a53a84e1ca877e2a4d5017a6a8d5890eafc76a 100644 --- a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlInterface.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlInterface.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Protocol; +namespace Magento\Mtf\Util\Protocol; /** * Class CurlInterface diff --git a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport.php b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport.php similarity index 99% rename from dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport.php index 9d1ccb866174851fa358ca68e8cf2379043c5da2..30c20908ed75cba5c20ac4a440f78d9f21c3ed80 100644 --- a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Protocol; +namespace Magento\Mtf\Util\Protocol; /** * HTTP CURL Adapter diff --git a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php similarity index 95% rename from dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php index a255547319ac928ca72cf44b6d349fba161d2aa5..5705d52766dc96dccb6c4e2ecd75dd727365bcb6 100644 --- a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/BackendDecorator.php @@ -4,11 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Protocol\CurlTransport; +namespace Magento\Mtf\Util\Protocol\CurlTransport; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; /** * Class BackendDecorator diff --git a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php similarity index 96% rename from dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php index fbd0aa152d17535a33c47efc188115e4008fda86..97b29483cbac799935092aee03786fc8d92c8e3f 100644 --- a/dev/tests/functional/lib/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/CurlTransport/FrontendDecorator.php @@ -4,11 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Protocol\CurlTransport; +namespace Magento\Mtf\Util\Protocol\CurlTransport; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; /** * Class FrontendDecorator diff --git a/dev/tests/functional/lib/Mtf/Util/Protocol/SoapTransport.php b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/SoapTransport.php similarity index 97% rename from dev/tests/functional/lib/Mtf/Util/Protocol/SoapTransport.php rename to dev/tests/functional/lib/Magento/Mtf/Util/Protocol/SoapTransport.php index 943a45b9801f62ef4d68cb1627200c1d164ce9f6..8ddeb74e4cd4dcad29b7a9ac9ad39e3a8d0a3e46 100644 --- a/dev/tests/functional/lib/Mtf/Util/Protocol/SoapTransport.php +++ b/dev/tests/functional/lib/Magento/Mtf/Util/Protocol/SoapTransport.php @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\Util\Protocol; +namespace Magento\Mtf\Util\Protocol; class SoapTransport { diff --git a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/OptgroupselectElement.php b/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/OptgroupselectElement.php deleted file mode 100644 index 76a9091ad17a936582bdeb38161a700a163c70b7..0000000000000000000000000000000000000000 --- a/dev/tests/functional/lib/Mtf/Client/Driver/Selenium/Element/OptgroupselectElement.php +++ /dev/null @@ -1,56 +0,0 @@ -<?php -/** - * Copyright © 2015 Magento. All rights reserved. - * See COPYING.txt for license details. - */ - -namespace Mtf\Client\Driver\Selenium\Element; - -use Mtf\Client\Driver\Selenium\Element; - -/** - * Class OptgroupselectElement - * Typified element class for option group selectors - */ -class OptgroupselectElement extends SelectElement -{ - /** - * Option group selector - * - * @var string - */ - protected $optGroup = 'optgroup[option[contains(.,"%s")]]'; - - /** - * Get the value of form element - * - * @return string - */ - public function getValue() - { - $this->_eventManager->dispatchEvent(['get_value'], [(string)$this->_locator]); - $selectedLabel = trim($this->_getWrappedElement()->selectedLabel()); - $value = trim( - $this->_getWrappedElement()->byXPath(sprintf($this->optGroup, $selectedLabel))->attribute('label'), - chr(0xC2) . chr(0xA0) - ); - $value .= '/' . $selectedLabel; - return $value; - } - - /** - * Select value in dropdown which has option groups - * - * @param string $value - * @return void - */ - public function setValue($value) - { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); - list($group, $option) = explode('/', $value); - $optionLocator = ".//optgroup[@label='$group']/option[contains(text(), '$option')]"; - $criteria = new \PHPUnit_Extensions_Selenium2TestCase_ElementCriteria('xpath'); - $criteria->value($optionLocator); - $this->_getWrappedElement(true)->selectOptionByCriteria($criteria); - } -} diff --git a/dev/tests/functional/phpunit.xml.dist b/dev/tests/functional/phpunit.xml.dist index 88428963045e80fd73e217dbaf77c9eff48deb3e..1bc47ba8998a80e915e08c384657b5aa9280ab34 100755 --- a/dev/tests/functional/phpunit.xml.dist +++ b/dev/tests/functional/phpunit.xml.dist @@ -19,14 +19,14 @@ </testsuites> <listeners> - <listener class="Mtf\System\Browser\Listener" /> - <listener class="Mtf\System\Isolation\Listener"> + <listener class="Magento\Mtf\System\Browser\Listener" /> + <listener class="Magento\Mtf\System\Isolation\Listener"> <arguments> - <object class="Mtf\System\Isolation\Driver\Base" /> + <object class="Magento\Mtf\System\Isolation\Driver\Base" /> </arguments> </listener> - <listener class="Mtf\System\Event\StateListener" /> - <listener class="Mtf\System\JUnit"/> + <listener class="Magento\Mtf\System\Event\StateListener" /> + <listener class="Magento\Mtf\System\JUnit"/> </listeners> <php> @@ -36,6 +36,7 @@ <env name="server_config_path" value="config/server.yml.dist" /> <env name="isolation_config_path" value="config/isolation.yml.dist" /> <env name="handlers_config_path" value="config/handler.yml.dist" /> + <env name="install_config_path" value="config/install_data.yml.dist" /> <env name="testsuite_rule" value="basic" /> <env name="testsuite_rule_path" value="Mtf/TestSuite/InjectableTests" /> <env name="log_directory" value="var/log" /> diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Admin/Login.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Admin/Login.php index 3ba5eb506099636c07abb9de216797a11a844ad9..54f750ceeec48e8fd45c0ae8682793d0e9d8ad6e 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Admin/Login.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Admin/Login.php @@ -6,8 +6,8 @@ namespace Magento\Backend\Test\Block\Admin; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Login diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Cache.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Cache.php index 6918b92ae9c6738f491555fe221c2415f1083761..c25eac6454d23fcb9ef9b754ce91b03a5a185219 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Cache.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Cache.php @@ -6,9 +6,9 @@ namespace Magento\Backend\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; /** * Class Actions @@ -62,7 +62,7 @@ class Cache extends Block public function flushCacheStorage() { $this->_rootElement->find($this->flushCacheStorageButton)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Denied.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Denied.php index 551202c18d02bad4fc413ab37aac9dc86813bbc6..c74b042f76f692054a37e72643d22bc243a12388 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Denied.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Denied.php @@ -6,8 +6,8 @@ namespace Magento\Backend\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Denied diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/FormPageActions.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/FormPageActions.php index 4d8abcfd1fa582a2621f93caca4d05315b8bc3fe..246c3113a8d176f05a2b226aab70d056f2effe50 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/FormPageActions.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/FormPageActions.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class FormPageActions @@ -110,7 +110,7 @@ class FormPageActions extends PageActions public function delete() { $this->_rootElement->find($this->deleteButton)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** @@ -131,6 +131,7 @@ class FormPageActions extends PageActions */ protected function waitBeforeClick() { + time_nanosleep(0, 600000000); usleep(500000); } } diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Menu.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Menu.php index 4f3aee6105530b2b531064be9b94e631c3d2a97b..23cd977b4c224ee95bb258281367bed61673c8a6 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Menu.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Menu.php @@ -6,7 +6,7 @@ */ namespace Magento\Backend\Test\Block; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Menu diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Header.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Header.php index b9732c73c2adb69c30b44ff3952c206dd1717ab6..94b36cc6a95ea6c8e46707c102c7fa3ac70aa0d5 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Header.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Header.php @@ -6,9 +6,9 @@ namespace Magento\Backend\Test\Block\Page; -use Mtf\Block\Block; -use Mtf\Client\Driver\Selenium\Element\GlobalsearchElement; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\GlobalsearchElement; /** * Header block. diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Main.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Main.php index da9b8ec3376c12b242d4a95d2e3516093d88ac2a..9de2cdc43498326ae52a79eb41ebbf373ec6b4f6 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Main.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Page/Main.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Block\Page; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Main block. diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/PageActions.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/PageActions.php index 1f55b62de5327649731b80eaab6911eaa1ea2ed2..58e1d53e0cead0329d456c6b78f48a4092ee44d7 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/PageActions.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/PageActions.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Block; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class PageActions diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form.php index 99ad6c7620eb68c716b9b515b0624a6ae40291a9..86ae1d8d66a067591d0fae2bed7b35c58f068663 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form.php @@ -7,9 +7,9 @@ */ namespace Magento\Backend\Test\Block\System\Config; -use Mtf\Block\Block; -use Mtf\Factory\Factory; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Client\Locator; class Form extends Block { diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form/Group.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form/Group.php index e168ce41053af7fd19ce5ff9b166801a12ac430b..0d3244802c70260eedce3ed996df9856c77a3057 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form/Group.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/Form/Group.php @@ -8,9 +8,12 @@ namespace Magento\Backend\Test\Block\System\Config\Form; +use Magento\Mtf\Client\Locator; use Magento\Backend\Test\Block\Widget\Form; -use Mtf\Client\Element; +/** + * Class Group + */ class Group extends Form { /** @@ -67,14 +70,14 @@ class Group extends Form $element = $this->_rootElement->find( sprintf($this->element, $field), - Element\Locator::SELECTOR_XPATH, + Locator::SELECTOR_XPATH, $input ); if ($element->isDisabled()) { $checkbox = $this->_rootElement->find( sprintf($this->defaultCheckbox, $field), - Element\Locator::SELECTOR_XPATH, + Locator::SELECTOR_XPATH, 'checkbox' ); $checkbox->setValue('No'); diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/PageActions.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/PageActions.php index d416864fe1542bd886a42a96c3e8d3c29761e1cf..8ed2b6a7bfb7acdadf0b2fd106939052fb7de5d2 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/PageActions.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Config/PageActions.php @@ -10,7 +10,7 @@ namespace Magento\Backend\Test\Block\System\Config; use Magento\Backend\Test\Block\FormPageActions as AbstractPageActions; use Magento\Store\Test\Fixture\Store; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class PageActions @@ -35,7 +35,7 @@ class PageActions extends AbstractPageActions { $this->_rootElement->find($this->scopeSelector, Locator::SELECTOR_CSS, 'liselectstore') ->setValue($websiteScope); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); return $this; } diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Delete/Form.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Delete/Form.php index cde30ce25ebddbf4d0dc6bc90150b256e7097254..ac3cce607228743746f8cec0237d349ed617b143 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Delete/Form.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Delete/Form.php @@ -6,8 +6,8 @@ namespace Magento\Backend\Test\Block\System\Store\Delete; -use Mtf\Block\Form as AbstractForm; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Block\Form as AbstractForm; /** * Class Form @@ -19,10 +19,10 @@ class Form extends AbstractForm * Fill Backup Option in delete * * @param array $data - * @param Element $element + * @param SimpleElement $element * @return void */ - public function fillForm(array $data, Element $element = null) + public function fillForm(array $data, SimpleElement $element = null) { $mapping = $this->dataMapping($data); $this->_fill($mapping, $element); diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/GroupForm.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/GroupForm.php index a703a31bc2b576a79fe2b9c6ccb440b1ec6b1a6b..819e075dbe9ab87b9d92914cb6d2c9122d93a019 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/GroupForm.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/GroupForm.php @@ -6,8 +6,8 @@ namespace Magento\Backend\Test\Block\System\Store\Edit\Form; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class GroupForm diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/StoreForm.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/StoreForm.php index 2c7f54f9f6800badc784ea7d675359d892f60ef6..0d9824e284fb8b7c1326c7dbb0b985521bdd045a 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/StoreForm.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/StoreForm.php @@ -6,8 +6,8 @@ namespace Magento\Backend\Test\Block\System\Store\Edit\Form; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class StoreForm diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/WebsiteForm.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/WebsiteForm.php index 28a29b48688c50e85eadfca07094ec2c42cf3c27..cfbfa524c77c55fdebee79a250f7a30666e33688 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/WebsiteForm.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/Edit/Form/WebsiteForm.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Block\System\Store\Edit\Form; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class WebsiteForm diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/StoreGrid.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/StoreGrid.php index b6c7817121d118b1777fc3d273c566dd30f05a90..f559e6130eca347c24b9db4dcd961d1f778a1c09 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/StoreGrid.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Store/StoreGrid.php @@ -10,7 +10,7 @@ use Magento\Backend\Test\Block\Widget\Grid as GridInterface; use Magento\Store\Test\Fixture\Store; use Magento\Store\Test\Fixture\StoreGroup; use Magento\Store\Test\Fixture\Website; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class StoreGrid diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Variable/Edit/VariableForm.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Variable/Edit/VariableForm.php index 0c3ad11e969ee626174b652671a6eafdc9677bc4..2b0c596f1f1e5e8541e5f8895f08b2fb1b6369e0 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Variable/Edit/VariableForm.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/System/Variable/Edit/VariableForm.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Block\System\Variable\Edit; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Template.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Template.php index 31b67b6b87330dde3e62f347f087a02328458293..5170a9b72ee00aeb4896c8e5dd4aa5e4361cd7c1 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Template.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Template.php @@ -7,7 +7,7 @@ namespace Magento\Backend\Test\Block; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Template diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Form.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Form.php index fe0aad5c9cdc69057d9f43e92826a5d67af7d80c..d57bd1aa4d78f8f9829b08857a27611793b1d462 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Form.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Form.php @@ -7,10 +7,10 @@ namespace Magento\Backend\Test\Block\Widget; -use Mtf\Block\Form as FormInstance; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form as FormInstance; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/FormTabs.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/FormTabs.php index edf9d9de7e3b4325741121bef2939b85ef7f9d37..ad1e586f8b6e9a1686c14d00a5177c83e3e60ee5 100755 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/FormTabs.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/FormTabs.php @@ -6,15 +6,15 @@ namespace Magento\Backend\Test\Block\Widget; -use Mtf\Block\BlockFactory; -use Mtf\Block\Mapper; -use Mtf\Client\Driver\Selenium\Browser; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; -use Mtf\Util\Iterator\File; -use Mtf\Util\XmlConverter; +use Magento\Mtf\Block\BlockFactory; +use Magento\Mtf\Block\Mapper; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Util\Iterator\File; +use Magento\Mtf\Util\XmlConverter; /** * Class FormTabs @@ -44,18 +44,18 @@ class FormTabs extends Form /** * @constructor - * @param Element $element + * @param SimpleElement $element * @param Mapper $mapper * @param BlockFactory $blockFactory - * @param Browser $browser + * @param BrowserInterface $browser * @param XmlConverter $xmlConverter * @param array $config */ public function __construct( - Element $element, + SimpleElement $element, Mapper $mapper, BlockFactory $blockFactory, - Browser $browser, + BrowserInterface $browser, XmlConverter $xmlConverter, array $config = [] ) { @@ -102,10 +102,10 @@ class FormTabs extends Form * Fill form with tabs * * @param FixtureInterface $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return FormTabs */ - public function fill(FixtureInterface $fixture, Element $element = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null) { $tabs = $this->getFieldsByTabs($fixture); return $this->fillTabs($tabs, $element); @@ -115,10 +115,10 @@ class FormTabs extends Form * Fill specified form with tabs * * @param array $tabs - * @param Element|null $element + * @param SimpleElement|null $element * @return FormTabs */ - protected function fillTabs(array $tabs, Element $element = null) + protected function fillTabs(array $tabs, SimpleElement $element = null) { $context = ($element === null) ? $this->_rootElement : $element; foreach ($tabs as $tabName => $tabFields) { @@ -179,13 +179,13 @@ class FormTabs extends Form * Get data of the tabs * * @param FixtureInterface|null $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return array * * @SuppressWarnings(PHPMD.UnusedLocalVariable) * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ - public function getData(FixtureInterface $fixture = null, Element $element = null) + public function getData(FixtureInterface $fixture = null, SimpleElement $element = null) { $data = []; diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Grid.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Grid.php index d4677523c25c1d31b80fab4e676b65d368fffb3d..3843da95b7b0a4e8cc43bb15ce5b0bd8db7db83a 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Grid.php @@ -6,10 +6,10 @@ namespace Magento\Backend\Test\Block\Widget; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Factory\Factory; /** * Abstract class Grid @@ -243,7 +243,6 @@ abstract class Grid extends Block $this->prepareForSearch($filter); $this->_rootElement->find($this->searchButton, Locator::SELECTOR_CSS)->click(); $this->waitLoader(); - $this->reinitRootElement(); } /** @@ -323,7 +322,6 @@ abstract class Grid extends Block $this->openFilterBlock(); $this->_rootElement->find($this->resetButton, Locator::SELECTOR_CSS)->click(); $this->waitLoader(); - $this->reinitRootElement(); } /** @@ -365,7 +363,7 @@ abstract class Grid extends Block { $this->_rootElement->find($this->massactionSubmit, Locator::SELECTOR_CSS)->click(); if ($acceptAlert) { - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } } @@ -375,7 +373,7 @@ abstract class Grid extends Block * @param array $filter * @param bool $isSearchable * @param bool $isStrict - * @return Element + * @return SimpleElement */ protected function getRow(array $filter, $isSearchable = true, $isStrict = true) { @@ -406,7 +404,7 @@ abstract class Grid extends Block { $data = []; do { - $rows = $this->_rootElement->find($this->rowItem)->getElements(); + $rows = $this->_rootElement->getElements($this->rowItem); foreach ($rows as $row) { $rowData = []; foreach ($columns as $columnName) { @@ -448,7 +446,6 @@ abstract class Grid extends Block $sortBlock->click(); $this->waitLoader(); } - $this->reinitRootElement(); } /** diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Tab.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Tab.php index 88bb906a8f582df3d960f1f69aa9bbe76d0f2e9f..a4f434313fc12b49c2088d85d8b7e9b33fe1b54a 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Tab.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Block/Widget/Tab.php @@ -6,9 +6,9 @@ namespace Magento\Backend\Test\Block\Widget; -use Mtf\Block\Form as AbstractForm; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form as AbstractForm; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; /** * Class Tab @@ -43,10 +43,10 @@ class Tab extends AbstractForm * Fill data to fields on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $data = $this->dataMapping($fields); $this->_fill($data, $element); @@ -58,10 +58,10 @@ class Tab extends AbstractForm * Get data of tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $data = $this->dataMapping($fields); return $this->_getData($data, $element); @@ -71,9 +71,9 @@ class Tab extends AbstractForm * Update data to fields on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element */ - public function updateFormTab(array $fields, Element $element = null) + public function updateFormTab(array $fields, SimpleElement $element = null) { $this->fillFormTab($fields, $element); } @@ -86,7 +86,7 @@ class Tab extends AbstractForm public function getJsErrors() { $data = []; - $elements = $this->_rootElement->find($this->mageErrorField, Locator::SELECTOR_XPATH)->getElements(); + $elements = $this->_rootElement->getElements($this->mageErrorField, Locator::SELECTOR_XPATH); foreach ($elements as $element) { $error = $element->find($this->mageErrorText, Locator::SELECTOR_XPATH); if ($error->isVisible()) { diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchCustomerName.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchCustomerName.php index 999eb88ce4ef0b6cc5c33f36443c7dd2edfdd9ea..70e2cf29fb4ee0739026c568646626b704572741 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchCustomerName.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchCustomerName.php @@ -8,7 +8,7 @@ namespace Magento\Backend\Test\Constraint; use Magento\Backend\Test\Fixture\GlobalSearch; use Magento\Backend\Test\Page\Adminhtml\Dashboard; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGlobalSearchCustomerName diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchNoRecordsFound.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchNoRecordsFound.php index 8b14b75af7cfd924ad3f90e70ba0c622b876abf1..69a2652ce24c741b34e4f87311a4b0e951cadc5b 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchNoRecordsFound.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchNoRecordsFound.php @@ -7,7 +7,7 @@ namespace Magento\Backend\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\Dashboard; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGlobalSearchNoRecordsFound diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchOrderId.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchOrderId.php index cc0af65d02874a206a7c6ff4ffb39173e2ce8ded..4f78438f27c5fee03415b598dd6c8315228a0805 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchOrderId.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchOrderId.php @@ -8,7 +8,7 @@ namespace Magento\Backend\Test\Constraint; use Magento\Backend\Test\Fixture\GlobalSearch; use Magento\Backend\Test\Page\Adminhtml\Dashboard; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGlobalSearchOrderId diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchProductName.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchProductName.php index 5c32c84fb1f9edb2c4d2d508325b7d682327a02f..4e477ff193cf26098a7d6168ea36ad443dac6dd5 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchProductName.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Constraint/AssertGlobalSearchProductName.php @@ -9,7 +9,7 @@ namespace Magento\Backend\Test\Constraint; use Magento\Backend\Test\Fixture\GlobalSearch; use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGlobalSearchProductName diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Admin/SuperAdmin.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Admin/SuperAdmin.php index 017da4d2aca591ca036dbbe37dac316cd60c64cd..2a519151087272f37a464675af3a59aa5a948539 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Admin/SuperAdmin.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Admin/SuperAdmin.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Fixture\Admin; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Fixture\DataFixture; /** * Class SuperAdmin diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Date.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Date.php index e9f9c69db999dcb44c2f2d25b435d870ab8b1457..12c06f560e703348ad9aa6d13f3dac781d7dc53d 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Date.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/Date.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Fixture; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Date diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch.php index a32966711b5094325fc654d72e730fde5159a134..d4f4890694a21961d660cf68c0677bfb48cb748f 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class GlobalSearch diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch/Query.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch/Query.php index 2c7de34543506265378e076a1df0242a86af6f6a..3f14768fb4511a5233a1e4038d693bed751acd32 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch/Query.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Fixture/GlobalSearch/Query.php @@ -6,9 +6,9 @@ namespace Magento\Backend\Test\Fixture\GlobalSearch; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Query diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Conditions.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Conditions.php index 527fa524e21bdd7c7cb1a2fd4d9fb96ef9b27d9f..ce80fa82d407470fe142e0fbc193579172363ba4 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Conditions.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Conditions.php @@ -6,7 +6,7 @@ namespace Magento\Backend\Test\Handler; -use Mtf\Handler\Curl; +use Magento\Mtf\Handler\Curl; /** * Class Conditions diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Extractor.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Extractor.php index 9346e1203a5c83fa25dc320c190c65e1c08d150f..6e980ea374c9f49f781ee631dc51b2a45015c43a 100755 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Extractor.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Extractor.php @@ -7,10 +7,10 @@ namespace Magento\Backend\Test\Handler; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Extractor diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LoginUser.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LoginUser.php index 7589e2bddd681c6babe4e4c10b42eca282ae5956..51cc5e3ab6f2fcfefb51b469432d86d5f4078c25 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LoginUser.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LoginUser.php @@ -6,9 +6,9 @@ namespace Magento\Backend\Test\Handler\Ui; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Ui; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Ui; /** * Class LoginUser diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LogoutUser.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LogoutUser.php index e774b6dc7fd3882299a0da727a23dc6f721d4773..9ffe8a5665bf9dc7eaef69aefe1e43282dd85d98 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LogoutUser.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Handler/Ui/LogoutUser.php @@ -7,9 +7,9 @@ namespace Magento\Backend\Test\Handler\Ui; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Ui; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Ui; /** * Class LogoutUser diff --git a/dev/tests/functional/tests/app/Magento/Backend/Test/Page/AdminAuthLogin.php b/dev/tests/functional/tests/app/Magento/Backend/Test/Page/AdminAuthLogin.php index 3215460fa6055d5c775b815cc29e0568d01625cb..c53ef25e6dc0a4a7dc930ed96849953f74d038a5 100644 --- a/dev/tests/functional/tests/app/Magento/Backend/Test/Page/AdminAuthLogin.php +++ b/dev/tests/functional/tests/app/Magento/Backend/Test/Page/AdminAuthLogin.php @@ -5,9 +5,9 @@ */ namespace Magento\Backend\Test\Page; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class AdminAuthLogin diff --git a/dev/tests/functional/tests/app/Magento/Backup/Test/Constraint/AssertBackupInGrid.php b/dev/tests/functional/tests/app/Magento/Backup/Test/Constraint/AssertBackupInGrid.php index 073ce6fcde77f96ab6ba484fc6dba5c15399754b..71c85156978498e81dbfdde4dc7124debef1ae4a 100644 --- a/dev/tests/functional/tests/app/Magento/Backup/Test/Constraint/AssertBackupInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Backup/Test/Constraint/AssertBackupInGrid.php @@ -7,7 +7,7 @@ namespace Magento\Backup\Test\Constraint; use Magento\Backup\Test\Page\Adminhtml\BackupIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertBackupInGrid diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle.php index fb31b7e0db1528bda7449d96069aa6a398dd6014..12d9fc7f39ea1e69f119a213a66e1e9b94a03fd4 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle.php @@ -7,8 +7,9 @@ namespace Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Bundle\Option; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element; /** * Class Bundle @@ -55,10 +56,10 @@ class Bundle extends Tab * Fill bundle options * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (!isset($fields['bundle_selections'])) { return $this; @@ -80,10 +81,10 @@ class Bundle extends Tab * Get data to fields on downloadable tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $newFields = []; if (!isset($fields['bundle_selections'])) { diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option.php index 4aa699e98b36ad19e6c896402de869f8f450da26..b3286de48a5bd3a1fc50838887eb313e8d8408ed 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option.php @@ -8,9 +8,8 @@ namespace Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Bundle; use Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Bundle\Option\Search\Grid; use Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Bundle\Option\Selection; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Option @@ -92,9 +91,9 @@ class Option extends Form { $mapping = $this->dataMapping($fields); $this->_fill($mapping); - $selections = $this->_rootElement->find($this->removeSelection)->getElements(); + $selections = $this->_rootElement->getElements($this->removeSelection); if (count($selections)) { - foreach ($selections as $itemSelection) { + foreach (array_reverse($selections) as $itemSelection) { $itemSelection->click(); } } diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option/Selection.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option/Selection.php index f7e96753e9e7eb2c05738860af221b0e47dbd0c8..5d213baa8b4b5707b0cdaa4d13b31ce32757363e 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option/Selection.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Bundle/Option/Selection.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Bundle\Option; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Selection diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Product/Composite/Configure.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Product/Composite/Configure.php index f34696966fd96f7ed0133603b3192249091995f6..af5173612c1aad9118fc66b92a2e924691a43674 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Product/Composite/Configure.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Adminhtml/Product/Composite/Configure.php @@ -7,7 +7,7 @@ namespace Magento\Bundle\Test\Block\Adminhtml\Product\Composite; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Configure diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View.php index de4c47845b37033d56080fff5954a13812413e19..5f99ab3bce393aef59a3a5d46ad4e7ee77915d43 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View.php @@ -8,9 +8,9 @@ namespace Magento\Bundle\Test\Block\Catalog\Product; use Magento\Bundle\Test\Block\Catalog\Product\View\Type\Bundle; use Magento\Bundle\Test\Fixture\BundleProduct; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class View @@ -70,7 +70,6 @@ class View extends \Magento\Catalog\Test\Block\Product\View $selector = $this->newsletterFormSelector; $this->browser->waitUntil( function () use ($browser, $selector) { - $this->reinitRootElement(); $element = $browser->find($selector); return $element->isVisible() ? true : null; } diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Bundle.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Bundle.php index feb5b963ab896be79dfe1f413f5bee7f6a3b23eb..137eadb438b48f4addcdb229ca72df4c53e5fbd5 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Bundle.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Bundle.php @@ -9,11 +9,12 @@ namespace Magento\Bundle\Test\Block\Catalog\Product\View\Type; use Magento\Bundle\Test\Fixture\Bundle as BundleDataFixture; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Bundle\Test\Block\Catalog\Product\View\Type\Option; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Bundle @@ -111,7 +112,7 @@ class Bundle extends Block throw new \Exception("Can't find option: \"{$title}\""); } - /** @var Element $optionElement */ + /** @var SimpleElement $optionElement */ $optionElement = $listFormOptions[$title]; $getTypeData = 'get' . $this->optionNameConvert($option['type']) . 'Data'; @@ -152,10 +153,10 @@ class Bundle extends Block /** * Get data of "Drop-down" option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getDropdownData(Element $option) + protected function getDropdownData(SimpleElement $option) { $select = $option->find($this->selectOption, Locator::SELECTOR_XPATH, 'select'); // Skip "Choose option ..."(option #1) @@ -165,10 +166,10 @@ class Bundle extends Block /** * Get data of "Multiple select" option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getMultipleselectData(Element $option) + protected function getMultipleselectData(SimpleElement $option) { $multiselect = $option->find($this->selectOption, Locator::SELECTOR_XPATH, 'multiselect'); $data = $this->getSelectOptionsData($multiselect, 1); @@ -184,13 +185,13 @@ class Bundle extends Block /** * Get data of "Radio buttons" option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getRadiobuttonsData(Element $option) + protected function getRadiobuttonsData(SimpleElement $option) { $listOptions = []; - $optionLabels = $option->find($this->optionLabel, Locator::SELECTOR_XPATH)->getElements(); + $optionLabels = $option->getElements($this->optionLabel, Locator::SELECTOR_XPATH); foreach ($optionLabels as $optionLabel) { if ($optionLabel->isVisible()) { @@ -204,10 +205,10 @@ class Bundle extends Block /** * Get data of "Checkbox" option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getCheckboxData(Element $option) + protected function getCheckboxData(SimpleElement $option) { $data = $this->getRadiobuttonsData($option); @@ -222,11 +223,11 @@ class Bundle extends Block /** * Get data from option of select and multiselect * - * @param Element $element + * @param SimpleElement $element * @param int $firstOption * @return array */ - protected function getSelectOptionsData(Element $element, $firstOption = 1) + protected function getSelectOptionsData(SimpleElement $element, $firstOption = 1) { $listOptions = []; diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Option.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Option.php index 9a9427361df7b780f6f84c3632490d0ed8c089ae..1d3c35cceceef00da7e51acaf78edfa5be9832f3 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Option.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Block/Catalog/Product/View/Type/Option.php @@ -9,7 +9,7 @@ namespace Magento\Bundle\Test\Block\Catalog\Product\View\Type; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Option diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleInCategory.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleInCategory.php index e808b34f92e98b64c3f06f19699a21b851c5bea5..d05b7beb50e61ec1f8adcecee342e676a70e778d 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleInCategory.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleInCategory.php @@ -10,7 +10,7 @@ use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check bundle product on the category page. diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleItemsOnProductPage.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleItemsOnProductPage.php index 4c74bc353fcc744e026f967dc97ea3c2af6bb547..a7ceb39b65a592dbaa0558d637607a72a59a543d 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleItemsOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleItemsOnProductPage.php @@ -8,8 +8,8 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertBundleItemsOnProductPage @@ -26,13 +26,13 @@ class AssertBundleItemsOnProductPage extends AbstractAssertForm * * @param CatalogProductView $catalogProductView * @param BundleProduct $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, BundleProduct $product, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceType.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceType.php index 40fe60cf5379872fc295074d06414b0a7c34d9ad..22e4f9c693a3098d9a8e011628cf7ee6f5f09511 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceType.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceType.php @@ -9,8 +9,8 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertBundlePriceType @@ -37,7 +37,7 @@ class AssertBundlePriceType extends AbstractConstraint * @param CatalogProductView $catalogProductView * @param BundleProduct $product * @param CheckoutCart $checkoutCartView - * @param Browser $browser + * @param BrowserInterface $browser * @param BundleProduct $originalProduct [optional] * @return void */ @@ -45,7 +45,7 @@ class AssertBundlePriceType extends AbstractConstraint CatalogProductView $catalogProductView, BundleProduct $product, CheckoutCart $checkoutCartView, - Browser $browser, + BrowserInterface $browser, BundleProduct $originalProduct = null ) { $checkoutCartView->open()->getCartBlock()->clearShoppingCart(); diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceView.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceView.php index df510064e829bb37ec25333d393f7d5bdb62d3a9..d4e8779a7786966ac464d6186ecff63ea04d326a 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceView.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundlePriceView.php @@ -8,8 +8,8 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check displayed price view for bundle product on product page. @@ -24,13 +24,13 @@ class AssertBundlePriceView extends AbstractConstraint * Assert that displayed price view for bundle product on product page equals passed from fixture. * * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param BundleProduct $product * @return void */ public function processAssert( CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, BundleProduct $product ) { //Open product view page diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleProductInCustomerWishlistOnBackendGrid.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleProductInCustomerWishlistOnBackendGrid.php index f512ad015560f280f3da66574586f7a122a033ff..868112dce9fb03bde9fad1cf6c9538688bca0c39 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleProductInCustomerWishlistOnBackendGrid.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertBundleProductInCustomerWishlistOnBackendGrid.php @@ -8,7 +8,7 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertBundleProductInCustomerWishlistOnBackendGrid diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertGroupedPriceOnBundleProductPage.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertGroupedPriceOnBundleProductPage.php index 4f431b4a0c164de06c8f3ae0403aad04ea777ce4..da18ba61b486e1c9bfa31c6a1ec2464747626e77 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertGroupedPriceOnBundleProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertGroupedPriceOnBundleProductPage.php @@ -8,7 +8,7 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Catalog\Test\Block\Product\View; use Magento\Catalog\Test\Constraint\AssertProductGroupedPriceOnProductPage; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertGroupedPriceOnBundleProductPage diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertTierPriceOnBundleProductPage.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertTierPriceOnBundleProductPage.php index 288f73b194192119d797d93a8f22b1b752c8c203..3c62ea1c4eac77055ad478c6b28de567657631cf 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertTierPriceOnBundleProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Constraint/AssertTierPriceOnBundleProductPage.php @@ -8,8 +8,8 @@ namespace Magento\Bundle\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPage; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertTierPriceOnBundleProductPage @@ -37,13 +37,16 @@ class AssertTierPriceOnBundleProductPage extends AssertProductTierPriceOnProduct /** * Assertion that tier prices are displayed correctly * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param FixtureInterface $product * @return void */ - public function processAssert(Browser $browser, CatalogProductView $catalogProductView, FixtureInterface $product) - { + public function processAssert( + BrowserInterface $browser, + CatalogProductView $catalogProductView, + FixtureInterface $product + ) { //Open product view page $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); $viewBlock = $catalogProductView->getBundleViewBlock(); diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Bundle.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Bundle.php index 092be30151c78bbaf6f27ce5aa5d3a18d6ea0208..082ce5fa3dbee08d0bc963fed6b9d449900935b7 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Bundle.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Bundle.php @@ -7,8 +7,8 @@ namespace Magento\Bundle\Test\Fixture; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\System\Config; /** * Class Bundle diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleDynamic.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleDynamic.php index 05619530cf7f8045cda8c1b61854c695b4e16465..18f692eeda8fe0f84c5c1013c2ebbbd952e376d6 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleDynamic.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleDynamic.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Fixture; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class BundleDynamic diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleFixed.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleFixed.php index 903a8da05d00eb264cda5967fbdbddae1ce2d44f..3cebc6dfa36b2e22d3bb6c36e36a309c286c740b 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleFixed.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleFixed.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Fixture; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class BundleFixed diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct.php index 9745ac6b032f616e37203328310f43b4ee2af66c..399f0184150b4f71d3db05deb87e46e693428d9c 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct.php @@ -6,12 +6,12 @@ namespace Magento\Bundle\Test\Fixture; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\HandlerFactory; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Config; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Config; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Class BundleProduct diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/BundleSelections.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/BundleSelections.php index 02d987d9eb3be30324a5c1781017151a45540997..b3d46087acd1b1d44e534d0c3be3451dd157510a 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/BundleSelections.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/BundleSelections.php @@ -6,8 +6,8 @@ namespace Magento\Bundle\Test\Fixture\BundleProduct; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class BundleSelections diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/Price.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/Price.php index d155c6236f702405766ac4ad3acf956f01725fa8..33965ee8bdfedb2d4eeff1a461e43ced0ac4cfce 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/Price.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/BundleProduct/Price.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Fixture\BundleProduct; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Price diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Cart/Item.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Cart/Item.php index 8ecfd8c910f0ae41716585b61b61dcd839123ccd..89bab0c1b7e8a5e30e95020d9426b4bd116475db 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Cart/Item.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Fixture/Cart/Item.php @@ -7,7 +7,7 @@ namespace Magento\Bundle\Test\Fixture\Cart; use Magento\Bundle\Test\Fixture\BundleProduct; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/BundleProductInterface.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/BundleProductInterface.php index c1f62b99914238fb405487f62f3e8218d848d7f6..d53e765d8c0e6c83291d096ff07c1dbda6645028 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/BundleProductInterface.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/BundleProductInterface.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Handler\BundleProduct; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface BundleProductInterface diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/Curl.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/Curl.php index e5f194127e99a628babc233fa398bd10f3f9ac04..c7746327b728b8bdae8d5c050339db83e80a99a9 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/BundleProduct/Curl.php @@ -8,8 +8,8 @@ namespace Magento\Bundle\Test\Handler\BundleProduct; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Handler\CatalogProductSimple\Curl as ProductCurl; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; /** * Create new bundle product via curl. diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/Curl/CreateBundle.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/Curl/CreateBundle.php index 2b93aaf4b9585fa3fa86f6e43fb1eb54b7c9e7c7..31abf5c15478c01defa5914deeeb1052e4eed9b5 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/Curl/CreateBundle.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Handler/Curl/CreateBundle.php @@ -7,12 +7,12 @@ namespace Magento\Bundle\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class CreateBundle diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/Repository/BundleProduct.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/Repository/BundleProduct.php index 7f91b0f2ae95fc68dd8c9dc6741f55c550a3c948..7e3ea715cca10bd1da1ade7b4567a0a8e820da69 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/Repository/BundleProduct.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/Repository/BundleProduct.php @@ -6,7 +6,7 @@ namespace Magento\Bundle\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class BundleProduct diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleDynamicTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleDynamicTest.php index 42af8b78cc83149ac8e72dcc75ee6609e8266519..fcdff4b9407d0f26811c9522b8bd50e774fc03b7 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleDynamicTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleDynamicTest.php @@ -7,8 +7,8 @@ namespace Magento\Bundle\Test\TestCase; use Magento\Bundle\Test\Fixture\Bundle; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class BundleDynamicTest diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleFixedTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleFixedTest.php index cbc2227fd0ee1769b64b411f4b999849566e12c6..ba309fcd6ed5f5670ac651dba9a80085e3925cc6 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleFixedTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/BundleFixedTest.php @@ -7,8 +7,8 @@ namespace Magento\Bundle\Test\TestCase; use Magento\Bundle\Test\Fixture\Bundle; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class BundleFixedTest diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.php index d39be09dbb642cc66a28bcf35a2224f8750d339c..3dc5fec8c7a2dde69fed367bd24e4bac365f9e6f 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/CreateBundleProductEntityTest.php @@ -10,7 +10,7 @@ use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateBundleProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/EditBundleTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/EditBundleTest.php index 6e466a1f8095c16b48ee306fd01cddc756bcb925..f4592e21ddab9c526025f74e3d2b04718d78f88b 100755 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/EditBundleTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/EditBundleTest.php @@ -7,8 +7,8 @@ namespace Magento\Bundle\Test\TestCase; use Magento\Bundle\Test\Fixture\Bundle; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class EditBundleTest diff --git a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php index aeddf4bcaae49440923e1a89642286f9618881e4..e2ab1af866a86204cd72578d2c80d8495e13252d 100644 --- a/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Bundle/Test/TestCase/UpdateBundleProductEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Bundle\Test\TestCase; use Magento\Bundle\Test\Fixture\BundleProduct; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update BundleProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/AbstractConfigureBlock.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/AbstractConfigureBlock.php index e291635c52ff3b4717350a3dedd5495c30bdd12a..148e06c61fa1efcec312e79863e5bfb72b67e6d6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/AbstractConfigureBlock.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/AbstractConfigureBlock.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Block; use Magento\Catalog\Test\Block\Product\View\CustomOptions; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Block\Form; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AbstractConfigureBlock diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/CategoryForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/CategoryForm.php index 27aac4a235edcedc3577f52c54a0d0355574a154..4a1ba08b8565e73dd84123bdd8f363c5b5cd794f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/CategoryForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/CategoryForm.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Category\Edit; use Magento\Backend\Test\Block\Widget\FormTabs; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class CategoryForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/Tab/Product.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/Tab/Product.php index 18d60a47e0ae81fb9e55f3425327ef64e84511aa..3f29be8ab7f41ab9d9be179571a7c06ee4a6f39b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/Tab/Product.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Edit/Tab/Product.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Category\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Catalog\Test\Block\Adminhtml\Category\Tab\ProductGrid; -use Mtf\Client\Element; /** * Products grid of Category Products tab. @@ -33,10 +33,10 @@ class Product extends Tab * Fill category products. * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return void */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (!isset($fields['category_products'])) { return; @@ -50,10 +50,10 @@ class Product extends Tab * Get data of tab. * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $data = $this->dataMapping($fields); $result = []; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Tree.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Tree.php index ccb3ce9c8f046c1d0fe4d18dfd1cdb59366d3c81..15a87f2de91c0097db842d621b8b8d41d697f5ac 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Tree.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Tree.php @@ -8,10 +8,11 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Category; use Magento\Catalog\Test\Fixture\Category; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element\TreeElement; /** * Class Tree @@ -158,7 +159,9 @@ class Tree extends Block public function isCategoryVisible(Category $category) { $categoryPath = $this->prepareFullCategoryPath($category); - $structure = $this->_rootElement->find($this->treeElement, Locator::SELECTOR_CSS, 'tree')->getStructure(); + /** @var TreeElement $treeElement */ + $treeElement = $this->_rootElement->find($this->treeElement, Locator::SELECTOR_CSS, 'tree'); + $structure = $treeElement->getStructure(); $result = false; $element = array_shift($categoryPath); foreach ($structure as $item) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Widget/Chooser.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Widget/Chooser.php index 2ac3d3251c5baf19f6d177d5ea974a0327e695b1..160116b75181321f160bd0f7db82289a0f79caf0 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Widget/Chooser.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Category/Widget/Chooser.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Category\Widget; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class CategoryChooser diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/AttributeForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/AttributeForm.php index 1161c7a95ea38482dd181224587faef8968b05a4..75a6c1b1c8958f6fd8c09d109302826a6b948bc5 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/AttributeForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/AttributeForm.php @@ -6,11 +6,12 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute; -use Magento\Backend\Test\Block\Widget\FormTabs; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Backend\Test\Block\Widget\FormTabs; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Edit attribute form on catalog product edit page. @@ -35,10 +36,10 @@ class AttributeForm extends FormTabs * Fill the attribute form. * * @param FixtureInterface $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fill(FixtureInterface $fixture, Element $element = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null) { $this->browser->switchToFrame(new Locator($this->iFrame)); $browser = $this->browser; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/CustomAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/CustomAttribute.php index b721484e4738b2dd65cf76353c45bfec241738a7..4dfc6d203b3f945c520bc8fadfff384600d1b20d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/CustomAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/CustomAttribute.php @@ -6,13 +6,13 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Catalog product custom attribute element. */ -class CustomAttribute extends Element +class CustomAttribute extends SimpleElement { /** * Attribute input selector; @@ -42,7 +42,7 @@ class CustomAttribute extends Element */ public function setValue($data) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); $element = $this->getElementByClass($this->getElementClass()); $value = is_array($data) ? $data['value'] : $data; $this->find($this->inputSelector, Locator::SELECTOR_CSS, $element)->setValue($value); @@ -55,7 +55,7 @@ class CustomAttribute extends Element */ public function getValue() { - $this->_eventManager->dispatchEvent(['get_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['get_value'], [__METHOD__, $this->getAbsoluteSelector()]); $inputType = $this->getElementByClass($this->getElementClass()); return $this->find($this->inputSelector, Locator::SELECTOR_CSS, $inputType)->getValue(); } @@ -84,9 +84,6 @@ class CustomAttribute extends Element */ protected function getElementClass() { - $criteria = new \PHPUnit_Extensions_Selenium2TestCase_ElementCriteria('css selector'); - $criteria->value($this->inputSelector); - $input = $this->_getWrappedElement()->element($criteria); - return $input->attribute('class'); + return $this->find($this->inputSelector, Locator::SELECTOR_CSS)->getAttribute('class'); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/AttributeForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/AttributeForm.php index b3ee1ca8e5313b9f60bde17db50fa6387e5f9d20..0a3a1b52f4a50f8018e6b593767b67307e3dd719 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/AttributeForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/AttributeForm.php @@ -6,12 +6,13 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit; -use Magento\Backend\Test\Block\Widget\FormTabs; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Backend\Test\Block\Widget\FormTabs; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Catalog Product Attribute form. @@ -36,14 +37,14 @@ class AttributeForm extends FormTabs * Get data of the tabs. * * @param FixtureInterface $fixture - * @param Element $element + * @param SimpleElement $element * @return array * @throws \Exception * * @SuppressWarnings(PHPMD.UnusedLocalVariable) * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ - public function getData(FixtureInterface $fixture = null, Element $element = null) + public function getData(FixtureInterface $fixture = null, SimpleElement $element = null) { $this->waitForElementVisible($this->propertiesTab); $data = []; @@ -79,7 +80,7 @@ class AttributeForm extends FormTabs */ protected function expandAllToggles() { - $closedToggles = $this->_rootElement->find($this->closedToggle, Locator::SELECTOR_XPATH)->getElements(); + $closedToggles = $this->_rootElement->getElements($this->closedToggle, Locator::SELECTOR_XPATH); foreach ($closedToggles as $toggle) { $toggle->click(); } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Options.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Options.php index 231c6b08f9a63f7968476cf9403121682cc9de6c..3e5a6fd3355b4c3caac80329b35b5c8a3d309b83 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Options.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Options.php @@ -6,14 +6,14 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit\Tab\Options\Option; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\ObjectManager; /** * Options element. */ -class Options extends Element +class Options extends SimpleElement { /** * 'Add Option' button. @@ -52,7 +52,7 @@ class Options extends Element public function getValue() { $data = []; - $options = $this->find($this->option)->getElements(); + $options = $this->getElements($this->option); foreach ($options as $option) { $data[] = $this->getFormInstance($option)->getData(); } @@ -62,10 +62,10 @@ class Options extends Element /** * Get options form. * - * @param Element|null $element + * @param SimpleElement|null $element * @return Option */ - protected function getFormInstance(Element $element = null) + protected function getFormInstance(SimpleElement $element = null) { return ObjectManager::getInstance()->create( 'Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit\Tab\Options\Option', diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Advanced.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Advanced.php index ae4eb3a3987c63af5a3097bbed41e7f79a9ac55c..b1091273427d381a749fb588bb47b4dd7883cac8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Advanced.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Advanced.php @@ -7,7 +7,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; /** * Class AdvancedPropertiesTab @@ -33,10 +34,10 @@ class Advanced extends Tab * Fill 'Advanced Attribute Properties' tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (!$this->_rootElement->find($this->propertiesTabActive)->isVisible()) { $this->_rootElement->find($this->propertiesTab)->click(); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options.php index 861b320f6e23bd25e445d84b3d47567622b3f06e..37bf323fa12f4cc22f0262b576e4e489b1f17703 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options.php @@ -7,7 +7,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; /** * Class Options @@ -26,10 +27,10 @@ class Options extends Tab * Fill 'Options' tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { foreach ($fields['options']['value'] as $field) { $this->_rootElement->find($this->addOption)->click(); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options/Option.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options/Option.php index 6918f41b76766607fb2691c137cc971ef0f564db..062ac3c4a3562300724acecdc7c65aa5edcf6be1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options/Option.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Edit/Tab/Options/Option.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit\Tab\Options; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Option diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main.php index e819d78acfd3856404caff7b7b6ebc1654429d25..47a2e261ba15fd602141d4e20f9cc5d73b7bf695 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Set; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Main @@ -123,7 +123,7 @@ class Main extends Block public function addAttributeSetGroup($groupName) { $this->_rootElement->find($this->addGroupButton)->click(); - $this->_rootElement->setAlertText($groupName); - $this->_rootElement->acceptAlert(); + $this->browser->setAlertText($groupName); + $this->browser->acceptAlert(); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/AttributeSetForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/AttributeSetForm.php index 4d034090adf44803e7a309c84424cb0583916f8d..ef673d484b78d723f62eb95e8ffad9e11ea2ec10 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/AttributeSetForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/AttributeSetForm.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Set\Main; -use Mtf\Block\Form as AbstractForm; +use Magento\Mtf\Block\Form as AbstractForm; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/EditForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/EditForm.php index 6f9dc7e7be315643ab9559afb01d8a7abb9db921..9dcc851e7f9e1f4c5a700026ee3c3f459f579cc1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/EditForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Attribute/Set/Main/EditForm.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Set\Main; -use Mtf\Block\Form as AbstractForm; +use Magento\Mtf\Block\Form as AbstractForm; /** * Class EditForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Composite/Configure.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Composite/Configure.php index b5b29452bb7c298c5e67eb5db87ad127202f6e52..bd6988a5afe234354f0b3148c6e93b277dc201d3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Composite/Configure.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Composite/Configure.php @@ -7,12 +7,11 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Composite; -use Magento\Backend\Test\Block\Template; -use Magento\Catalog\Test\Block\AbstractConfigureBlock; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Catalog\Test\Block\AbstractConfigureBlock; /** * Class Configure diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Action/Attribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Action/Attribute.php index dc054d3f4fb803562a19bbb47514b7ff9eb4661b..d6943bf14db79c61c29156987c56e370ba945271 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Action/Attribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Action/Attribute.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Action; use Magento\Backend\Test\Block\Widget\Form; -use Mtf\Client\Element; +use Magento\Mtf\Client\Locator; /** * Product attribute massaction edit page. @@ -37,7 +37,7 @@ class Attribute extends Form { $this->_rootElement->find( $this->priceFieldEnablerSelector, - Element\Locator::SELECTOR_XPATH, + Locator::SELECTOR_XPATH, 'checkbox' )->setValue('Yes'); } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab.php index 761c1c5de7500b0146a326a74a94e24899255c31..269e53dfcba0d2fda6391f9bd8c80aca4f27c676 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab.php @@ -6,8 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit; -use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class AdvancedPricingTab @@ -29,10 +28,10 @@ class AdvancedPricingTab extends ProductTab * Fill 'Advanced price' product form on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $context = $element ? $element : $this->_rootElement; foreach ($fields as $fieldName => $field) { @@ -66,10 +65,10 @@ class AdvancedPricingTab extends ProductTab * Get data of tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $formData = []; foreach ($fields as $fieldName => $field) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionGroup.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionGroup.php index 3cd38b1cb63a1fffe914bde54ddd16c875635508..36ea46aaff06384131663ff5e6557a5b928f25b3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionGroup.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionGroup.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\AdvancedPricingTab; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options\AbstractOptions; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class OptionField @@ -26,10 +26,10 @@ class OptionGroup extends AbstractOptions * Fill the form 'Extended price' * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return $this */ - public function fillOptions(array $fields, Element $element = null) + public function fillOptions(array $fields, SimpleElement $element = null) { $this->_rootElement->find($this->buttonFormLocator)->click(); return parent::fillOptions($fields, $element); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionTier.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionTier.php index 79eb22af2fda245b686a65655aa0f79942118b7d..7dc90c88899bb8f1318dd7141c257c1aafc6eef8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionTier.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/AdvancedPricingTab/OptionTier.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\AdvancedPricingTab; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options\AbstractOptions; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class OptionTier @@ -26,10 +26,10 @@ class OptionTier extends AbstractOptions * Fill product form 'Tier price' * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return $this */ - public function fillOptions(array $fields, Element $element = null) + public function fillOptions(array $fields, SimpleElement $element = null) { $this->_rootElement->find($this->buttonFormLocator)->click(); return parent::fillOptions($fields, $element); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/ProductTab.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/ProductTab.php index 08f7f5a71e648674a810207448fcf9a6b9824424..c7c48a1847c784ab2dc885b98fe3c3640c73549d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/ProductTab.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/ProductTab.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; use Magento\Backend\Test\Block\Widget\Tab; use Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\Edit; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/AbstractRelated.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/AbstractRelated.php index 33bd8e681b1cc819af446c4a18f89e2d79dff957..e23a8abf1adee5b88ad250c42ca60ff432c5a014 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/AbstractRelated.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/AbstractRelated.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; -use Magento\Backend\Test\Block\Widget\Grid; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; +use Magento\Backend\Test\Block\Widget\Grid; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class AbstractRelated @@ -27,10 +27,10 @@ abstract class AbstractRelated extends Tab * Select related products * * @param array $data - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $data, Element $element = null) + public function fillFormTab(array $data, SimpleElement $element = null) { if (isset($data[$this->relatedType]['value'])) { $context = $element ? $element : $this->_rootElement; @@ -48,10 +48,10 @@ abstract class AbstractRelated extends Tab * Get data of tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $relatedBlock = $this->getRelatedGrid($element); $columns = [ @@ -67,8 +67,8 @@ abstract class AbstractRelated extends Tab /** * Return related products grid * - * @param Element $element + * @param SimpleElement $element * @return Grid */ - abstract protected function getRelatedGrid(Element $element = null); + abstract protected function getRelatedGrid(SimpleElement $element = null); } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Attributes/Search.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Attributes/Search.php index 4a4374d1bed5b1e311c40582ad00808ac1030462..fac0fe3f9fb44bf1fbd89011621b72ab44530555 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Attributes/Search.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Attributes/Search.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Attributes; +use Magento\Mtf\Client\Element\SuggestElement; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Client\Driver\Selenium\Element\SuggestElement; /** * Class FormAttributeSearch @@ -72,6 +72,7 @@ class Search extends SuggestElement if ($this->find($this->searchResult)->getText() == $productAttribute->getFrontendLabel()) { return true; } + return false; } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Crosssell.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Crosssell.php index 552e58154ed5a112fa19b3e0083a17b676a48820..ea40e9576f8256f124eee3cd248ca9fc4285b766 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Crosssell.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Crosssell.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Crosssell\Grid as CrosssellGrid; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Crosssell @@ -33,10 +33,10 @@ class Crosssell extends AbstractRelated /** * Return cross sell products grid * - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @return CrosssellGrid */ - protected function getRelatedGrid(Element $element = null) + protected function getRelatedGrid(SimpleElement $element = null) { $element = $element ? $element : $this->_rootElement; return $this->blockFactory->create( diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options.php index e3c653e1cd3395bed4d9c4f7c9adaf35523e3123..e1782ef6ca1f6f2cb603e31f627a0c99c1096d8a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options.php @@ -7,9 +7,10 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options\Search\Grid; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Client\Locator; /** * Class Options @@ -56,10 +57,10 @@ class Options extends Tab * Fill custom options form on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $fields = reset($fields); if (empty($fields['value']) || !is_array($fields['value'])) { @@ -136,10 +137,10 @@ class Options extends Tab * Get data of tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $fields = reset($fields); $formData = []; @@ -196,6 +197,7 @@ class Options extends Tab $importOptions = $options['import']['options']; $options = array_merge($options, $importOptions); unset($options['import']); + return $options; } @@ -211,6 +213,7 @@ class Options extends Tab if ($end = strpos($str, '-')) { $str = substr($str, 0, $end) . ucfirst(substr($str, ($end + 1))); } + return $str; } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/AbstractOptions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/AbstractOptions.php index a503837d1199c87956098006acf8e1ba49bc711c..55af1526e62097c49f674318e3ee8f5872998e6b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/AbstractOptions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/AbstractOptions.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; /** * Abstract class AbstractOptions @@ -19,14 +19,15 @@ abstract class AbstractOptions extends Tab * Fills in the form of an array of input data * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return $this */ - public function fillOptions(array $fields, Element $element = null) + public function fillOptions(array $fields, SimpleElement $element = null) { $element = $element === null ? $this->_rootElement : $element; $mapping = $this->dataMapping($fields); $this->_fill($mapping, $element); + return $this; } @@ -34,13 +35,14 @@ abstract class AbstractOptions extends Tab * Getting options data form on the product form * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return $this */ - public function getDataOptions(array $fields = null, Element $element = null) + public function getDataOptions(array $fields = null, SimpleElement $element = null) { $element = $element === null ? $this->_rootElement : $element; $mapping = $this->dataMapping($fields); + return $this->_getData($mapping, $element); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/Type/DropDown.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/Type/DropDown.php index 637636979a89ec82885b3548efb84bb2416196bd..bf958e52b0adddc21e48a03be9a69ba826d100ad 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/Type/DropDown.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Options/Type/DropDown.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options\Type; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Options\AbstractOptions; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Form "Option dropdown" on tab product "Custom options". @@ -32,13 +32,14 @@ class DropDown extends AbstractOptions * Fill the form. * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return $this */ - public function fillOptions(array $fields, Element $element = null) + public function fillOptions(array $fields, SimpleElement $element = null) { $this->_rootElement->find($this->optionTitle)->click(); $this->_rootElement->find($this->buttonAddLocator)->click(); + return parent::fillOptions($fields, $element); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails.php index 6d4db31a1b2ee834a5dbc2def0e245522a23c9ac..546719a20d45924939f41db8bad0bbd905687219 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; /** * Product details tab. @@ -32,10 +32,10 @@ class ProductDetails extends \Magento\Catalog\Test\Block\Adminhtml\Product\Edit\ * Fill data to fields on tab. * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $data = $this->dataMapping($fields); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/AttributeSet.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/AttributeSet.php index 651739618a84d8ddaa3611b5719d539f5642e244..56d6b46ed629a7a40590f3b57171d3e496ee9fc4 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/AttributeSet.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/AttributeSet.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\ProductDetails; -use Mtf\Client\Driver\Selenium\Element\SuggestElement; +use Magento\Mtf\Client\Element\SuggestElement; /** * Class AttributeSet diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/CategoryIds.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/CategoryIds.php index 2cc41dd5bec986eadecf891217d45abb3ff05540..0e45e4c6cdd835a113375903f9199f56ad20d089 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/CategoryIds.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/CategoryIds.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\ProductDetails; -use Mtf\Client\Driver\Selenium\Element\MultisuggestElement; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\MultisuggestElement; /** * Typified element class for category element. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/ProductOnlineSwitcher.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/ProductOnlineSwitcher.php index 60b84be3c1245442ba952d4ef97a0c45a2cad13b..55f800b3f67b7f2b0ffc2c1bf73c999ddfb85009 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/ProductOnlineSwitcher.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/ProductDetails/ProductOnlineSwitcher.php @@ -6,14 +6,14 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\ProductDetails; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class ProductOnlineSwitcher * Typified element class for product status element */ -class ProductOnlineSwitcher extends Element +class ProductOnlineSwitcher extends SimpleElement { /** * CSS locator button status of the product diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Related.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Related.php index 93fb6f594f2fdaa159c91ab4c86084592078fde2..78298efb56abf89f5d919398e1b22afcad7aceb8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Related.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Related.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Related\Grid as RelatedGrid; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Related @@ -33,12 +33,13 @@ class Related extends AbstractRelated /** * Return related products grid * - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @return RelatedGrid */ - protected function getRelatedGrid(Element $element = null) + protected function getRelatedGrid(SimpleElement $element = null) { $element = $element ? $element : $this->_rootElement; + return $this->blockFactory->create( '\Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Related\Grid', ['element' => $element->find($this->relatedGrid)] diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Upsell.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Upsell.php index 010c5bd3020c1cfde77a242f263c07525a813e53..f3d4ff8f8bc97232d85a14d58afb29a3e2ffd568 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Upsell.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Upsell.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Upsell\Grid as UpsellGrid; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Upsell @@ -33,12 +33,13 @@ class Upsell extends AbstractRelated /** * Return related products grid * - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @return UpsellGrid */ - protected function getRelatedGrid(Element $element = null) + protected function getRelatedGrid(SimpleElement $element = null) { $element = $element ? $element : $this->_rootElement; + return $this->blockFactory->create( '\Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Upsell\Grid', ['element' => $element->find($this->crossSellGrid)] diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Websites/StoreTree.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Websites/StoreTree.php index cf1ddaee1ee32016c41d31edfabe96b28304bcb4..f9b1f1a92be20b77040dc52b07c872a23f1bb045 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Websites/StoreTree.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/Edit/Tab/Websites/StoreTree.php @@ -6,14 +6,14 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Websites; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class StoreTree * Typified element class for store tree element */ -class StoreTree extends Element +class StoreTree extends SimpleElement { /** * Selector for website checkbox diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/FormPageActions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/FormPageActions.php index fd99b998c340f4282f55e6b586dbf98ade4c09f9..9778f9a4b34a57e9725ae66b6516f0e1385889d3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/FormPageActions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/FormPageActions.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product; use Magento\Backend\Test\Block\FormPageActions as ParentFormPageActions; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class FormAction diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/GridPageAction.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/GridPageAction.php index 47526b696ca0bfb289a964cc0976b04b0b193aad..bafda38e5f53d11d5af355b7878e512e3f2a01dc 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/GridPageAction.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/GridPageAction.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Block\Adminhtml\Product; use Magento\Backend\Test\Block\GridPageActions as ParentGridPageActions; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class GridPageAction diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.php index b582f3526f3c9ecf83548197e23b4f503d0ff8f3..51df922610d9164ae09c3f6faa155096b886d99d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Adminhtml/Product/ProductForm.php @@ -10,14 +10,15 @@ use Magento\Backend\Test\Block\Widget\FormTabs; use Magento\Backend\Test\Block\Widget\Tab; use Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\AttributeForm; use Magento\Catalog\Test\Block\Adminhtml\Product\Attribute\CustomAttribute; -use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\ProductTab; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\ProductTab; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\DataFixture; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\DataFixture; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Product form on backend product page. @@ -126,13 +127,13 @@ class ProductForm extends FormTabs * Fill the product form. * * @param FixtureInterface $product - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @param FixtureInterface|null $category [optional] * @return FormTabs * * @SuppressWarnings(PHPMD.NPathComplexity) */ - public function fill(FixtureInterface $product, Element $element = null, FixtureInterface $category = null) + public function fill(FixtureInterface $product, SimpleElement $element = null, FixtureInterface $category = null) { $dataConfig = $product->getDataConfig(); $typeId = isset($dataConfig['type_id']) ? $dataConfig['type_id'] : null; @@ -182,7 +183,6 @@ class ProductForm extends FormTabs $tab = $this->openTab($tabName); $tab->addNewAttribute($tabName); $this->fillAttributeForm($attribute); - $this->reinitRootElement(); } } @@ -190,12 +190,13 @@ class ProductForm extends FormTabs * Get data of the tabs. * * @param FixtureInterface|null $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getData(FixtureInterface $fixture = null, Element $element = null) + public function getData(FixtureInterface $fixture = null, SimpleElement $element = null) { $this->showAdvancedSettings(); + return parent::getData($fixture, $element); } @@ -328,6 +329,7 @@ class ProductForm extends FormTabs $tabName = strtolower($tabName); $selector = sprintf($this->customTab, $tabName); $this->waitForElementVisible($selector, Locator::SELECTOR_XPATH); + return $this->_rootElement->find($selector, Locator::SELECTOR_XPATH)->isVisible(); } @@ -363,6 +365,7 @@ class ProductForm extends FormTabs $data[$tabName] = $errors; } } + return $data; } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/ProductPagination.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/ProductPagination.php index ae9a508fb562a22cffa7674f11d494b26da80f86..7051e8d5372ead5dab04b364e523d1be32e12655 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/ProductPagination.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/ProductPagination.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Category; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class ProductPagination @@ -26,7 +26,7 @@ class ProductPagination extends Block /** * Getting the active element to go to the next page * - * @return \Mtf\Client\Element|null + * @return \Magento\Mtf\Client\Element|null */ public function getNextPage() { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/View.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/View.php index e49e273cb7302b9749cf591aa24244ac1f07a6bb..b8c85e290dd14f129545de8f05f50bd98352f79d 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/View.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Category/View.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Block\Category; use Magento\Widget\Test\Fixture\Widget; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class View @@ -66,8 +66,7 @@ class View extends Block { $products = []; $this->waitForElementVisible($this->recentlyViewedProducts, Locator::SELECTOR_XPATH); - $productNames = $this->_rootElement->find($this->recentlyViewedProducts, Locator::SELECTOR_XPATH) - ->getElements(); + $productNames = $this->_rootElement->getElements($this->recentlyViewedProducts, Locator::SELECTOR_XPATH); foreach ($productNames as $productName) { $products[] = $productName->getText(); } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Additional.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Additional.php index 7cdcada069665e9aa94daeaaaf9ee83d9e87ac3e..fdfbc654c12bbc94ebfd21df16c4b71c332fbf9d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Additional.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Additional.php @@ -6,10 +6,11 @@ namespace Magento\Catalog\Test\Block\Product; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; /** * Product additional information block on the product page. @@ -33,18 +34,19 @@ class Additional extends Block /** * Get product attributes. * - * @return Element[] + * @return SimpleElement[] */ protected function getProductAttributes() { $data = []; - $elements = $this->_rootElement->find($this->attributeSelector, Locator::SELECTOR_XPATH)->getElements(); + $elements = $this->_rootElement->getElements($this->attributeSelector, Locator::SELECTOR_XPATH); foreach ($elements as $element) { $data[$element->getText()] = $this->_rootElement->find( $this->attributeSelector . $this->attributeValueSelector, Locator::SELECTOR_XPATH ); } + return $data; } @@ -67,11 +69,11 @@ class Additional extends Block /** * Find <tag1><tag2><tagN> ... </tagN></tag2></tag1> tag structure in element. * - * @param Element $element + * @param SimpleElement $element * @param string $selector - * @return Element + * @return SimpleElement */ - protected function checkHtmlTagStructure(Element $element, $selector) + protected function checkHtmlTagStructure(SimpleElement $element, $selector) { return $element->find($selector); } @@ -105,6 +107,7 @@ class Additional extends Block for ($index = 0; $index < $middleElement; $index++) { $selector .= $htmlData[$index]['tag'] . " "; } + return trim($selector); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/ListCompare.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/ListCompare.php index 768edce417884a0dd1ec159f019b0cb66c85457c..22c7b8213d29da77df1d519a31ef2cf599554d05 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/ListCompare.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/ListCompare.php @@ -6,9 +6,10 @@ namespace Magento\Catalog\Test\Block\Product\Compare; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Catalog\Test\Fixture\CatalogProductAttribute; +use Magento\Mtf\Client\Element\SimpleElement; /** * Compare list product block. @@ -116,7 +117,7 @@ class ListCompare extends Block * Get item compare product info. * * @param int $index - * @return Element + * @return SimpleElement */ protected function getCompareProductInfo($index) { @@ -139,7 +140,7 @@ class ListCompare extends Block ); $data = []; - $attributes = $this->_rootElement->find($this->attribute)->getElements(); + $attributes = $this->_rootElement->getElements($this->attribute); foreach ($attributes as $attribute) { $data[] = $attribute->getText(); } @@ -150,7 +151,7 @@ class ListCompare extends Block * Get item compare product attribute. * * @param string $key - * @return Element + * @return SimpleElement */ public function getCompareProductAttribute($key) { @@ -207,7 +208,6 @@ class ListCompare extends Block while ($this->isProductVisible()) { $this->removeProduct(); $messageBlock->waitSuccessMessage(); - $this->reinitRootElement(); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/Sidebar.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/Sidebar.php index 6c6cc28808b42838de04a81ada3d6df2c89e6046..89d6ffe88b1ca4965507e43312608fc161f1c524 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/Sidebar.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Compare/Sidebar.php @@ -6,8 +6,6 @@ namespace Magento\Catalog\Test\Block\Product\Compare; -use Mtf\Client\Element; - /** * Compare product block on cms page. */ @@ -51,7 +49,7 @@ class Sidebar extends ListCompare return $rootElement->find($selector)->isVisible() ? true : null; } ); - $elements = $this->_rootElement->find($this->productName)->getElements(); + $elements = $this->_rootElement->getElements($this->productName); foreach ($elements as $element) { $result[] = $element->getText(); } @@ -74,6 +72,6 @@ class Sidebar extends ListCompare public function clickClearAll() { $this->_rootElement->find($this->clearAll)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts.php index 4ac1574f4ef2df7ab256d03d0b68c6b4c4d065b2..59f48c60913a61f1803a35c706cead61b7272668 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts.php @@ -7,9 +7,10 @@ namespace Magento\Catalog\Test\Block\Product\Grouped; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; /** * Class AssociatedProducts @@ -20,7 +21,7 @@ class AssociatedProducts extends Tab /** * 'Create New Option' button * - * @var Element + * @var SimpleElement */ protected $addNewOption = '#grouped-product-container>button'; @@ -53,10 +54,10 @@ class AssociatedProducts extends Tab /** * Get associated products list block * - * @param Element $context + * @param SimpleElement $context * @return \Magento\Catalog\Test\Block\Product\Grouped\AssociatedProducts\ListAssociatedProducts */ - protected function getListAssociatedProductsBlock(Element $context = null) + protected function getListAssociatedProductsBlock(SimpleElement $context = null) { $element = $context ?: $this->_rootElement; @@ -69,10 +70,10 @@ class AssociatedProducts extends Tab * Fill data to fields on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (isset($fields['grouped_products'])) { foreach ($fields['grouped_products']['value'] as $groupedProduct) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php index c99c9348ce3e2968ff4536b977337b32f6c487af..51fba6b4440a121a27ba5281175a4d52c99fb689 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php @@ -6,10 +6,10 @@ namespace Magento\Catalog\Test\Block\Product\Grouped\AssociatedProducts; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Factory\Factory; /** * Class ListAssociatedProducts @@ -21,10 +21,10 @@ class ListAssociatedProducts extends Block * Getting block products * * @param string $productId - * @param Element $context + * @param SimpleElement $context * @return ListAssociatedProducts\Product */ - private function getProductBlock($productId, Element $context = null) + private function getProductBlock($productId, SimpleElement $context = null) { $element = $context ?: $this->_rootElement; return Factory::getBlockFactory() @@ -40,9 +40,9 @@ class ListAssociatedProducts extends Block * Filling options products * * @param array $data - * @param Element $element + * @param SimpleElement $element */ - public function fillProductOptions(array $data, Element $element = null) + public function fillProductOptions(array $data, SimpleElement $element = null) { $productBlock = $this->getProductBlock($data['product_id']['value'], $element); $productBlock->fillQty($data['selection_qty']['value']); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php index 7b1fadb9301234b426eeeba68d0a548a37340cef..80f0b1d6b8bd94d816c9d0cf676a96421a4ea339 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php @@ -6,8 +6,11 @@ namespace Magento\Catalog\Test\Block\Product\Grouped\AssociatedProducts\ListAssociatedProducts; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; +/** + * Class Product + */ class Product extends Block { /** diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/Search/Grid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/Search/Grid.php index f04e5fefeb8c1ddcb89779c784846111e978dbf7..e8dc06003db01756a30cd7a4be1c7565e0be7557 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/Search/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Grouped/AssociatedProducts/Search/Grid.php @@ -10,7 +10,6 @@ use Magento\Backend\Test\Block\Widget\Grid as GridInterface; /** * Class Grid - * */ class Grid extends GridInterface { @@ -37,6 +36,8 @@ class Grid extends GridInterface /** * Initialize block elements + * + * @return void */ protected function _init() { @@ -46,6 +47,8 @@ class Grid extends GridInterface /** * Press 'Add Selected Products' button + * + * @return void */ public function addProducts() { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ListProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ListProduct.php index d027c9ae4294ce7cf02b78cf24fb858a8098d2d0..4415fec2ac069e006b5cf47e8e3f4b27bc2a4319 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ListProduct.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ListProduct.php @@ -6,10 +6,10 @@ namespace Magento\Catalog\Test\Block\Product; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Factory\Factory; /** * Product list. @@ -135,7 +135,7 @@ class ListProduct extends Block * This method returns the element representing the product details for the named product. * * @param string $productName String containing the name of the product - * @return Element + * @return SimpleElement */ protected function getProductDetailsElement($productName) { @@ -149,7 +149,7 @@ class ListProduct extends Block * This method returns the element on the page associated with the product name. * * @param string $productName String containing the name of the product - * @return Element + * @return SimpleElement */ protected function getProductNameElement($productName) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Price.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Price.php index 51d590c9d8c4d9fca190c4dc59f963771dee95ef..52d04a0e4e82a7417462061c32c4793d58e146d8 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Price.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/Price.php @@ -5,9 +5,9 @@ */ namespace Magento\Catalog\Test\Block\Product; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Price @@ -267,7 +267,7 @@ class Price extends Block * Get specify type price element * * @param string $type - * @return Element + * @return SimpleElement */ protected function getTypePriceElement($type) { @@ -294,21 +294,23 @@ class Price extends Block * Get price excluding tax * * @param string $currency - * @return string + * @return string|null */ public function getPriceExcludingTax($currency = '$') { - return trim($this->_rootElement->find($this->priceExcludingTax)->getText(), $currency); + $priceElement = $this->_rootElement->find($this->priceExcludingTax); + return $priceElement->isVisible() ? trim($priceElement->getText(), $currency) : null; } /** * Get price including tax * * @param string $currency - * @return string + * @return string|null */ public function getPriceIncludingTax($currency = '$') { - return trim($this->_rootElement->find($this->priceIncludingTax)->getText(), $currency); + $priceElement = $this->_rootElement->find($this->priceIncludingTax); + return $priceElement->isVisible() ? trim($priceElement->getText(), $currency) : null; } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/BottomToolbar.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/BottomToolbar.php index e5866a521d3356714806fd22fc39a443488829bd..7bbe9c2d7613cc7dd708a84262dad9f058a8fc64 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/BottomToolbar.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/BottomToolbar.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Product\ProductList; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class BottomToolbar diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Crosssell.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Crosssell.php index 6c4bf4c8f62043485b138876159870983a64c31d..9b5d42d49b9130569596ad016c0d2eb7b754c469 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Crosssell.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Crosssell.php @@ -6,11 +6,11 @@ namespace Magento\Catalog\Test\Block\Product\ProductList; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; /** * Class Crosssell @@ -41,7 +41,7 @@ class Crosssell extends Block * Click on cross-sell product link * * @param Product $product - * @return Element + * @return SimpleElement */ public function clickLink($product) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Related.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Related.php index 6d36de4de97a02a41a281c174f2de7c8b1f33fa9..dd65782e9f253ada489329075282f5ce4f76d7a2 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Related.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Related.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Block\Product\ProductList; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Related @@ -73,7 +73,7 @@ class Related extends Block * Get related product element * * @param string $productName - * @return Element + * @return SimpleElement */ private function getProductElement($productName) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/TopToolbar.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/TopToolbar.php index 4090f15dc3637c48c75d7489f3734eb8f1509bbe..7f53f190bd41710fa6988f628f35227df4c760b6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/TopToolbar.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/TopToolbar.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Block\Product\ProductList; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class TopToolbar diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Upsell.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Upsell.php index e789535fa0428b2551a299ff77913faa2ea9a86e..ce1ee095156a918fd8fbd2d0e077045fc254aba9 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Upsell.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/ProductList/Upsell.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Block\Product\ProductList; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Upsell @@ -48,7 +48,7 @@ class Upsell extends Block * Get a the product * * @param string $productName - * @return Element + * @return SimpleElement */ private function getProductElement($productName) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View.php index 20da95313d9949902d58e7e176d3c75f2856a623..b658bb823cdfd53903156b7a9aa8580d49ece99e 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Block\Product; use Magento\Catalog\Test\Block\AbstractConfigureBlock; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Product view block on the product page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View/CustomOptions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View/CustomOptions.php index 67b43503f752ae135f800c96e215197a039ffb6f..ea07ff104aafa1ea93f96eb3a7b1e0b79f84b35b 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View/CustomOptions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Product/View/CustomOptions.php @@ -6,11 +6,11 @@ namespace Magento\Catalog\Test\Block\Product\View; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class CustomOptions @@ -136,7 +136,7 @@ class CustomOptions extends Form throw new \Exception("Can't find option: \"{$title}\""); } - /** @var Element $optionElement */ + /** @var SimpleElement $optionElement */ $optionElement = $listCustomOptions[$title]; $typeMethod = preg_replace('/[^a-zA-Z]/', '', $option['type']); $getTypeData = 'get' . ucfirst(strtolower($typeMethod)) . 'Data'; @@ -178,10 +178,10 @@ class CustomOptions extends Form /** * Get data of "Field" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getFieldData(Element $option) + protected function getFieldData(SimpleElement $option) { $price = $this->getOptionPriceNotice($option); $maxCharacters = $option->find($this->maxCharacters, Locator::SELECTOR_XPATH); @@ -199,10 +199,10 @@ class CustomOptions extends Form /** * Get data of "Area" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getAreaData(Element $option) + protected function getAreaData(SimpleElement $option) { return $this->getFieldData($option); } @@ -210,10 +210,10 @@ class CustomOptions extends Form /** * Get data of "File" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getFileData(Element $option) + protected function getFileData(SimpleElement $option) { $price = $this->getOptionPriceNotice($option); @@ -232,10 +232,10 @@ class CustomOptions extends Form /** * Get data of "Drop-down" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getDropdownData(Element $option) + protected function getDropdownData(SimpleElement $option) { $select = $option->find($this->selectOption, Locator::SELECTOR_XPATH, 'select'); // Skip "Choose option ..."(option #1) @@ -245,10 +245,10 @@ class CustomOptions extends Form /** * Get data of "Multiple Select" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getMultipleSelectData(Element $option) + protected function getMultipleSelectData(SimpleElement $option) { $multiselect = $option->find($this->selectOption, Locator::SELECTOR_XPATH, 'multiselect'); return $this->getSelectOptionsData($multiselect, 1); @@ -257,14 +257,15 @@ class CustomOptions extends Form /** * Get data of "Radio Buttons" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getRadioButtonsData(Element $option) + protected function getRadioButtonsData(SimpleElement $option) { $listOptions = []; $count = 1; + /** @var SimpleElement $option */ $option = $option->find(sprintf($this->optionLabel, $count), Locator::SELECTOR_XPATH); while ($option->isVisible()) { $listOptions[] = $this->parseOptionText($option->getText()); @@ -280,10 +281,10 @@ class CustomOptions extends Form /** * Get data of "Checkbox" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getCheckboxData(Element $option) + protected function getCheckboxData(SimpleElement $option) { return $this->getRadioButtonsData($option); } @@ -291,10 +292,10 @@ class CustomOptions extends Form /** * Get data of "Date" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getDateData(Element $option) + protected function getDateData(SimpleElement $option) { $price = $this->getOptionPriceNotice($option); @@ -310,10 +311,10 @@ class CustomOptions extends Form /** * Get data of "Date & Time" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getDateTimeData(Element $option) + protected function getDateTimeData(SimpleElement $option) { return $this->getDateData($option); } @@ -321,10 +322,10 @@ class CustomOptions extends Form /** * Get data of "Time" custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getTimeData(Element $option) + protected function getTimeData(SimpleElement $option) { return $this->getDateData($option); } @@ -332,11 +333,11 @@ class CustomOptions extends Form /** * Get data from option of select and multiselect * - * @param Element $element + * @param SimpleElement $element * @param int $firstOption * @return array */ - protected function getSelectOptionsData(Element $element, $firstOption = 1) + protected function getSelectOptionsData(SimpleElement $element, $firstOption = 1) { $listOptions = []; @@ -356,10 +357,10 @@ class CustomOptions extends Form /** * Get price from price-notice of custom option * - * @param Element $option + * @param SimpleElement $option * @return array */ - protected function getOptionPriceNotice(Element $option) + protected function getOptionPriceNotice(SimpleElement $option) { $priceNotice = $option->find($this->priceNotice, Locator::SELECTOR_XPATH); if (!$priceNotice->isVisible()) { @@ -371,11 +372,11 @@ class CustomOptions extends Form /** * Get notice of option by number * - * @param Element $option + * @param SimpleElement $option * @param int $number * @return mixed */ - protected function getOptionNotice(Element $option, $number) + protected function getOptionNotice(SimpleElement $option, $number) { $note = $option->find(sprintf($this->noteByNumber, $number), Locator::SELECTOR_XPATH); return $note->isVisible() ? $note->getText() : null; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Search.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Search.php index c66390c667a0aea80c3f0db60d7a36a9f0391008..2257512b72f9ea91dba1592cd19a6248fc37801e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Search.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Block/Search.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Search diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAbsenceDeleteAttributeButton.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAbsenceDeleteAttributeButton.php index 4174cb6d23eec32def16c6c84debca60990744a4..3c017e29dabb46fdcf629f3279483a9c49fd1bd2 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAbsenceDeleteAttributeButton.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAbsenceDeleteAttributeButton.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAbsenceDeleteAttributeButton diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonAbsent.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonAbsent.php index 71992451111a951d9d1d62e70788a74e996ac217..4aad21571bd7d4b45d3e40c4b4bffc1fa2cf0b5c 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonAbsent.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonAbsent.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAddToCartButtonAbsent diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonPresent.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonPresent.php index 470580cddbf0d69429fd9aec40fe11190eacc76d..b779f7a8eaaee717b523a6e35f19e2546f7cf881 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonPresent.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddToCartButtonPresent.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAddToCartButtonPresent diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddedProductAttributeOnProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddedProductAttributeOnProductForm.php index 2fa65b17147572e20afeb07d766c34f5ec0aef58..a5ffd6438ac26a03e795ad3881931b492f8d435f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddedProductAttributeOnProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAddedProductAttributeOnProductForm.php @@ -8,12 +8,12 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\InjectableFixture; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\ObjectManager; +use Magento\Mtf\ObjectManager; /** * Check attribute on product form. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeForm.php index f6bf41059077ce17bb33c89318cd9238d0da5bfa..d559f1386cdeb188c49f502c482c8e6e50828d7a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeForm.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Assert that displayed attribute data on edit page equals passed from fixture. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeOptionsOnProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeOptionsOnProductForm.php index 7ce9ed37e4622fb772f0d0508e1df21679e26dbf..5d8898934c1a2738ada381c0baa9f6478993b17b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeOptionsOnProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeOptionsOnProductForm.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAttributeOptionsOnProductForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeSearchableByLabel.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeSearchableByLabel.php index 0497a34073664f5fd56877701dcd60945e50d8b9..f79f14a6689162ce1aa3b36d50ffa1b5ac0eb200 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeSearchableByLabel.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertAttributeSearchableByLabel.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAttributeSearchableByLabel diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnBackend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnBackend.php index 3668858b2a9f34d2cfcaf0fe00f874aea35accfa..16be1cbf6e00c53f64ec2c4708ea64dde2c2bbbe 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnBackend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnBackend.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryAbsenceOnBackend diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnFrontend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnFrontend.php index e7786799d6625aa8a4f4441e8a71ff2070774fe1..f4c2b6530a788f6bbed326bdf08b199f0ebb1847 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryAbsenceOnFrontend.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryAbsenceOnFrontend @@ -29,13 +29,16 @@ class AssertCategoryAbsenceOnFrontend extends AbstractConstraint /** * Assert that not displayed category in frontend main menu * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogCategoryView $categoryView * @param Category $category * @return void */ - public function processAssert(Browser $browser, CatalogCategoryView $categoryView, Category $category) - { + public function processAssert( + BrowserInterface $browser, + CatalogCategoryView $categoryView, + Category $category + ) { $browser->open($_ENV['app_frontend_url'] . $category->getUrlKey() . '.html'); \PHPUnit_Framework_Assert::assertEquals( self::NOT_FOUND_MESSAGE, diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForAssignedProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForAssignedProducts.php index c1a7fea183a6aaa992006265ff6c61d701779fb2..f81d4b389d29c8b3134c06bd14d05a11e5e53064 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForAssignedProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForAssignedProducts.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryForAssignedProducts @@ -26,14 +26,18 @@ class AssertCategoryForAssignedProducts extends AbstractConstraint * * @param Category $category * @param CatalogCategoryView $categoryView - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(Category $category, CatalogCategoryView $categoryView, Browser $browser) - { + public function processAssert( + Category $category, + CatalogCategoryView $categoryView, + BrowserInterface $browser + ) { $categoryUrlKey = $category->hasData('url_key') ? strtolower($category->getUrlKey()) : trim(strtolower(preg_replace('#[^0-9a-z%]+#i', '-', $category->getName())), '-'); + $products = $category->getDataFieldConfig('category_products')['source']->getProducts(); $browser->open($_ENV['app_frontend_url'] . $categoryUrlKey . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForm.php index c0bf8c3bb07c7af0f353c2cff5bc06983fded2f8..06d7ce4fe0af9a7e130f0b0678d150d059657ae4 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryForm.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryIndex; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Assert that displayed category data on edit page equals passed from fixture. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotActive.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotActive.php index e7a3b603354246e9285b772f9f9c04d1bdbd548e..b83d2fd8599096f58a466fbd350e67eae246d20f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotActive.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotActive.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryIsNotActive @@ -28,10 +28,10 @@ class AssertCategoryIsNotActive extends AbstractConstraint * * @param CmsIndex $cmsIndex * @param Category $category - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CmsIndex $cmsIndex, Category $category, Browser $browser) + public function processAssert(CmsIndex $cmsIndex, Category $category, BrowserInterface $browser) { $cmsIndex->open(); \PHPUnit_Framework_Assert::assertFalse( diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotIncludeInMenu.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotIncludeInMenu.php index a4738147eae13e074a6e6af1af0e1252c9e2d0dd..07b23794984b7c3851b2c1d10fcb5cfb97085a6f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotIncludeInMenu.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryIsNotIncludeInMenu.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryIsNotIncludeInMenu @@ -27,14 +27,14 @@ class AssertCategoryIsNotIncludeInMenu extends AbstractConstraint * * @param CmsIndex $cmsIndex * @param Category $category - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogCategoryView $categoryView * @return void */ public function processAssert( CmsIndex $cmsIndex, Category $category, - Browser $browser, + BrowserInterface $browser, CatalogCategoryView $categoryView ) { $cmsIndex->open(); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryPage.php index 59c7ba41e59302442e5e64b777535a622de50943..3197b59c3d55c54550f2dbfaa8dd952db5938ec4 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryPage.php @@ -9,9 +9,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\Category\LandingPage; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Assert that displayed category data on category page equals to passed from fixture. @@ -53,7 +53,7 @@ class AssertCategoryPage extends AbstractConstraint * @param Category $initialCategory * @param FixtureFactory $fixtureFactory * @param CatalogCategoryView $categoryView - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( @@ -61,7 +61,7 @@ class AssertCategoryPage extends AbstractConstraint Category $initialCategory, FixtureFactory $fixtureFactory, CatalogCategoryView $categoryView, - Browser $browser + BrowserInterface $browser ) { $this->browser = $browser; $this->categoryViewPage = $categoryView; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryRedirect.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryRedirect.php index e7dcaac9ba593f0e0aaeb83822439e1ac9d73145..3c72fa66599ca92c9a28fc8be1c38dd80a07dadb 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryRedirect.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategoryRedirect.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategoryRedirect @@ -24,12 +24,15 @@ class AssertCategoryRedirect extends AbstractConstraint * Assert that old Category URL lead to appropriate Category in frontend * * @param Category $category - * @param Browser $browser + * @param BrowserInterface $browser * @param Category $initialCategory * @return void */ - public function processAssert(Category $category, Browser $browser, Category $initialCategory) - { + public function processAssert( + Category $category, + BrowserInterface $browser, + Category $initialCategory + ) { $browser->open($_ENV['app_frontend_url'] . $initialCategory->getUrlKey() . '.html'); \PHPUnit_Framework_Assert::assertEquals( diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySaveMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySaveMessage.php index 37150e69985c4c98a3c07238c12d45911a9d36b1..95552645afe7e149e7ba2f9c366e1f558c961db3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategorySaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySuccessDeleteMessage.php index 898a92ea6d2b0c0f70b6d87dd065b9085d19c241..2f0348ef51d09b87ea04220c51ac93dda48fe21f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCategorySuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCategorySuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCrossSellsProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCrossSellsProductsSection.php index 7f785f4e19a22337783d39ac25f4e08c8b01a6ab..b6a8c8c559ffa911229abef13587bd3fe72e5b6f 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCrossSellsProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertCrossSellsProductsSection.php @@ -9,9 +9,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertCrossSellsProductsSection @@ -26,7 +26,7 @@ class AssertCrossSellsProductsSection extends AbstractConstraint /** * Assert that product is displayed in cross-sell section * - * @param Browser $browser + * @param BrowserInterface $browser * @param CheckoutCart $checkoutCart * @param CatalogProductSimple $product * @param CatalogProductView $catalogProductView @@ -34,7 +34,7 @@ class AssertCrossSellsProductsSection extends AbstractConstraint * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CheckoutCart $checkoutCart, CatalogProductSimple $product, CatalogProductView $catalogProductView, diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoCrossSellsProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoCrossSellsProductsSection.php index 794fe66e908c6a9ce9c83903bb89e28e579c54a7..9ba318c3a3f9fb95519fa954e0116ef48507dc5e 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoCrossSellsProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoCrossSellsProductsSection.php @@ -9,9 +9,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertNoCrossSellsProductsSection @@ -26,7 +26,7 @@ class AssertNoCrossSellsProductsSection extends AbstractConstraint /** * Assert that product is not displayed in cross-sell section * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @param InjectableFixture[] $relatedProducts * @param CatalogProductView $catalogProductView @@ -34,7 +34,7 @@ class AssertNoCrossSellsProductsSection extends AbstractConstraint * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product, array $relatedProducts, CatalogProductView $catalogProductView, diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoRelatedProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoRelatedProductsSection.php index d2edb61f6427fc75f2a15587a0fda7d81c8701dd..77dafc88946df4d8b4f4ac7f264c142faa8abdb5 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoRelatedProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoRelatedProductsSection.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertNoRelatedProductsSection @@ -25,14 +25,14 @@ class AssertNoRelatedProductsSection extends AbstractConstraint /** * Assert that product is not displayed in related products section * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @param InjectableFixture[] $relatedProducts * @param CatalogProductView $catalogProductView * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product, array $relatedProducts, CatalogProductView $catalogProductView diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoUpSellsProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoUpSellsProductsSection.php index e31e2eada172c616c92344f7b2f9517769f097f8..e2ec0224da538306a117d2b13f72d2a58e7daa8a 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoUpSellsProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertNoUpSellsProductsSection.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertNoUpSellsProductsSection @@ -25,14 +25,14 @@ class AssertNoUpSellsProductsSection extends AbstractConstraint /** * Assert that product is not displayed in up-sell section * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @param InjectableFixture[] $relatedProducts * @param CatalogProductView $catalogProductView * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product, array $relatedProducts, CatalogProductView $catalogProductView diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertPriceOnProductPageInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertPriceOnProductPageInterface.php index 391b2394ceb1cea61b568cebd94fed2791a49e86..e26cb9d0dfe20fc0bf7c37014a9d9379122a5fff 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertPriceOnProductPageInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertPriceOnProductPageInterface.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Block\Product\View; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Interface AssertPriceOnProductPageInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInGrid.php index f7d97ff7c1b7d3a03f1d2bd6eea404c2c1447f88..1091df6e8b2096bfd80258f64baff2395a2a650c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAbsenceProductAttributeInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInSearchOnProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInSearchOnProductForm.php index a0eb096a1b059c7f737a4926ead8c8a4fefc12ba..3cf4328573e0dcaafdda280c0ac4cc1ac4820391 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInSearchOnProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInSearchOnProductForm.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAbsenceInAddAttributeSearch diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInTemplateGroups.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInTemplateGroups.php index 7393939c7e7cbf1f8056acee99f6445f22ce2326..178bdd4078027dee27ca51c3a48d7d804e4172d1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInTemplateGroups.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInTemplateGroups.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeAbsenceInTemplateGroups diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInUnassignedAttributes.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInUnassignedAttributes.php index 517a00547faeb67f6dc9670751e3e8d8f00baa7f..7131b704c9ca6cb9c6c1b2a104c7ddecf2e3301b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInUnassignedAttributes.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeAbsenceInUnassignedAttributes.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeAbsenceInUnassignedAttributes diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnFrontend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnFrontend.php index 36f8fe1199d478139399d967dc121999bfd87a3e..a7f562305a04d26c50319014eb0b7a0964be8def 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnFrontend.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Driver\Selenium\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Check whether the attribute is visible on the frontend. @@ -27,14 +27,14 @@ class AssertProductAttributeDisplayingOnFrontend extends AbstractConstraint * @param InjectableFixture $product * @param CatalogProductAttribute $attribute * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( InjectableFixture $product, CatalogProductAttribute $attribute, CatalogProductView $catalogProductView, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnSearchForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnSearchForm.php index 4c1b3d5a125e43e772778ac6ce5ab1886ed57313..1d9a0a73cf089f38aa586a29cf051acee08cd8ce 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnSearchForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeDisplayingOnSearchForm.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\CatalogSearch\Test\Page\AdvancedSearch; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check whether attribute is displayed in the advanced search form on the frontend. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeInGrid.php index 5247acf20d0101a6ccaa5cededa7d6c415531b4b..4f76dc4d50d48565cc23d5c890e52037806c7e03 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsComparable.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsComparable.php index df9e49d9972b55afbf1614c0839b20d87d6a03c1..bc4a1c23c9e123193633f8e97da8fb5064fb12e1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsComparable.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsComparable.php @@ -9,9 +9,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Product\CatalogProductCompare; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Driver\Selenium\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Check whether there is an opportunity to compare products using given attribute. @@ -27,14 +27,14 @@ class AssertProductAttributeIsComparable extends AbstractConstraint * * @param InjectableFixture $product * @param CatalogProductAttribute $attribute - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param CatalogProductCompare $catalogProductCompare */ public function processAssert( InjectableFixture $product, CatalogProductAttribute $attribute, - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, CatalogProductCompare $catalogProductCompare ) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterable.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterable.php index 343dce13148e149a3546a53ed27dad7544a18738..bd3c2262147d1fd81f51b1a457cc789a7c90b5e4 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterable.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterable.php @@ -6,10 +6,10 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterableInSearch.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterableInSearch.php index fd0e4173327a4da0404cbf5978c3e96d180f3693..d43006c06f668986c2d7a6ea53c853794efff3db 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterableInSearch.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsFilterableInSearch.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Check out if the attribute in the navigation bar on the search results page in Layered navigation. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsGlobal.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsGlobal.php index 7db85843f974d7259a6273e28ea9cfd6904fafe9..486497d81c9c435426439b70eb302a5fe1b4adec 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsGlobal.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsGlobal.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Look on the scope of product attribute in the grid. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsHtmlAllowed.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsHtmlAllowed.php index 1b9ab866988fbfa012f43c239fe2ccd17339759d..33b93ac4f1effdfcbd18d99729eb92e1daefd7bb 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsHtmlAllowed.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsHtmlAllowed.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Driver\Selenium\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Check whether html tags are using in an attribute value. @@ -28,7 +28,7 @@ class AssertProductAttributeIsHtmlAllowed extends AbstractConstraint * @param InjectableFixture $product * @param CatalogProductAttribute $attribute * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @throws \Exception * @return void */ @@ -36,7 +36,7 @@ class AssertProductAttributeIsHtmlAllowed extends AbstractConstraint InjectableFixture $product, CatalogProductAttribute $attribute, CatalogProductView $catalogProductView, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsRequired.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsRequired.php index fcd98a85b6d3ee2ebbefc5086819b6f20d6d8366..d563b8966aa1c3fd1d41bca3f86ff3fea7764141 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsRequired.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsRequired.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Check whether the attribute is mandatory. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUnique.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUnique.php index 9d33cbdf8f9992605a401e2b2c0a065674090ac5..ca35c959794d9775f823ca133adcea15e930da1b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUnique.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUnique.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Check whether the attribute is unique. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedInSortOnFrontend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedInSortOnFrontend.php index 4af9bd95be936601c61fdea7c8f1da2384126083..73d9c93fdf2dc336c9509a6ef56c59aa164e4cde 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedInSortOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedInSortOnFrontend.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\CatalogSearch\Test\Page\CatalogsearchResult; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Assert that attribute present in sort dropdown on search results page on frontend. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedPromoRules.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedPromoRules.php index 3dca6021de3704a36dd7efeb103179aaa2e05452..cda2dbe885ccf547520a745fb38c9f9fefc78e61 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedPromoRules.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeIsUsedPromoRules.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeIsUsedPromoRules diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSaveMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSaveMessage.php index b6c11594ab6f798ffe90839e71b1c34df52851ae..f58f02ad1f4fe848237c37f4286a277123dabfbf 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSuccessDeleteMessage.php index ea2adf5025f7ae88df5f3060204b9464f8330306..60b68f622cb549aec8a3ecbb0f9772cc0e9a11d1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductAttributeSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSuccessDeletedAttribute diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareBlockOnCmsPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareBlockOnCmsPage.php index e7362c6e7255c84de480154e90983bb650df739c..5388bf823b46bbb61151164646e6c4238452483a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareBlockOnCmsPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareBlockOnCmsPage.php @@ -7,9 +7,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertProductCompareBlockOnCmsPage @@ -27,11 +27,15 @@ class AssertProductCompareBlockOnCmsPage extends AbstractConstraint * @param array $products * @param CmsIndex $cmsIndex * @param FixtureFactory $fixtureFactory - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(array $products, CmsIndex $cmsIndex, FixtureFactory $fixtureFactory, Browser $browser) - { + public function processAssert( + array $products, + CmsIndex $cmsIndex, + FixtureFactory $fixtureFactory, + BrowserInterface $browser + ) { $newCmsPage = $fixtureFactory->createByCode('cmsPage', ['dataSet' => '3_column_template']); $newCmsPage->persist(); $browser->open($_ENV['app_frontend_url'] . $newCmsPage->getIdentifier()); diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLink.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLink.php index d54776b16eea3263982c488efe7c8ef76579f83d..716bb8c00933c195aae9ce93ddc0568181d7f75a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLink.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLink.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductCompareItemsLink diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLinkIsAbsent.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLinkIsAbsent.php index 1deb79c236d7dbf0498a37772c0fdeae6acce5b8..3455b8dad453c53d35e9bad044a4b78728f8c783 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLinkIsAbsent.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareItemsLinkIsAbsent.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductCompareItemsLinkIsAbsent diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductComparePage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductComparePage.php index bd023344378c8d8a1f9e66e0dd44adb87a318ad4..c08c1850494e96d27341e2e5eddfbfbc1efee0ef 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductComparePage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductComparePage.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductCompare; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductComparePage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareRemoveLastProductMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareRemoveLastProductMessage.php index 3a6fb000b077eeb347569eafd4806bf4c8f9392b..0ede4a57e7b3638ccb496a372113fb21328db7b7 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareRemoveLastProductMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareRemoveLastProductMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductCompare; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductCompareRemoveLastProductMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessAddMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessAddMessage.php index 38875701b974ff83173ce4e872d1e84abc30dfc0..733c8b726597606c1a79be502085fb1eebafe0d7 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessAddMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessAddMessage.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductCompareSuccessAddMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveAllProductsMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveAllProductsMessage.php index 5f0f8266ff3d0d3a86c532d13b87162ca123ce04..4c878871b76740d909d4d3b8d46ab6bb3512cf8f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveAllProductsMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveAllProductsMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductCompareSuccessRemoveAllProductsMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveMessage.php index f78b2770a0425659eb21d826e060e43c23ca1b75..434daafcee86ed1944cf6147dd9a45f8e4b9aa00 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCompareSuccessRemoveMessage.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductCompare; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductCompareSuccessRemoveMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCustomOptionsOnProductPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCustomOptionsOnProductPage.php index 44303d263e78a3404bed6fc00aa6216a28bb3df3..7150626d7dcb9b47535fa5180916358774d67ea4 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCustomOptionsOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductCustomOptionsOnProductPage.php @@ -7,9 +7,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductCustomOptionsOnProductPage @@ -80,11 +80,14 @@ class AssertProductCustomOptionsOnProductPage extends AbstractAssertForm * * @param CatalogProductView $catalogProductView * @param FixtureInterface $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CatalogProductView $catalogProductView, FixtureInterface $product, Browser $browser) - { + public function processAssert( + CatalogProductView $catalogProductView, + FixtureInterface $product, + BrowserInterface $browser + ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); $actualPrice = null; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateForm.php index a26e9b5d4f3767f6e764940f5f40a83046b4d6a8..51da2a9c5d3f12877db54ed03600829c8acbcb74 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateForm.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert form data equals fixture data. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateIsNotDisplayingOnFrontend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateIsNotDisplayingOnFrontend.php index c27dcb389304c160e3989dc2e20178f0a2d29abe..89f7eaae399374329847ad25565a30ebc1547f01 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateIsNotDisplayingOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateIsNotDisplayingOnFrontend.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductDuplicateIsNotDisplayingOnFrontend diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateMessage.php index 3abcce7a6003df88406a448d2d5acb1e6b32bf68..837fb1ebdb26c10845171557630eadeba81fa681 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductDuplicateMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicatedInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicatedInGrid.php index 278786c42b5ed624f06fdfc369673f75ae85da51..4adca9c9b7bb9de7e1c8192461919b863d09ee20 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicatedInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductDuplicatedInGrid.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductDuplicatedInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductForm.php index efbdc1f4aa15298431915760038bb9ceca6860b6..e10767e1eb658b9a46686ab2de613957bb39853f 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductForm.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductGroupedPriceOnProductPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductGroupedPriceOnProductPage.php index 05e86b8e8dedc4f972a8533f3cf392d77335bd18..bfd4ea2306d84640cb05b1492ea750eb11887adf 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductGroupedPriceOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductGroupedPriceOnProductPage.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Block\Product\View; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductGroupedPriceOnProductPage @@ -40,11 +40,14 @@ class AssertProductGroupedPriceOnProductPage extends AbstractConstraint implemen * * @param CatalogProductView $catalogProductView * @param FixtureInterface $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CatalogProductView $catalogProductView, FixtureInterface $product, Browser $browser) - { + public function processAssert( + CatalogProductView $catalogProductView, + FixtureInterface $product, + BrowserInterface $browser + ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); //Process assertions diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCart.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCart.php index 6750c8cc4c5cd49f96834313f7ec2d8bd998bf98..c231814db8b4dd819aa71921a7fe72d12b470199 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCart.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCart.php @@ -9,9 +9,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductInCart @@ -28,14 +28,14 @@ class AssertProductInCart extends AbstractConstraint * * @param CatalogProductView $catalogProductView * @param FixtureInterface $product - * @param Browser $browser + * @param BrowserInterface $browser * @param CheckoutCart $checkoutCart * @return void */ public function processAssert( CatalogProductView $catalogProductView, FixtureInterface $product, - Browser $browser, + BrowserInterface $browser, CheckoutCart $checkoutCart ) { // Add product to cart diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCategory.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCategory.php index 63fcbcf80075b3ba42851c9838d3bdcb214e8789..ea20ef12903b25b6d5de16197fde477032f69ec8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCategory.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInCategory.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductInCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInGrid.php index 7f12ecab2f3a47f9cee00651f02890334230c382..b2a87f0ee3e5e9a28ddbc1aafbf8e499a07a4824 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInGrid.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInStock.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInStock.php index 15dec662a9a774d18c788925d882a1f912ee8bcf..b00dc4d171301fb86fbeab9358acee18a5eaded2 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInStock.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductInStock.php @@ -7,9 +7,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductInStock @@ -29,12 +29,15 @@ class AssertProductInStock extends AbstractConstraint * Assert that In Stock status is displayed on product page * * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureInterface $product * @return void */ - public function processAssert(CatalogProductView $catalogProductView, Browser $browser, FixtureInterface $product) - { + public function processAssert( + CatalogProductView $catalogProductView, + BrowserInterface $browser, + FixtureInterface $product + ) { // TODO fix initialization url for frontend page $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); \PHPUnit_Framework_Assert::assertEquals( diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotDisplayingOnFrontend.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotDisplayingOnFrontend.php index c4382c7be411bfa9ac1bafb12552897a2ca8133f..f53f723ebc2ee2229904eb6a0d0e893b9cf61b87 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotDisplayingOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotDisplayingOnFrontend.php @@ -11,9 +11,9 @@ use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\CatalogSearch\Test\Page\CatalogsearchResult; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductIsNotDisplayingOnFrontend @@ -60,7 +60,7 @@ class AssertProductIsNotDisplayingOnFrontend extends AbstractConstraint /** * Browser * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -79,7 +79,7 @@ class AssertProductIsNotDisplayingOnFrontend extends AbstractConstraint * @param CatalogCategoryView $catalogCategoryView * @param CmsIndex $cmsIndex * @param FixtureInterface|FixtureInterface[] $product - * @param Browser $browser + * @param BrowserInterface $browser * @param Category|null $category */ public function processAssert( @@ -88,7 +88,7 @@ class AssertProductIsNotDisplayingOnFrontend extends AbstractConstraint CatalogCategoryView $catalogCategoryView, CmsIndex $cmsIndex, $product, - Browser $browser, + BrowserInterface $browser, Category $category = null ) { $this->browser = $browser; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInCompareBlock.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInCompareBlock.php index 8785c154add925f67d746eab74790bf6350f2fe1..e0cd14a071e484fbc72f31415b39b55f9461aa7e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInCompareBlock.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInCompareBlock.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductIsNotVisibleInCompareBlock diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInComparePage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInComparePage.php index ddbba15320bfd5b720c40fec6fe119e4376c12ee..65205e252f79be15d59bd1578b7f4f56f91eac24 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInComparePage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductIsNotVisibleInComparePage.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductCompare; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductIsNotVisibleInComparePage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotInGrid.php index 342c61139676287ff077f3b20d165e0b0b0377b5..d973f1ae0bcddd641baa51d35306df2ae401bbbb 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotInGrid.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotSearchableBySku.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotSearchableBySku.php index e3963b136f130a1f243a0d788fa0d42846d543c2..bf5fe7db22701082126475a724ce582755e756f8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotSearchableBySku.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotSearchableBySku.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\CatalogSearch\Test\Page\CatalogsearchResult; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductNotSearchableBySku diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotVisibleInCategory.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotVisibleInCategory.php index a96967889aae6b05b962b4bb787638b6e971e8e8..cb885fcee6f3d46b47a64979e0fcae0f06147fd1 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotVisibleInCategory.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductNotVisibleInCategory.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductNotVisibleInCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductOutOfStock.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductOutOfStock.php index 3e978d962f43293bfb5ac76d98d2757583d495bc..9aeec7495e10bb1f7a561e7e02c7570de336fb44 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductOutOfStock.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductOutOfStock.php @@ -7,9 +7,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductOutOfStock @@ -29,12 +29,15 @@ class AssertProductOutOfStock extends AbstractConstraint * Assert that Out of Stock status is displayed on product page * * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureInterface $product * @return void */ - public function processAssert(CatalogProductView $catalogProductView, Browser $browser, FixtureInterface $product) - { + public function processAssert( + CatalogProductView $catalogProductView, + BrowserInterface $browser, + FixtureInterface $product + ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); \PHPUnit_Framework_Assert::assertEquals( self::STOCK_AVAILABILITY, diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductPage.php index dd9c77a6a8ac612d314db49b7cd48cbf0c3278e0..23e31de68caf9b5bf0ea3263bd82a8fa5c006cbc 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductPage.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductPage @@ -45,13 +45,16 @@ class AssertProductPage extends AbstractAssertForm * 5. Description * 6. Short Description * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param FixtureInterface $product * @return void */ - public function processAssert(Browser $browser, CatalogProductView $catalogProductView, FixtureInterface $product) - { + public function processAssert( + BrowserInterface $browser, + CatalogProductView $catalogProductView, + FixtureInterface $product + ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); $this->product = $product; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSaveMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSaveMessage.php index 2d2e0ff69f5b4841dc9a168fea6fcd10902717b2..7f972607e954b858c40973d39df825d9dce5a667 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSearchableBySku.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSearchableBySku.php index 118a0aedf71c71723c5a685d850858093d751a28..337aec58a57aad4aeebd121d61fa05e405ff6f3c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSearchableBySku.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSearchableBySku.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\CatalogSearch\Test\Page\CatalogsearchResult; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductSearchableBySku diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSkuAutoGenerated.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSkuAutoGenerated.php index 985b0e30d2307066b7eef90c50cfba96643e1836..cfeed99f470d0fec53e7271e857a47330a306e9d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSkuAutoGenerated.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSkuAutoGenerated.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductSkuAutoGenerated diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSpecialPriceOnProductPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSpecialPriceOnProductPage.php index 5425ac797955931d890952a6b4ce4b965b9fad2c..4a4df8f12a0c51a0889ebd3a7c0fde0a268a72be 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSpecialPriceOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSpecialPriceOnProductPage.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Block\Product\View; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert that displayed special price on product page equals passed from fixture. @@ -32,12 +32,15 @@ class AssertProductSpecialPriceOnProductPage extends AbstractConstraint implemen * Assert that displayed special price on product page equals passed from fixture * * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureInterface $product * @return void */ - public function processAssert(CatalogProductView $catalogProductView, Browser $browser, FixtureInterface $product) - { + public function processAssert( + CatalogProductView $catalogProductView, + BrowserInterface $browser, + FixtureInterface $product + ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); //Process assertions diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSuccessDeleteMessage.php index 408d2aea57d7d6fe6936535e9b178311f3b5658d..0be5aaf2f66e79736bd95bc8946d854d0c4193ab 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductSuccessDeleteMessage.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateForm.php index d5d4beaf5bad44e4238e7c1b7bf47e2b8b847efd..af751de70b60cc696534344711d1ef293b4feb49 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateForm.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductTemplateForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateGroupOnProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateGroupOnProductForm.php index 87d0c9105986e40c4a98906b4d5bd8ce82efbc9f..d207b3b1a3517253dc2e055ab2b92016316869be 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateGroupOnProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateGroupOnProductForm.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Constraint; -use Mtf\ObjectManager; -use Mtf\Fixture\FixtureFactory; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateInGrid.php index 1a616f41bc693b5b57b1085b4ef6a5f0da05b0e5..6c5f5a361f89e9f94b12de20aaa217511c81280e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductTemplateInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateNotInGrid.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateNotInGrid.php index 870fa371f979d95dc20351d31a80a85881240ef3..6169fe31598de123aae474096bae79fa584ccfab 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductTemplateNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateOnProductForm.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateOnProductForm.php index 378370a452436425f33cc2f27a1b927d195cae61..34dbf3c2914794a494276eb630b21b79acdc253b 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateOnProductForm.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateOnProductForm.php @@ -12,8 +12,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertProductTemplateOnProductForm diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessDeleteMessage.php index 1308b188bc02227a2e2cb1003deffc15935b09f2..8fe292c2423163f67a8067940a96320ea35a55bb 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductTemplateSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessSaveMessage.php index cc06f1cce7c3d51a5dae2bb9919cf893a66319a3..e19ff6274563410a4ab1f83e9a9deb419e02675b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTemplateSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductTemplateSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPage.php index d4acd06cab22213e3835917b69d727b89209b619..94702a94536d06599378ecdc9eb852cb52c26957 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductTierPriceOnProductPage.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Block\Product\View; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert that displayed tier price on product page equals passed from fixture. @@ -38,13 +38,13 @@ class AssertProductTierPriceOnProductPage extends AbstractConstraint implements /** * Assertion that tier prices are displayed correctly * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param FixtureInterface $product * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, FixtureInterface $product ) { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductView.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductView.php index 64ec170af0c26b2e2f722bd6d07a56a1e8564eec..52bfc9299be638851b14775a7fe7556a50ab346f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductView.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductView.php @@ -8,13 +8,11 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductView - * - * @package Magento\Catalog\Test\Constraint */ class AssertProductView extends AbstractConstraint { @@ -24,13 +22,13 @@ class AssertProductView extends AbstractConstraint /** * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @return void */ public function processAssert( CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product ) { //Open product view page diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductVisibleInCategory.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductVisibleInCategory.php index a58ede703595901123e09606e5adf22bcb7c6500..c8167af1480bf44bf031425fcb6c43aab7224f45 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductVisibleInCategory.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertProductVisibleInCategory.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductVisibleInCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertRelatedProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertRelatedProductsSection.php index c6070ec805612c46c0fdd86ec6175b0ddc2a2827..c2279cf6a7325723e29fa2a3a1b9eb401b5f22cc 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertRelatedProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertRelatedProductsSection.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertRelatedProductsSection @@ -25,14 +25,14 @@ class AssertRelatedProductsSection extends AbstractConstraint /** * Assert that product is displayed in related products section * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @param InjectableFixture[] $relatedProducts * @param CatalogProductView $catalogProductView * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product, array $relatedProducts, CatalogProductView $catalogProductView diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUpSellsProductsSection.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUpSellsProductsSection.php index ffb916a70b0513439dcb0b53fcedc9f95ed29391..0dae93dd6d207f8182c8fdb110ddaab03cffd567 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUpSellsProductsSection.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUpSellsProductsSection.php @@ -7,10 +7,10 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertUpSellsProductsSection @@ -25,14 +25,14 @@ class AssertUpSellsProductsSection extends AbstractConstraint /** * Assert that product is displayed in up-sell section * - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureInterface $product * @param InjectableFixture[] $relatedProducts, * @param CatalogProductView $catalogProductView * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, FixtureInterface $product, array $relatedProducts, CatalogProductView $catalogProductView diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUsedSuperAttributeImpossibleDeleteMessages.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUsedSuperAttributeImpossibleDeleteMessages.php index 133d2e28910ae183d985365515281a73347c7181..8bb9e4122149bc2d464237ad9ec24bdfeaf5c001 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUsedSuperAttributeImpossibleDeleteMessages.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Constraint/AssertUsedSuperAttributeImpossibleDeleteMessages.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUsedSuperAttributeImpossibilityDeleteMessages diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/AssignProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/AssignProducts.php index e1c04547aa337be2d35ab960b1bc9d24302ef3c4..47ba4a555e512c028ca969c15967671604081e12 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/AssignProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/AssignProducts.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\System\Config; class AssignProducts extends Product { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Cart/Item.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Cart/Item.php index 1d977962b2e6a9b57b4389ef01e4f4c23f9a8fbc..9e8d1996b13a22dda3e97df67182435f16caaf66 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Cart/Item.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Cart/Item.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Fixture\Cart; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet.php index 4a3c8f5da9ce7d55913e29ee6c1b69fa5e835c9c..21cf68bc8a85d21f6ffdf6f6812a1127cb20cc69 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CatalogAttributeSet diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/AssignedAttributes.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/AssignedAttributes.php index fe38371d7ab0e4a86f37b154fe4d2ff5e72868fc..3cab12364140258fe29475db5ca95c8c651c8109 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/AssignedAttributes.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/AssignedAttributes.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssignedAttributes diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/SkeletonSet.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/SkeletonSet.php index 4d70dd528ea8e9fceee1f73b1a25e70320923748..27f86800767f536908ea62c0a07b6d158469d4ee 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/SkeletonSet.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogAttributeSet/SkeletonSet.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class SkeletonSet diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute.php index db403b73608038373b39c85e28d59825efb9cca9..4d645477ec25da207433607e6ea83a4017955735 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CatalogAttributeEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute/Options.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute/Options.php index fce3250d3d7c793705984cc56c578fcdce7b1582..f05c63c30d733d50222ec830df0c9a2d788f090c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute/Options.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductAttribute/Options.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Options diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.php index 4c988324e04effde4da42dec520734cc4309212e..ffaa24098d39f1baa35d523eea93af8aa0c3a74a 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple.php @@ -6,12 +6,12 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\System\Config; -use Mtf\Handler\HandlerFactory; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\System\Config; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Class CatalogProductSimple diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AbstractRelatedProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AbstractRelatedProducts.php index 7d041eb90f1bbca29d0d78c4c4154ec65f55e768..b1ffd0322195e019c3efd2a08546a4a0d172ca30 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AbstractRelatedProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AbstractRelatedProducts.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AbstractRelatedProducts diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AttributeSetId.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AttributeSetId.php index 17faa3b5b062b9b828f2385a894c1033c48c6dbd..28b6e17750ad223d7af61835de5aa7faf8a4b58c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AttributeSetId.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/AttributeSetId.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AttributeSetId diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CategoryIds.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CategoryIds.php index 9453ec0828e7e3912c0cdf485db9081f6d4093d1..cf59c0bc7a19ceebdfe5f5467105e3db465f588a 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CategoryIds.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CategoryIds.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\Category; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class CategoryIds diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CheckoutData.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CheckoutData.php index ac5d179809542ee24f5d4ea4e6fd03e9a4ab2cb1..6cabd44b50ec6e5609ccf12d09f1fa4eb0056ae6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CheckoutData.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CheckoutData.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class CheckoutData diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomAttribute.php index 49d6a01d0c0c4c1d066679fb22557995c043a3f6..024e8bc7680694502a7f39ae8763803cafc34843 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomAttribute.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Source for attribute field. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomOptions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomOptions.php index 733a611b3cb224ca2d9a9e267881812e73625b7d..82d498b27c0346dc6cbce7ba70361a1a8ee81ddc 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomOptions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/CustomOptions.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class CustomOptions diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Fpt.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Fpt.php index 5e84f8822e591a5c45515feca5a7f6002e774d11..8d29bd7bd8bf13d7e76cd74e233d633f356c74c9 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Fpt.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Fpt.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Fpt diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/GroupPriceOptions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/GroupPriceOptions.php index 256bb41cb82cbf41e1c53067f5e3ce420dff02c3..ae26f43149b3066bdf054197fe2c08626be6b4cc 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/GroupPriceOptions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/GroupPriceOptions.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class GroupPriceOptions @@ -19,7 +19,7 @@ use Mtf\Fixture\FixtureInterface; class GroupPriceOptions implements FixtureInterface { /** - * @var \Mtf\Fixture\FixtureFactory + * @var \Magento\Mtf\Fixture\FixtureFactory */ protected $fixtureFactory; @@ -69,6 +69,8 @@ class GroupPriceOptions implements FixtureInterface } /** + * Get preset array + * * @param string $name * @return mixed|null */ diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Price.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Price.php index 9c68b4060f26d33f2ee43fefa0008c427c8beed4..470558b5d4d0ba8c8f8e26f410b894fea1ed6696 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Price.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/Price.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Price @@ -33,7 +33,7 @@ class Price implements FixtureInterface protected $params; /** - * @var \Mtf\Fixture\FixtureFactory + * @var \Magento\Mtf\Fixture\FixtureFactory */ protected $fixtureFactory; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TaxClass.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TaxClass.php index 0d5b1c9981aa1c22f54a59580b0f5271cf209778..bfec8539bb6b38b69a254a992b46bc5a9761d424 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TaxClass.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TaxClass.php @@ -7,12 +7,12 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Tax\Test\Fixture\TaxClass as FixtureTaxClass; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class TaxClass diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TierPriceOptions.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TierPriceOptions.php index 4dbc4be608dfbd41421b035708b4230bd94940c6..1d2c292ec6e6392fa304cf14697b10598df989a7 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TierPriceOptions.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductSimple/TierPriceOptions.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class TierPriceOptions diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductVirtual.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductVirtual.php index 997b81fbbda03dbc7f6816c438afde366def8d2d..c7102655fe9b4a61018c2cc1f135a61455305295 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductVirtual.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CatalogProductVirtual.php @@ -6,12 +6,12 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\HandlerFactory; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Config; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Config; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Class CatalogProductVirtual diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category.php index d27ae4c345b8158aac78de18e33de5c9750352ba..c159bb8f7398187223e6456a3eb7645250eec54e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CatalogCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/CategoryProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/CategoryProducts.php index c84d694e909cbf337ee23df9758c166c22530c7d..1230c6c96549b1afe27bd09808dbed64eec56270 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/CategoryProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/CategoryProducts.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\Fixture\Category; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class CategoryProducts diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/LandingPage.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/LandingPage.php index b8110cfe17445e65b07b1331ab3f81a35fc3673a..add0a7c40e1bcae69191eeeab91173c2d8e497f2 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/LandingPage.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/LandingPage.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\Category; use Magento\Cms\Test\Fixture\CmsBlock; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Prepare landing page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/ParentId.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/ParentId.php index 57c0c0e49ee6163b7352704b38326435e506167d..7075706983b99a89b14a29a36617d980df17ec62 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/ParentId.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Category/ParentId.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\Category; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class ParentId diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CrosssellProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CrosssellProducts.php index 9f8bfc8925444bfcdca7059601035281a116aed3..6314c21b52cf8f48e2fe4d1bbecefd1207a27b29 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CrosssellProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/CrosssellProducts.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Fixture; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Crosssell; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; class CrosssellProducts extends AssignProducts { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product.php index ba65b0bb50ca874e3808b959c394509f2da3e5be..ca49dbcb8743d913ae7bd93a6b60fafe3c26dd17 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/Product.php @@ -5,10 +5,10 @@ */ namespace Magento\Catalog\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; -use Mtf\ObjectManager; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\System\Config; class Product extends DataFixture { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/ProductAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/ProductAttribute.php index c69da4e83af86d7726472a1adfac1d33a09567cc..e0bcf99fe4058771c685d3a6ab15fb8170124f9f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/ProductAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/ProductAttribute.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class Attribute diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/SimpleProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/SimpleProduct.php index 43a32cb5864c130917db8ab868a84627406cd6c1..29ce1edf9252fba739e1da8d624f89a3a884d688 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/SimpleProduct.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/SimpleProduct.php @@ -5,8 +5,8 @@ */ namespace Magento\Catalog\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\System\Config; /** * Class SimpleProduct diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/VirtualProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/VirtualProduct.php index 35057a1f722657128f6a19cede105a1824634357..be101be7e2874fc3598eca60db9900adc834075f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/VirtualProduct.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Fixture/VirtualProduct.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Fixture; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; class VirtualProduct extends Product { diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/CatalogAttributeSetInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/CatalogAttributeSetInterface.php index fb00c52d4d9b4be4e4fee613daf8067ba1caabb9..da04410ef232c0fc24e9a4050662c71d5876c010 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/CatalogAttributeSetInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/CatalogAttributeSetInterface.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Handler\CatalogAttributeSet; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogCategoryEntityInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/Curl.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/Curl.php index 6e33e1ee8ac5de4114683eca784d47b267f59d18..869c7507cda01de635b16f22a3e646086d30b037 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogAttributeSet/Curl.php @@ -7,12 +7,12 @@ namespace Magento\Catalog\Test\Handler\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/CatalogProductAttributeInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/CatalogProductAttributeInterface.php index 1a5221e0501e857d59e0deef9a23a3ab79e5206d..de29b27f9458c6fa6e8836f8fd2204085cac071c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/CatalogProductAttributeInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/CatalogProductAttributeInterface.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Handler\CatalogProductAttribute; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogCategoryEntityInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/Curl.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/Curl.php index 9d3652fe978811fc7089f5ab37fa1975778e85e1..fb0e7437711b58072d333f864432e446f0f0653d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductAttribute/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Catalog\Test\Handler\CatalogProductAttribute; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/CatalogProductSimpleInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/CatalogProductSimpleInterface.php index f4df1f9289680083d46d5655a31a8263f1351ff8..f705cfd88f2542c631147ae73ad638d21ea77ebf 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/CatalogProductSimpleInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/CatalogProductSimpleInterface.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Handler\CatalogProductSimple; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogProductSimpleInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Curl.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Curl.php index 0f7a8b1dd6b25ea64caf6f69879dd2671795bcb3..c6ee44d2d0c533b3bd462e1a95da6ec93a8e6560 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Catalog\Test\Handler\CatalogProductSimple; -use Mtf\System\Config; -use Mtf\Fixture\FixtureInterface; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\System\Config; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Create new simple product via curl. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Ui.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Ui.php index e3b8421cc3ed15d1208877be2f1d92b5509cb483..1e3631bc057ca280944ccd063e34d39419a06296 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Ui.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductSimple/Ui.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Handler\CatalogProductSimple; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Ui as AbstractUi; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Ui as AbstractUi; /** * Class CreateProduct diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductVirtual/CatalogProductVirtualInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductVirtual/CatalogProductVirtualInterface.php index 67a4bf6cfff78baf34d88e620ac344a0d7aa2da6..d9cc8dff4dfd99e19f6a9ac9868579e6faad503c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductVirtual/CatalogProductVirtualInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/CatalogProductVirtual/CatalogProductVirtualInterface.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Handler\CatalogProductVirtual; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogProductVirtualInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/CategoryInterface.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/CategoryInterface.php index adfdcb62c0a74ae441e83f7c884bc7b62470ae9e..d63688100a2f6024e9c3bb9abc461a44f81b4010 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/CategoryInterface.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/CategoryInterface.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Handler\Category; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CategoryInterface diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/Curl.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/Curl.php index 030d3bbae3b838146a98cbe5ab103d4df0f61a17..0e8c6e7fd420731794c380ba4bbc9f141827ae89 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Category/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Catalog\Test\Handler\Category; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProduct.php index 6f3040413d8b2828a14ba6b59bbede44ace2758f..1205d69fa11a7dcb6717de0dc14256aa62b8c8b4 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProduct.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProduct.php @@ -7,13 +7,13 @@ namespace Magento\Catalog\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class CreateProduct diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProductAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProductAttribute.php index f2873e71543a4324bcfc5dd814f5bfa3bbda963b..18a8f3598f0dc6e51c80d7a03a32620833e9a317 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProductAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Curl/CreateProductAttribute.php @@ -8,12 +8,12 @@ namespace Magento\Catalog\Test\Handler\Curl; use Magento\Catalog\Test\Fixture\ProductAttribute; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class CreateProductAttribute diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Ui/CreateProduct.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Ui/CreateProduct.php index 1533bae18f6a5ba3d3a3731bc34b91e13df0a4c6..acabe4b5e64f481a8621d91187b3598e0e769b7f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Ui/CreateProduct.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Handler/Ui/CreateProduct.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Handler\Ui; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Ui; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Ui; /** * Class CreateProduct diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategory.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategory.php index 85b7c74d02e426948ef12dd8f4b99ca90fafcc48..43666299a1ab36c41ed8a986498c032cb0de8859 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategory.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategory.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Page\Category; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class CatalogCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategoryEdit.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategoryEdit.php index a8ee76b6665eefa6e64cc7185cad62019dbc7915..f7bcf562cd9a529a41ec6dece9afaa3732654f76 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategoryEdit.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Category/CatalogCategoryEdit.php @@ -7,9 +7,9 @@ namespace Magento\Catalog\Test\Page\Category; use Magento\Backend\Test\Block\FormPageActions; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class CatalogCategoryEdit diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Product/CatalogProductActionAttributeEdit.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Product/CatalogProductActionAttributeEdit.php index dc40f0d8e28c4c050bc7071b152fdba24862b487..96ffb35c54577179c009d9efe371eb6368fd6700 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Product/CatalogProductActionAttributeEdit.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Page/Product/CatalogProductActionAttributeEdit.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\Page\Product; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class CatalogProductActionAttributeEdit diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/AssignProducts.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/AssignProducts.php index cfe500f811cb3bbac30ca0fb4e1b6a4dc0e203e4..9d31fe311d9f3921cd904b4221fdf1c77450606c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/AssignProducts.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/AssignProducts.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Product Repository diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogAttributeSet.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogAttributeSet.php index 87da5eb4b6f4b6bbda088e34eddf89a3a0c0ff26..1bba2984d00560d84daa61fcf4c9d548d13eae6b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogAttributeSet.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogAttributeSet.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogProductTemplate diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductAttribute.php index fc5aacdd8e4f3703ae7808336be7a9ce36f6dba0..0c2747857573b4d4703f21345cad1e4fa5d00bf5 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductAttribute.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogProductAttribute diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductSimple.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductSimple.php index 43ee2aadb8f46eb0e2e764da540f0d8da4018e57..de287058e44a5b1d3d7889dc07624aa787eb3464 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductSimple.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductSimple.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Data for creation Catalog Product Simple. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductVirtual.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductVirtual.php index fd43d3c3aa3c8a0a24bb36e94d47bf4289560c7e..d62d7b3ddb5aa433dcfb2b39dfe3dcefad1be7de 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductVirtual.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/CatalogProductVirtual.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogProductVirtual diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Category.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Category.php index ecb9febd09a028a3876349d480620d0163bdb7be..61b458e067e50467545ee51b64a9f2c9945cc32a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Category.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Category.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogCategory diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product.php index 7e83c80ef2015ccd2266384a3752bef27ffa83a3..4c9b8591ac0165fc4fb650583516c6d02405ffe6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/Product.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\Repository; use Magento\Catalog\Test\Fixture; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Product Repository diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/ProductAttribute.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/ProductAttribute.php index 500c30275b08effd58294ac79e6d1bf6ff41532d..607a80eea4e09c3a8585952309f7264d1aa0ab63 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/ProductAttribute.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/Repository/ProductAttribute.php @@ -6,7 +6,7 @@ namespace Magento\Catalog\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Product Attribute Repository diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.php index 232fd29cfc8ca8f7e8b584cddc5ddcb8ec1c820a..ed8172c2fe9aec8101f659fc9b62255c7beb4c57 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/CreateCategoryEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestCase\Category; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateCategoryEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/DeleteCategoryEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/DeleteCategoryEntityTest.php index 4148746b6e2c7dd0f362f30b7e92d49368a15e28..85496befeb3a330d1f42756ff6ab4faa830acdef 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/DeleteCategoryEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/DeleteCategoryEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestCase\Category; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteCategoryEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/UpdateCategoryEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/UpdateCategoryEntityTest.php index 8362d31c4fb4b0b0812909c4ee83906acb0a45bb..7b43b0189048d7e4a46ea540b10f0cd111809d72 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/UpdateCategoryEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Category/UpdateCategoryEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestCase\Category; use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogCategoryIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateCategoryEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractAddRelatedProductsEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractAddRelatedProductsEntityTest.php index 6865d2fad806209ac27e876932a44484fd0550e5..c0200a2ccb2a6773d15e45d75116b0316bd8e412 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractAddRelatedProductsEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractAddRelatedProductsEntityTest.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\TestCase\Injectable; /** * Class AbstractAddRelatedProductsEntityTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractCompareProductsTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractCompareProductsTest.php index 4fc5578dc456e7a3c583c76e575285d87e6367b0..b8bcce9c6c744a0e7981e26493ace658e3dd72a9 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractCompareProductsTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/AbstractCompareProductsTest.php @@ -11,11 +11,11 @@ use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountLogin; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\TestCase\Injectable; /** * Abstract class for compare products class. @@ -41,7 +41,7 @@ abstract class AbstractCompareProductsTest extends Injectable /** * Browser. * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -99,14 +99,14 @@ abstract class AbstractCompareProductsTest extends Injectable * * @param CmsIndex $cmsIndex * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param CustomerAccountLogin $customerAccountLogin * @return void */ public function __inject( CmsIndex $cmsIndex, CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, CustomerAccountLogin $customerAccountLogin ) { $this->cmsIndex = $cmsIndex; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateProductTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateProductTest.php index 209fb3f589ca64e82a2b810b19f612c2318164cb..251ff8c60d3c5c455c8b6a7de51b649f6cc62ff6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateProductTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateProductTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\SimpleProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateProductTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.php index 19bb0fa8f7b7680f7eadd268f79b5763ec300c41..02044246737b11def87d8f48b06884e10a9b530d 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleProductEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateSimpleProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCategoryTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCategoryTest.php index bef726b3adb837e566ad44bdad1d4b29c1a20a86..01f3fecddcaa5c606a7309b25ebf200c27f7dc36 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCategoryTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCategoryTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\SimpleProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateSimpleWithCategoryTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCustomOptionsAndCategoryTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCustomOptionsAndCategoryTest.php index 9cc4424bf05d4eb69ce3a46e41b9324de975d3c8..1f6c1e41b6ffb48ec3f605e4065a4cab3ad00855 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCustomOptionsAndCategoryTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateSimpleWithCustomOptionsAndCategoryTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateSimpleWithCustomOptionsAndCategoryTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateTest.php index 5eba66335092deb81db91270c38903f89267a628..b168b568d242026fc0b4ae7d1ccc39cc72fa899c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\SimpleProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.php index c3662e3f685d9a68fa0ec215dd397c3d4280ca4f..b7e1955b146b5c24e9352f18b09f542078e14b58 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualProductEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\CatalogProductVirtual; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateVirtualProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualTest.php index 473a7a2599ae167d81d7c923150be5ffa60c2fcd..7e966ab4371dd040ad09d17b12a1a7c1c31d6af6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CreateVirtualTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\VirtualProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CrosssellTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CrosssellTest.php index 0a454ded8bccb06bc2a51515d0065a16af29ed0d..2f71f814a2ac3147f8e3036edeff71f42cbf0540 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CrosssellTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/CrosssellTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CrosssellTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/EditSimpleProductTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/EditSimpleProductTest.php index b03a0cf4e53bd729a48e66079961fd7cdcfd6aac..75898fccf9a975810410b55fbab83354f9e426a6 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/EditSimpleProductTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/EditSimpleProductTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\SimpleProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Edit products diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.php index 9b35f9081b3d9dce08beaed7a7b68b198c53ad3d..1cdff9dbf0ed156e55ea0d5bbc657f7628f7e02d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnCreationTest.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ProductTypeSwitchingOnCreation diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php index c1b821dedefc439a15c28e204a2ef7ccc270189b..7448eb5eb32818475cdf0dad72b76306af6a9048 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/ProductTypeSwitchingOnUpdateTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config; use Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ProductTypeSwitchingOnUpdating diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/RelatedProductTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/RelatedProductTest.php index 448e534fdab4046657878953020a29113798d018..2dce365a7bcfa61fc268ede139217b4f90b677f5 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/RelatedProductTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/RelatedProductTest.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Related; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class RelatedProductTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UnassignCategoryTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UnassignCategoryTest.php index 69ca4b005decbb389f24876974686bb6a36be4cd..bf024a2a2a4b9c649e127c7c0498b9542a8503c8 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UnassignCategoryTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UnassignCategoryTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class UnassignCategoryTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.php index 248bd5a6a712ccf2ff6c7500fb361b1bfa61435e..33125f9bdffa3d735b8180e65108966a996380e0 100755 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateSimpleProductEntityTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateProductSimpleEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php index f3bfd46975fd77e31e4a3e8a9ca212d4c211e7b8..0868765d7b590ed722dcbf6cb943b594df8ce68a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpdateVirtualProductEntityTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Fixture\CatalogProductVirtual; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateVirtualProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpsellTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpsellTest.php index b8e7bb4e70b4b1e69cd5cd7c1815dc7b26797ac3..23d3a2a581361685e00e55dc66d45ae2bc33fdc3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpsellTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/Product/UpsellTest.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\TestCase\Product; use Magento\Catalog\Test\Block\Adminhtml\Product\Edit\Tab\Upsell; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class UpsellTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.php index aca4fb8a4fc5a31de0459b8cfbaed9ad8a26122b..7ddb966ed99a38aed91201c7cb802a182f26d2b3 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateAttributeSetEntityTest.php @@ -11,7 +11,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetAdd; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateAttributeSetEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityFromProductPageTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityFromProductPageTest.php index 0dfee0e266d3da56efcafb11ce9d40ff64350ae6..d17441b09b1fce6815ac4fa4f70771fa8918b335 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityFromProductPageTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityFromProductPageTest.php @@ -8,9 +8,9 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureFactory; -use Mtf\ObjectManager; -use Mtf\TestCase\Scenario; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Scenario; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.php index c863602bbcdafa43834fdf311cf76fc758fb4b29..aa04e94af83eb8ef90a1c381fec6231479fe15ce 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/CreateProductAttributeEntityTest.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\ObjectManager; -use Mtf\TestCase\Scenario; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Scenario; /** * Test Creation for CreateProductAttributeEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAssignedToTemplateProductAttributeTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAssignedToTemplateProductAttributeTest.php index ef01e486b83364f32b474a9802aaa7dffecca5f0..5a717e86f09e5b88e9d815fcf1376a11d6d18914 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAssignedToTemplateProductAttributeTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAssignedToTemplateProductAttributeTest.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete Attribute Set (Product Template) diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.php index 86b4b2db53f6747ed8afb5ee525dccc35ae1bb57..5e88db04c3ca11e84164274eddcee87cd8d0e789 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteAttributeSetTest.php @@ -9,8 +9,8 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete Attribute Set (Product Template) diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.php index 0375978ad724d64a69b4bf80c8e59df0fd5c0d9b..7303aaf305c9708988254098508e4eba3ebc58a0 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteProductAttributeEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateProductAttributeEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteSystemProductAttributeTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteSystemProductAttributeTest.php index ccb1ccadf1b6d231301ab8109d08ae5c933e423f..5bf2a74ee1e93d2db12999e18d9e8743c6dabe5f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteSystemProductAttributeTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteSystemProductAttributeTest.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\TestCase\ProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Cover DeleteSystemProductAttribute with functional tests designed for automation diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteUsedInConfigurableProductAttributeTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteUsedInConfigurableProductAttributeTest.php index 7437d0e488df961761f7f2053b8cf43e83e6554a..9485ebe8e0841755111898351c5b0d8fb3fb8f93 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteUsedInConfigurableProductAttributeTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/DeleteUsedInConfigurableProductAttributeTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete Used in Configurable ProductAttribute diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.php index dc1e25e7703f551d871355d400100602a43d1789..0939c76aadbe4c131169f2cbb7bed5ffc2d95a65 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateAttributeSetTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateAttributeSetTest diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.php index a8f77b33c44a2922e625ecbd8547ff32def3314d..b9e8ed962b3f0f1fd0e3e94ebe5d3b44d8f8726c 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestCase/ProductAttribute/UpdateProductAttributeEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateProductAttributeEntity diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddAttributeToProductTemplateStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddAttributeToProductTemplateStep.php index 2224e63068c1cfe785d57c443c79b85a791fdbd1..ef52d2a94f01577856eab8de4218e28c68bb6520 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddAttributeToProductTemplateStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddAttributeToProductTemplateStep.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestStep\TestStepInterface; /** * Move attribute To attribute set. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeFromProductPageStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeFromProductPageStep.php index 5c220ce185db9719130bc497942a8314d454e32e..58d29f12e4d67eedbaf2ebfc01549fd8b2a2a95d 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeFromProductPageStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeFromProductPageStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Add custom attribute to product from product page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeStep.php index 84d3f05f7adec5cc2697e0b536fbf129e21eddd0..4b446c35fabfa27b399bf7ceda19e67d0e7f59b7 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/AddNewAttributeStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Add New Attribute from Attribute index page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductStep.php index 299dc6d37bf276cf3ddce9a8999994ec7709d22d..28bc0fc4eb20698a7b8f0a4f90209be03f9cea48 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductStep.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\TestStep; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Create product using handler. @@ -55,7 +55,6 @@ class CreateProductStep implements TestStepInterface if ($product->hasData('id') === false) { $product->persist(); } - - return ['product' => $product]; + return ['product' => $product]; } } diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductTemplateStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductTemplateStep.php index 7464f5c1d19b9218370833e91055ffa89586fc5b..e8b106042af164484fbc0f73c6ad92deba48eafc 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductTemplateStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductTemplateStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Create product attribute template using handler. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductsStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductsStep.php index 914c92bd68d082288e22ea28523fef7f1244664c..74adfb27e1075d828970ffbc81df67f9dffe087e 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductsStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/CreateProductsStep.php @@ -6,9 +6,9 @@ namespace Magento\Catalog\Test\TestStep; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class CreateProductsStep diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/DeleteAttributeStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/DeleteAttributeStep.php index b485cf5956b5936b91127cdc1caa2e6e1cd338f0..0c028ca6a4802f79f8efc2d5eb2c7cd040086758 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/DeleteAttributeStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/DeleteAttributeStep.php @@ -9,7 +9,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Delete product attribute. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormOnProductPageStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormOnProductPageStep.php index 63b6c188f1a9677427c6afdef9ac2f110b9882a2..2d867c8aaa5d114d958081f59ec7e5808dd7ad73 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormOnProductPageStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormOnProductPageStep.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Fill custom attribute form on product page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormStep.php index b00e58a291fb366adeb93894f057302b202a9440..265871d80b6dc1cc52d25a2306778988fe06c2a1 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/FillAttributeFormStep.php @@ -8,7 +8,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Fill attribute form on attribute page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductAttributesPageStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductAttributesPageStep.php index a357b802340b2a68281654a6803f25b09c3e7624..39f35eef6a528ddf8c0b8fb5a95a24a0b4d89f4b 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductAttributesPageStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductAttributesPageStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Open Product Attribute Index Page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductOnBackendStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductOnBackendStep.php index 99cacb3269eeed8da9637bb8191c1f25e1821327..d6f6f73cd5b5bf924223a1f7bdabdd550e371b3f 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductOnBackendStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductOnBackendStep.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\InjectableFixture; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\TestStep\TestStepInterface; /** * Open product on backend. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductsOnFrontendStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductsOnFrontendStep.php index 8be5acf25e0492728e2c867fb8c7f8cb80a67be6..cae7f71355dac55e11b51f7a4b842d38829853bc 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductsOnFrontendStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/OpenProductsOnFrontendStep.php @@ -6,8 +6,8 @@ namespace Magento\Catalog\Test\TestStep; -use Mtf\Client\Browser; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Open products on frontend via url. @@ -24,7 +24,7 @@ class OpenProductsOnFrontendStep implements TestStepInterface /** * Browser. * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -33,9 +33,9 @@ class OpenProductsOnFrontendStep implements TestStepInterface * * @constructor * @param array $products - * @param Browser $browser + * @param BrowserInterface $browser */ - public function __construct(array $products, Browser $browser) + public function __construct(array $products, BrowserInterface $browser) { $this->products = $products; $this->browser = $browser; diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeOnProductPageStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeOnProductPageStep.php index 5cccb4c6a340cb8e6b5b84855ebb47adccded100..38d6ebdf1b59da446da19ab4b4ac4d083e3f6aa9 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeOnProductPageStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeOnProductPageStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Click "Save" button on attribute form on product page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeStep.php index 60b9acf32ac9d4e7122a0ccee11b50f016b95940..0651b72bc377fa796d0bf16a66e806237f45c105 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveAttributeStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductAttributeNew; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Save attribute on attribute page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductStep.php index d592470490cd7380c930eef9d73636b04bc59cd1..9d1e5d899686bb23387b1f0cbf08f9156582ff48 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductStep.php @@ -7,8 +7,8 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\Fixture\InjectableFixture; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\TestStep\TestStepInterface; /** * Save product step. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductTemplateStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductTemplateStep.php index 09f466651040e94623c518b356431378758f0737..759f036f3f818a5e024b9ae80253c4d0895737eb 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductTemplateStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SaveProductTemplateStep.php @@ -7,7 +7,7 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Save attributeSet on attribute set page. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SetDefaultAttributeValueStep.php b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SetDefaultAttributeValueStep.php index 1f1c6a2b71bcb0ad5914a3b0ce6d1f7fd865ebaa..7ab1e215e9c16093e06160a2e1532763120de18a 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SetDefaultAttributeValueStep.php +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/TestStep/SetDefaultAttributeValueStep.php @@ -8,8 +8,8 @@ namespace Magento\Catalog\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestStep\TestStepInterface; /** * Set default attribute value. diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/constraint.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/constraint.xml index 07d18daff56793e2cdd7bd2dbc7b65abcf886065..9ad414f26cb118f39e76886717e9c656a9767a81 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/constraint.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/constraint.xml @@ -10,7 +10,7 @@ <severity>high</severity> <require> <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductInGrid> <assertProductSaveMessage module="Magento_Catalog"> @@ -23,14 +23,14 @@ <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductOutOfStock> <assertProductInStock module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductInStock> <assertProductVisibleInCategory module="Magento_Catalog"> @@ -39,7 +39,7 @@ <catalogCategoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> <category class="Magento\Catalog\Test\Fixture\Category" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductVisibleInCategory> <assertProductNotVisibleInCategory module="Magento_Catalog"> @@ -48,7 +48,7 @@ <catalogCategoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> <category class="Magento\Catalog\Test\Fixture\Category" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductNotVisibleInCategory> <assertProductSearchableBySku module="Magento_Catalog"> @@ -56,7 +56,7 @@ <require> <catalogSearchResult class="Magento\CatalogSearch\Test\Page\CatalogsearchResult" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductSearchableBySku> <assertProductInCategory module="Magento_Catalog"> @@ -64,7 +64,7 @@ <require> <catalogCategoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> <category class="Magento\Catalog\Test\Fixture\Category" /> </require> </assertProductInCategory> @@ -72,7 +72,7 @@ <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> <checkoutCart class="Magento\Checkout\Test\Page\CheckoutCart" /> </require> </assertProductInCart> @@ -80,42 +80,42 @@ <severity>middle</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductPage> <assertProductGroupedPriceOnProductPage module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductGroupedPriceOnProductPage> <assertProductSpecialPriceOnProductPage module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductSpecialPriceOnProductPage> <assertProductTierPriceOnProductPage module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductTierPriceOnProductPage> <assertProductCustomOptionsOnProductPage module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductCustomOptionsOnProductPage> <assertProductForm module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductForm> <assertAddToCartButtonAbsent module="Magento_Catalog"> @@ -129,7 +129,7 @@ <require> <catalogCategoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> <category class="Magento\Catalog\Test\Fixture\Category" /> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> <catalogSearchResult class="Magento\CatalogSearch\Test\Page\CatalogsearchResult" /> @@ -139,14 +139,14 @@ <severity>low</severity> <require> <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductSkuAutoGenerated> <assertProductGroupedPriceOnProductPage module="Magento_Catalog"> <severity>low</severity> <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertProductGroupedPriceOnProductPage> <assertProductAttributeSaveMessage module="Magento_Catalog"> @@ -171,7 +171,7 @@ <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> <productSetEdit class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetEdit" /> <productSet class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductSetIndex" /> - <fixtureFactory class="Mtf\Fixture\FixtureFactory" /> + <fixtureFactory class="Magento\Mtf\Fixture\FixtureFactory" /> </require> </assertAddedProductAttributeOnProductForm> <assertProductAttributeIsRequired module="Magento_Catalog"> @@ -289,7 +289,7 @@ <assertCategoryAbsenceOnFrontend module="Magento_Catalog"> <severity>low</severity> <require> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> <categoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView" /> <category class="Magento\Catalog\Test\Fixture\Category" /> </require> @@ -326,7 +326,7 @@ <assertProductTemplateOnProductForm module="Magento_Catalog"> <severity>high</severity> <require> - <fixtureFactory class="Mtf\Fixture\FixtureFactory" /> + <fixtureFactory class="Magento\Mtf\Fixture\FixtureFactory" /> <attributeSet class="Magento\Catalog\Test\Fixture\CatalogAttributeSet" /> <productEdit class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit" /> <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> @@ -394,7 +394,7 @@ <assertProductDuplicatedInGrid module="Magento_Catalog"> <severity>low</severity> <require> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> </require> </assertProductDuplicatedInGrid> diff --git a/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/scenario.xml index 34945296329446a75a68357b60f381cbd8514909..fadb2635416f42381372ceccab06118447115b80 100644 --- a/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/Catalog/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="CreateProductAttributeEntityFromProductPageTest" module="Magento_Catalog"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog.php index 8c8c18e6039b4e169076cd68a83c02023ab40b70..e667956e1f8867e4f94faad6e9962feb634c7b7a 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog.php @@ -6,9 +6,9 @@ namespace Magento\CatalogRule\Test\Block\Adminhtml\Promo; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; /** * Backend catalog price rule grid. @@ -61,7 +61,7 @@ class Catalog extends Grid * Return row with given catalog price rule name. * * @param string $ruleName - * @return Element + * @return SimpleElement */ public function getGridRow($ruleName) { diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/PromoForm.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/PromoForm.php index 143227ba2c967a00c959b381f010ce4c338480bc..ed6797e5656997827bc7dda19f5dcd1af66874cd 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/PromoForm.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/PromoForm.php @@ -7,8 +7,9 @@ namespace Magento\CatalogRule\Test\Block\Adminhtml\Promo\Catalog\Edit; use Magento\Backend\Test\Block\Widget\FormTabs; -use Mtf\Client\Element; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class PromoForm @@ -20,11 +21,11 @@ class PromoForm extends FormTabs * Fill form with tabs * * @param FixtureInterface $fixture - * @param Element $element + * @param SimpleElement $element * @param array $replace * @return $this|FormTabs */ - public function fill(FixtureInterface $fixture, Element $element = null, array $replace = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null, array $replace = null) { $tabs = $this->getFieldsByTabs($fixture); if ($replace) { diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/Tab/Conditions.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/Tab/Conditions.php index 3d4cc6d56726cdc26730562d91e5f6d1aa6ae402..2ad3ea93baad5a58d2bac8b5abe954c3e26c6046 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/Tab/Conditions.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Adminhtml/Promo/Catalog/Edit/Tab/Conditions.php @@ -6,9 +6,9 @@ namespace Magento\CatalogRule\Test\Block\Adminhtml\Promo\Catalog\Edit\Tab; +use Magento\Mtf\Factory\Factory; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Factory\Factory; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Conditions @@ -28,10 +28,10 @@ class Conditions extends Tab * Fill condition options * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return void */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $data = $this->dataMapping($fields); diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Conditions.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Conditions.php index 6bc6032c2c407400f53cb2d497e1865977a6986f..a66e4e04959b60d95b2da5156842a7fe3fbd9b36 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Conditions.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Block/Conditions.php @@ -5,8 +5,8 @@ */ namespace Magento\CatalogRule\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Conditions diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedCatalogPage.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedCatalogPage.php index 7de205897b22e31782387ef60837455959b23902..7b5c27f818e076576269bc132900d85e30849baa 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedCatalogPage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedCatalogPage.php @@ -9,7 +9,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleAppliedCatalogPage diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedProductPage.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedProductPage.php index f5cf729f3b3836fb9458f2165ebaefd86a3ed92b..fb49621cc044cc1fbdcdc978cb5b20430ac5ab90 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedProductPage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedProductPage.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleAppliedProductPage diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedShoppingCart.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedShoppingCart.php index 3ff64a39e77bb871a70b694b8459565788c21d22..e1a3b8bccf34d058010bb54f1633164b42403de1 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleAppliedShoppingCart.php @@ -11,7 +11,7 @@ use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleAppliedShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleForm.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleForm.php index 1247ca4e175bb0b79aab785f52a236eeff209b79..5fc6a6d7bb73487dc826bfb80cb0a21cdb89e18f 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleForm.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleForm.php @@ -9,7 +9,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Fixture\CatalogRule; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleForm diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleInGrid.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleInGrid.php index bf157e0a4bc6f9109a132ccbc17dd464e39a0747..88ffb1308f2b4aa8c7e5aea4d2240c6391b1c188 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleInGrid.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleInGrid.php @@ -8,7 +8,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Fixture\CatalogRule; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleInGrid diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNotInGrid.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNotInGrid.php index 0a8c3522d38792fbdc447d72fe06a60c5aec85f6..c38cab63849357632c624c3a6d0ac7336c2f0629 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Fixture\CatalogRule; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNoticeMessage.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNoticeMessage.php index 0c1e8c41d7ed7444d268babb22b4a1a490880a78..8106e0062b1edef06a431bbc0ee66186d58af4bb 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNoticeMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleNoticeMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleNoticeMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessDeleteMessage.php index da703e0b1e6f15935aba738054043493d07aa94f..30729236399d7e4781cd101599a894dc4251c9a6 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessSaveMessage.php index 46fa4556486e017db7cb6278764ea8c26d4bde8b..95e32ec3bd7e04a2c219f715bbc803c11c7dbd1a 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Constraint/AssertCatalogPriceRuleSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogRule\Test\Constraint; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCatalogPriceRuleSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogPriceRule.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogPriceRule.php index d14ef23b1bfd00f81aeee848c75386f07575bd77..ff33ac103f3b04906254cafb8c32cc7ba888897d 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogPriceRule.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogPriceRule.php @@ -7,8 +7,8 @@ namespace Magento\CatalogRule\Test\Fixture; use Magento\CatalogRule\Test\Repository\CatalogPriceRule as Repository; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class CatalogPriceRule diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule.php index 910c5a91f0bedc0a8108eb4e1dc49f276efe2647..087f07330c5c8f64492e3882035e83e353617275 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule.php @@ -6,7 +6,7 @@ namespace Magento\CatalogRule\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CatalogRule diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule/Conditions.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule/Conditions.php index 714f7069486cb9a3d919975c95b98ab99d6b2aac..548477e346f9a2c75ac305ce9a912ef7c8409cd5 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule/Conditions.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/CatalogRule/Conditions.php @@ -6,8 +6,8 @@ namespace Magento\CatalogRule\Test\Fixture\CatalogRule; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Conditions @@ -23,7 +23,7 @@ class Conditions implements FixtureInterface protected $data = []; /** - * @var \Mtf\Fixture\FixtureFactory + * @var \Magento\Mtf\Fixture\FixtureFactory */ protected $fixtureFactory; diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Conditions.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Conditions.php index 9b66a1bdd3be052aa1c3d5156cf815e23c772d12..10b7388a42aaf1e2badf0f77d18ca735fd31a304 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Conditions.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Conditions.php @@ -8,8 +8,8 @@ namespace Magento\CatalogRule\Test\Fixture; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Fixture\CatalogProductSimple\CategoryIds; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Conditions diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Product/Category.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Product/Category.php index c92ec7fe231f97c0fb6748a1b411d8e72a1f7e79..ed8f775509728edac53ffaf3b3fd68fbea7a0c01 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Product/Category.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Fixture/Product/Category.php @@ -6,8 +6,8 @@ namespace Magento\CatalogRule\Test\Fixture\Product; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Category @@ -18,7 +18,7 @@ use Mtf\Fixture\FixtureInterface; class Category implements FixtureInterface { /** - * @var \Mtf\Fixture\FixtureFactory + * @var \Magento\Mtf\Fixture\FixtureFactory */ protected $fixtureFactory; diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/CatalogRuleInterface.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/CatalogRuleInterface.php index 7e94d6c9874c35bfca976f6d10b8d429a3950d62..5ea223b692be3f162461c482298b3e1e13b2d3a0 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/CatalogRuleInterface.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/CatalogRuleInterface.php @@ -5,7 +5,7 @@ */ namespace Magento\CatalogRule\Test\Handler\CatalogRule; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogRuleInterface diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/Curl.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/Curl.php index 8225dc55dcb4851a31546629b51c49e574a36a0a..d1b01f2b89aa9294251b7519383697c0ade5ca0d 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/Curl.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Handler/CatalogRule/Curl.php @@ -8,11 +8,11 @@ namespace Magento\CatalogRule\Test\Handler\CatalogRule; use Magento\Backend\Test\Handler\Conditions; use Magento\CatalogRule\Test\Handler\CatalogRule; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogPriceRule.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogPriceRule.php index 3aad355402c9f601609b2ce8001a51ceac403a76..1a9b4268b9ffb8271c56725944d648ff7894a5c6 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogPriceRule.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogPriceRule.php @@ -6,7 +6,7 @@ namespace Magento\CatalogRule\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogPriceRule Repository diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogRule.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogRule.php index a2d1254e13cff783ed6580f618c5ddc0ac7b246a..5e67cddc6eb11062f4bd52a18f11f607d40f6e75 100755 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogRule.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/Repository/CatalogRule.php @@ -6,7 +6,7 @@ namespace Magento\CatalogRule\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogRule @@ -88,5 +88,16 @@ class CatalogRule extends AbstractRepository 'simple_action' => 'By Fixed Amount', 'discount_amount' => '10', ]; + + $this->_data['catalog_price_rule_all_groups'] = [ + 'name' => 'catalog_price_rule_all_groups_%isolation%', + 'description' => '-50% of price, Priority = 0', + 'is_active' => 'Active', + 'website_ids' => ['Main Website'], + 'customer_group_ids' => ['NOT LOGGED IN', 'General', 'Wholesale', 'Retailer'], + 'sort_order' => '0', + 'simple_action' => 'By Percentage of the Original Price', + 'discount_amount' => '50', + ]; } } diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/AbstractCatalogRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/AbstractCatalogRuleEntityTest.php index 83535be670a8e0c9cb62b9c6624fac3655b11cd2..5602c65632c81c6728e499ad361aaddc3d86e382 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/AbstractCatalogRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/AbstractCatalogRuleEntityTest.php @@ -10,8 +10,8 @@ use Magento\Backend\Test\Page\Adminhtml\AdminCache; use Magento\CatalogRule\Test\Fixture\CatalogRule; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Parent class for CatalogRule tests diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/DeleteCatalogPriceRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/DeleteCatalogPriceRuleEntityTest.php index 13fb5e1a6c3b72543c05394574268a3f67c14242..959edfcf46434fe1522a305970123c5c28509582 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/DeleteCatalogPriceRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestCase/DeleteCatalogPriceRuleEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\CatalogRule\Test\TestCase; use Magento\CatalogRule\Test\Fixture\CatalogRule; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete CatalogPriceRuleEntity diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/CreateCatalogRuleStep.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/CreateCatalogRuleStep.php new file mode 100644 index 0000000000000000000000000000000000000000..f17c6b396216012c6824e9f216131643944a1eeb --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/CreateCatalogRuleStep.php @@ -0,0 +1,62 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\CatalogRule\Test\TestStep; + +use Mtf\Fixture\FixtureFactory; +use Mtf\TestStep\TestStepInterface; + +/** + * Creating catalog rule + */ +class CreateCatalogRuleStep implements TestStepInterface +{ + /** + * Catalog Rule dataset name + * + * @var string + */ + protected $catalogRule; + + /** + * Factory for Fixture + * + * @var FixtureFactory + */ + protected $fixtureFactory; + + /** + * Preparing step properties + * + * @constructor + * @param FixtureFactory $fixtureFactory + * @param string $catalogRule + */ + public function __construct(FixtureFactory $fixtureFactory, $catalogRule) + { + $this->fixtureFactory = $fixtureFactory; + $this->catalogRule = $catalogRule; + } + + /** + * Create catalog rule + * + * @return array + */ + public function run() + { + $result['catalogRule'] = null; + if ($this->catalogRule != '-') { + $catalogRule = $this->fixtureFactory->createByCode( + 'catalogRule', + ['dataSet' => $this->catalogRule] + ); + $catalogRule->persist(); + $result['catalogRule'] = $catalogRule; + } + return $result; + } +} diff --git a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/DeleteAllCatalogRulesStep.php b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/DeleteAllCatalogRulesStep.php index 9bffed37d4ee1a69abef9631df5fae450b6cf1d4..fd52826d9bc8181412dd2979f4147ffd91ececed 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/DeleteAllCatalogRulesStep.php +++ b/dev/tests/functional/tests/app/Magento/CatalogRule/Test/TestStep/DeleteAllCatalogRulesStep.php @@ -8,7 +8,7 @@ namespace Magento\CatalogRule\Test\TestStep; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleIndex; use Magento\CatalogRule\Test\Page\Adminhtml\CatalogRuleNew; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class DeleteAllCatalogRulesStep diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Form.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Form.php index e632e6c1e0856aa0329c75df7bf36000f76b60d9..c98608a606314a018beb1b4baeb7c173dfd4e5d1 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Form.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Form.php @@ -6,10 +6,11 @@ namespace Magento\CatalogSearch\Test\Block\Advanced; -use Mtf\Block\Form as ParentForm; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form as ParentForm; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; /** * Advanced search form. @@ -58,10 +59,10 @@ class Form extends ParentForm * Fill the root form. * * @param FixtureInterface $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fill(FixtureInterface $fixture, Element $element = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null) { // Prepare price data $data = $fixture->getData(); @@ -83,9 +84,9 @@ class Form extends ParentForm * * @param FixtureInterface $fixture * @param array $fields - * @param Element $element + * @param SimpleElement $element */ - public function fillCustom(FixtureInterface $fixture, array $fields, Element $element = null) + public function fillCustom(FixtureInterface $fixture, array $fields, SimpleElement $element = null) { $data = $fixture->getData('fields'); $dataForMapping = array_intersect_key($data, array_flip($fields)); @@ -101,7 +102,7 @@ class Form extends ParentForm public function getFormLabels() { $labels = []; - $elements = $this->_rootElement->find($this->fieldSelector, Locator::SELECTOR_XPATH)->getElements(); + $elements = $this->_rootElement->getElements($this->fieldSelector, Locator::SELECTOR_XPATH); foreach ($elements as $element) { $labels[] = $element->find($this->labelSelector)->getText(); } diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Result.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Result.php index ad9cbccc73aa182db94f93928636792ab8449e59..f62cc2ddfb1801dd39fa2b704fcb65574db6f4c1 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Result.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Block/Advanced/Result.php @@ -6,8 +6,8 @@ namespace Magento\CatalogSearch\Test\Block\Advanced; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Result diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertAdvancedSearchProductsResult.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertAdvancedSearchProductsResult.php index 93246a5256eb577ed31f046305993fb5c0ccd9e0..3eb7492a8f74683ea7146473d2aeab0fc1892cc3 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertAdvancedSearchProductsResult.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertAdvancedSearchProductsResult.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\CatalogSearch\Test\Page\AdvancedResult; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAdvancedSearchProductsResult diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertCatalogSearchResult.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertCatalogSearchResult.php index df52f62ce4f5d9f34597e12d7d40b86e825d06c9..410a7134bae6ef66ba0a2e60acb2b7ae677e6aa0 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertCatalogSearchResult.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertCatalogSearchResult.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\AdvancedResult; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert search results. diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertProductCanBeOpenedFromSearchResult.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertProductCanBeOpenedFromSearchResult.php index 444b6ffba31091fd53eeb736ce08b61936faec29..337398e208c1697da9ec5a19a631c7b1f82c8cce 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertProductCanBeOpenedFromSearchResult.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertProductCanBeOpenedFromSearchResult.php @@ -6,7 +6,7 @@ namespace Magento\CatalogSearch\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\CatalogSearch\Test\Page\AdvancedResult; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymMassActionNotOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymMassActionNotOnFrontend.php index 928e62035bc77f2fb08505ab7a198521e89bab2f..1f1eeb86e3d69f3bc2371f42a45658c3c5693c4f 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymMassActionNotOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymMassActionNotOnFrontend.php @@ -7,8 +7,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchSynonymMassActionNotOnFrontend @@ -25,14 +25,14 @@ class AssertSearchSynonymMassActionNotOnFrontend extends AbstractConstraint * * @param array $searchTerms * @param CmsIndex $cmsIndex - * @param Browser $browser + * @param BrowserInterface $browser * @param AssertSearchSynonymNotOnFrontend $assertSearchSynonymNotOnFrontend * @return void */ public function processAssert( array $searchTerms, CmsIndex $cmsIndex, - Browser $browser, + BrowserInterface $browser, AssertSearchSynonymNotOnFrontend $assertSearchSynonymNotOnFrontend ) { foreach ($searchTerms as $term) { diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymNotOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymNotOnFrontend.php index b345274b34b46e16a3ea52848f5546b61906f4b8..63d60cf7c53f8f168ccbb2049fec3d0e8c9de2da 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymNotOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchSynonymNotOnFrontend.php @@ -8,8 +8,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchSynonymNotOnFrontend @@ -26,10 +26,10 @@ class AssertSearchSynonymNotOnFrontend extends AbstractConstraint * * @param CmsIndex $cmsIndex * @param CatalogSearchQuery $searchTerm - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CmsIndex $cmsIndex, Browser $browser, CatalogSearchQuery $searchTerm) + public function processAssert(CmsIndex $cmsIndex, BrowserInterface $browser, CatalogSearchQuery $searchTerm) { $cmsIndex->open()->getSearchBlock()->search($searchTerm->getSynonymFor()); \PHPUnit_Framework_Assert::assertNotEquals( diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermForm.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermForm.php index bdde33a21d92dcc7079a18fc5c17b3b6586b60bb..1a9dd4b4b7ea742635fa99b4a3061998970e8783 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermForm.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermForm.php @@ -9,7 +9,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchEdit; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermForm diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermInGrid.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermInGrid.php index bb03c1a485b19ff5ae6815436db6ec022e01e94a..9307dfff97a03b7dbd389b841707ae1bc5a367e0 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermInGrid.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermInGrid.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermInGrid diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionNotOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionNotOnFrontend.php index e21a404fff85d855dacaa3a947347931ce2e8a8d..9e6fc9299631fce7694178636dd6dba658e27d9b 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionNotOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionNotOnFrontend.php @@ -8,8 +8,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermMassActionNotOnFrontend @@ -26,14 +26,14 @@ class AssertSearchTermMassActionNotOnFrontend extends AbstractConstraint * * @param array $searchTerms * @param CmsIndex $cmsIndex - * @param Browser $browser + * @param BrowserInterface $browser * @param AssertSearchTermNotOnFrontend $assertSearchTermNotOnFrontend * @return void */ public function processAssert( array $searchTerms, CmsIndex $cmsIndex, - Browser $browser, + BrowserInterface $browser, AssertSearchTermNotOnFrontend $assertSearchTermNotOnFrontend ) { foreach ($searchTerms as $term) { diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionsNotInGrid.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionsNotInGrid.php index ba31e19ee048fff234109c732f7eeb0c4c43b544..4480b8795a9c61dd44378d9d0d316bb86dc7e796 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionsNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermMassActionsNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermMassActionsNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotInGrid.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotInGrid.php index 986c39c669cfd83fff8038adf0d1de074218dfbc..e1ddef02322fb71986944af0cec68bf125489efc 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotOnFrontend.php index 5c5fa68b5ffc83dd10001563831e3f7d35dff47d..07016ce22975c193fe65cb4681554255fa395eb3 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermNotOnFrontend.php @@ -8,8 +8,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermNotOnFrontend @@ -26,10 +26,10 @@ class AssertSearchTermNotOnFrontend extends AbstractConstraint * * @param CmsIndex $cmsIndex * @param CatalogSearchQuery $searchTerm - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CmsIndex $cmsIndex, Browser $browser, CatalogSearchQuery $searchTerm) + public function processAssert(CmsIndex $cmsIndex, BrowserInterface $browser, CatalogSearchQuery $searchTerm) { $queryText = $searchTerm->getQueryText(); $cmsIndex->open()->getSearchBlock()->search($queryText); diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermOnFrontend.php index 04f2f3f35ec29913bc6c83ffbdc043b058cc2fa1..58e1aa3ab135aeb39bc4608bcc5eb170ae9fa129 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermOnFrontend.php @@ -9,8 +9,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\Catalog\Test\Block\Search; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermOnFrontend @@ -38,10 +38,10 @@ class AssertSearchTermOnFrontend extends AbstractConstraint * * @param CmsIndex $cmsIndex * @param CatalogSearchQuery $searchTerm - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CmsIndex $cmsIndex, CatalogSearchQuery $searchTerm, Browser $browser) + public function processAssert(CmsIndex $cmsIndex, CatalogSearchQuery $searchTerm, BrowserInterface $browser) { $errors = []; $this->searchBlock = $cmsIndex->open()->getSearchBlock(); diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessDeleteMessage.php index 16ff4f13f1c1a2c5dd56d531221e7171bd14ce42..0177e5d8860f9307eb70b795272d727d3ec36c6b 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessMassDeleteMessage.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessMassDeleteMessage.php index c71093f642e4a4cb0d6b7e9819977f4f8caf7762..f05a61e2d0fa8ed9c104d56dc257bc1d9d33c6b5 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessMassDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessMassDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermSuccessMassDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessSaveMessage.php index 8eb589cc1332f412ee257f51a6da1bf80648dd7e..96d9df392e9537c40e7696f7e4b6434c8a863f1d 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSynonymOnFrontend.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSynonymOnFrontend.php index cb1cc34b772220ed14432cfca639530b835131ed..01379f373a4c3029c7807e72e29d6401039eff30 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSynonymOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSearchTermSynonymOnFrontend.php @@ -8,8 +8,8 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermSynonymOnFrontend @@ -25,11 +25,11 @@ class AssertSearchTermSynonymOnFrontend extends AbstractConstraint * Assert that you will be redirected to url from dataset * * @param CmsIndex $cmsIndex - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogSearchQuery $searchTerm * @return void */ - public function processAssert(CmsIndex $cmsIndex, Browser $browser, CatalogSearchQuery $searchTerm) + public function processAssert(CmsIndex $cmsIndex, BrowserInterface $browser, CatalogSearchQuery $searchTerm) { $cmsIndex->open()->getSearchBlock()->search($searchTerm->getSynonymFor()); $windowUrl = $browser->getUrl(); diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSuggestSearchingResult.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSuggestSearchingResult.php index ff6bc79e1a8bc475046c5f5677b432a45ce20da0..388806e1f3a8e18d55da75712f113d5e50154b30 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSuggestSearchingResult.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Constraint/AssertSuggestSearchingResult.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\Constraint; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSuggestSearchingResult diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery.php index ce372d1c8ad58440887924b4d6cf8b335196f2b1..82858efa74fbeb2dd6c27328ec38e482de457c75 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery.php @@ -6,7 +6,7 @@ namespace Magento\CatalogSearch\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CatalogSearchQuery diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery/QueryText.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery/QueryText.php index 172d79054d9b981d252f6752c9d5eeed7b894d8b..b2bf945cc675cb44e701f778786c6743b1757306 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery/QueryText.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Fixture/CatalogSearchQuery/QueryText.php @@ -6,9 +6,9 @@ namespace Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Data to search for. diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/CatalogSearchQueryInterface.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/CatalogSearchQueryInterface.php index 431ad8860dd8b03192ed00d5f4f099e403948a2a..cc6f02816f129edf45d7b02546bbffccbeb11ef1 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/CatalogSearchQueryInterface.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/CatalogSearchQueryInterface.php @@ -6,7 +6,7 @@ namespace Magento\CatalogSearch\Test\Handler\CatalogSearchQuery; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CatalogSearchQueryInterface diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/Curl.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/Curl.php index ac1f7447596479e2d1cd55c870709ab972c45ddf..d570d3653db7c94a61c94010c2e409e543e1e792 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/Curl.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Handler/CatalogSearchQuery/Curl.php @@ -6,12 +6,12 @@ namespace Magento\CatalogSearch\Test\Handler\CatalogSearchQuery; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Create new search term via curl. diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Repository/CatalogSearchQuery.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Repository/CatalogSearchQuery.php index 789e3312ad1972cb2c613a7681fa47cb30acb664..60eea1265c76ac2463eaf411294dde8c149900d4 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Repository/CatalogSearchQuery.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/Repository/CatalogSearchQuery.php @@ -6,7 +6,7 @@ namespace Magento\CatalogSearch\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CatalogSearchQuery diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.php index 98eaf67aad609444e5d606ce2b672f83900f8607..2bd73f161a8028441ef459a631e1bfa211d9df97 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/AdvancedSearchEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\CatalogSearch\Test\Page\AdvancedSearch; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Preconditions: diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/CreateSearchTermEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/CreateSearchTermEntityTest.php index 02dc9a6038cd533bf8071473e5b408ef0ac44b93..106070b62ec4e474126a1966f8461f0cd96a80b0 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/CreateSearchTermEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/CreateSearchTermEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchEdit; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateSearchTermEntity diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/DeleteSearchTermEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/DeleteSearchTermEntityTest.php index d9f55fe374461ca78db7693681e914ef69fba30a..b8400504d031aeda63c0d132b266d69aa55e7c46 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/DeleteSearchTermEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/DeleteSearchTermEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchEdit; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteSearchTermEntity diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/EditSearchTermEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/EditSearchTermEntityTest.php index 4c6c542abae9d4429d07413ce59ee6b3be166d50..a2b143d4786f03bd5e0b64f381c0c01231d5ae3b 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/EditSearchTermEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/EditSearchTermEntityTest.php @@ -10,7 +10,7 @@ use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchEdit; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for EditSearchTermEntity diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/MassDeleteSearchTermEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/MassDeleteSearchTermEntityTest.php index 306ea03431d4c5e2ba1c072451b34049a5e2bb36..4f35edd4150c5e5d8daa234e290eb5318465bf0d 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/MassDeleteSearchTermEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/MassDeleteSearchTermEntityTest.php @@ -8,8 +8,8 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for MassDeleteSearchTermEntity diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SearchEntityResultsTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SearchEntityResultsTest.php index a965f34e0fa996531d92e214c3cd9058cb5f9715..30a54eda01b5b919ec9770e6a601c3f4678d3f2f 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SearchEntityResultsTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SearchEntityResultsTest.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Preconditions: diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.php b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.php index dda437f4e48f3a87b7ef753958e8541675f249f8..d4ce912e61386c4a79a50b99f4c6c64b24510f45 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/TestCase/SuggestSearchingResultEntityTest.php @@ -8,7 +8,7 @@ namespace Magento\CatalogSearch\Test\TestCase; use Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Cover Suggest Searching Result (SearchEntity) diff --git a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/etc/constraint.xml b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/etc/constraint.xml index 7a061c80ad16bc44cbc6ec1b7261f4649571dd72..9a215cf30c095aead61ef10a573a6bf52e92f1cb 100644 --- a/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/etc/constraint.xml +++ b/dev/tests/functional/tests/app/Magento/CatalogSearch/Test/etc/constraint.xml @@ -48,7 +48,7 @@ <require> <searchTerm class="Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchTermOnFrontend> <assertSearchTermSuccessSaveMessage module="Magento_CatalogSearch"> @@ -62,7 +62,7 @@ <require> <searchTerm class="Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchTermSynonymOnFrontend> <assertSearchTermSuccessDeleteMessage module="Magento_CatalogSearch"> @@ -83,7 +83,7 @@ <require> <searchTerm class="Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchTermNotOnFrontend> <assertSearchSynonymNotOnFrontend module="Magento_CatalogSearch"> @@ -91,7 +91,7 @@ <require> <searchTerm class="Magento\CatalogSearch\Test\Fixture\CatalogSearchQuery" /> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchSynonymNotOnFrontend> <assertSearchTermSuccessMassDeleteMessage module="Magento_CatalogSearch"> @@ -110,14 +110,14 @@ <severity>high</severity> <require> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchTermMassActionNotOnFrontend> <assertSearchSynonymMassActionNotOnFrontend module="Magento_CatalogSearch"> <severity>high</severity> <require> <cmsIndex class="Magento\Cms\Test\Page\CmsIndex" /> - <browser class="Mtf\Client\Browser" /> + <browser class="Magento\Mtf\Client\Browser" /> </require> </assertSearchSynonymMassActionNotOnFrontend> <assertProductCanBeOpenedFromSearchResult module="Magento_CatalogSearch"> diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart.php index 0ab77e4f68f5d1c611e9f319c9e4b85c197c6d76..2802929c1069c518f00fbb12bee0d8715daa0a96 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart.php @@ -9,10 +9,10 @@ namespace Magento\Checkout\Test\Block; use Exception; use Magento\Checkout\Test\Block\Cart\CartItem; use Magento\Checkout\Test\Block\Onepage\Link; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Cart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/AbstractCartItem.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/AbstractCartItem.php index 9bb23fb9ef151a0a43fab0a042d0e8566a288b86..c2c64fd6903d8b877c8cf18dc0fc922e2970c98f 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/AbstractCartItem.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/AbstractCartItem.php @@ -6,7 +6,7 @@ namespace Magento\Checkout\Test\Block\Cart; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class AbstractCartItem diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartEmpty.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartEmpty.php index c3a24adb6cde7d3f02901f156896e20adbb362b4..0df5fe46b9e4afff7d3e4281c3a0c3e150ae512d 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartEmpty.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartEmpty.php @@ -6,8 +6,8 @@ namespace Magento\Checkout\Test\Block\Cart; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class CartEmpty diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartItem.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartItem.php index 622542c132b6391dd52e2244577fe310f5cae293..44de73078781de9aefbe259e80523cd9f2d1379c 100755 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartItem.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/CartItem.php @@ -6,7 +6,7 @@ namespace Magento\Checkout\Test\Block\Cart; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class CartItem @@ -69,23 +69,27 @@ class CartItem extends AbstractCartItem /** * Get product price * - * @return string + * @return string|null */ public function getPrice() { - $cartProductPrice = $this->_rootElement->find($this->price, Locator::SELECTOR_XPATH)->getText(); - return str_replace(',', '', $this->escapeCurrency($cartProductPrice)); + $cartProductPrice = $this->_rootElement->find($this->price, Locator::SELECTOR_XPATH); + return $cartProductPrice->isVisible() + ? str_replace(',', '', $this->escapeCurrency($cartProductPrice->getText())) + : null; } /** * Get product price including tax * - * @return string + * @return string|null */ public function getPriceInclTax() { - $cartProductPrice = $this->_rootElement->find($this->priceInclTax, Locator::SELECTOR_XPATH)->getText(); - return str_replace(',', '', $this->escapeCurrency($cartProductPrice)); + $cartProductPrice = $this->_rootElement->find($this->priceInclTax, Locator::SELECTOR_XPATH); + return $cartProductPrice->isVisible() + ? str_replace(',', '', $this->escapeCurrency($cartProductPrice->getText())) + : null; } /** @@ -112,29 +116,33 @@ class CartItem extends AbstractCartItem /** * Get sub-total for the specified item in the cart * - * @return string + * @return string|null */ public function getSubtotalPrice() { - $price = $this->_rootElement->find($this->subtotalPrice, Locator::SELECTOR_XPATH)->getText(); - return str_replace(',', '', $this->escapeCurrency($price)); + $cartProductPrice = $this->_rootElement->find($this->subtotalPrice, Locator::SELECTOR_XPATH); + return $cartProductPrice->isVisible() + ? str_replace(',', '', $this->escapeCurrency($cartProductPrice->getText())) + : null; } /** * Get sub-total including tax for the specified item in the cart * - * @return string + * @return string|null */ public function getSubtotalPriceInclTax() { - $price = $this->_rootElement->find($this->subTotalPriceInclTax, Locator::SELECTOR_XPATH)->getText(); - return str_replace(',', '', $this->escapeCurrency($price)); + $cartProductPrice = $this->_rootElement->find($this->subTotalPriceInclTax, Locator::SELECTOR_XPATH); + return $cartProductPrice->isVisible() + ? str_replace(',', '', $this->escapeCurrency($cartProductPrice->getText())) + : null; } /** * Get product options in the cart * - * @return string + * @return array */ public function getOptions() { @@ -142,8 +150,8 @@ class CartItem extends AbstractCartItem $options = []; if ($optionsBlock->isVisible()) { - $titles = $optionsBlock->find('./dt', Locator::SELECTOR_XPATH)->getElements(); - $values = $optionsBlock->find('./dd', Locator::SELECTOR_XPATH)->getElements(); + $titles = $optionsBlock->getElements('./dt', Locator::SELECTOR_XPATH); + $values = $optionsBlock->getElements('./dd', Locator::SELECTOR_XPATH); foreach ($titles as $key => $title) { $value = $values[$key]->getText(); diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/DiscountCodes.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/DiscountCodes.php index a5faa27be3a174eb6da4936622b4ea612ef722ea..58637651153864cfb996da1bf05ce9260c1f73c9 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/DiscountCodes.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/DiscountCodes.php @@ -6,8 +6,8 @@ namespace Magento\Checkout\Test\Block\Cart; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class DiscountCodes diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Shipping.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Shipping.php index 2388dbee076c19f4dacaef84ddba2e6b368edbbf..b6fde4920b1d0c5d27b215117356ad172626e96e 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Shipping.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Shipping.php @@ -7,8 +7,8 @@ namespace Magento\Checkout\Test\Block\Cart; use Magento\Customer\Test\Fixture\AddressInjectable; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Shipping @@ -125,6 +125,7 @@ class Shipping extends Form } ); $selector = sprintf($this->shippingMethod, $carrier, $method); + return $this->_rootElement->find($selector, Locator::SELECTOR_XPATH)->isVisible(); } } diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar.php index b7df995b3c9695c921d89246eeb50761fc21f06c..f909e97086b5a2f2bf5dc3a84e15994d526d55d3 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar.php @@ -6,9 +6,9 @@ namespace Magento\Checkout\Test\Block\Cart; use Magento\Checkout\Test\Block\Cart\Sidebar\Item; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Sidebar diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar/Item.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar/Item.php index 43e9110ecda721e861cbc430428b6ed57b20c9cc..7d0966f153598dcdd97c018ecf89f3cf5b0ae4d1 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar/Item.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Sidebar/Item.php @@ -36,7 +36,7 @@ class Item extends Sidebar public function removeItemFromMiniCart() { $this->_rootElement->find($this->removeItem)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Totals.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Totals.php index 78921b17470923e785d5f2ec898875aa147acacf..fb47e4560253e2ec8d7d1e8e245f6853940b0f4f 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Totals.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Cart/Totals.php @@ -6,8 +6,8 @@ namespace Magento\Checkout\Test\Block\Cart; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Totals @@ -76,7 +76,7 @@ class Totals extends Block * * @var string */ - protected $discount = '//tr[normalize-space(th)="Discount"]//span'; + protected $discount = '[class=totals] .amount .price'; /** * Get shipping price including tax selector @@ -95,45 +95,45 @@ class Totals extends Block /** * Get Grand Total Text * - * @return array|string + * @return string */ public function getGrandTotal() { - $grandTotal = $this->_rootElement->find($this->grandTotal)->getText(); + $grandTotal = $this->_rootElement->find($this->grandTotal, Locator::SELECTOR_CSS)->getText(); return $this->escapeCurrency($grandTotal); } /** * Get Grand Total Text * - * @return string + * @return string|null */ public function getGrandTotalIncludingTax() { - $grandTotal = $this->_rootElement->find($this->grandTotalInclTax, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($grandTotal); + $priceElement = $this->_rootElement->find($this->grandTotalInclTax, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Get Grand Total Text * - * @return string + * @return string|null */ public function getGrandTotalExcludingTax() { - $grandTotal = $this->_rootElement->find($this->grandTotalExclTax, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($grandTotal); + $priceElement = $this->_rootElement->find($this->grandTotalExclTax, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Get Tax text from Order Totals * - * @return array|string + * @return string|null */ public function getTax() { - $taxPrice = $this->_rootElement->find($this->tax, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($taxPrice); + $priceElement = $this->_rootElement->find($this->tax, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** @@ -153,37 +153,37 @@ class Totals extends Block */ public function getSubtotal() { - $subTotal = $this->_rootElement->find($this->subtotal)->getText(); + $subTotal = $this->_rootElement->find($this->subtotal, Locator::SELECTOR_CSS)->getText(); return $this->escapeCurrency($subTotal); } /** * Get Subtotal text * - * @return string + * @return string|null */ public function getSubtotalIncludingTax() { - $subTotal = $this->_rootElement->find($this->subtotalInclTax, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($subTotal); + $priceElement = $this->_rootElement->find($this->subtotalInclTax, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Get Subtotal text * - * @return string + * @return string|null */ public function getSubtotalExcludingTax() { - $subTotal = $this->_rootElement->find($this->subtotalExclTax, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($subTotal); + $priceElement = $this->_rootElement->find($this->subtotalExclTax, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Method that escapes currency symbols * * @param string $price - * @return string + * @return string|null */ protected function escapeCurrency($price) { @@ -194,35 +194,34 @@ class Totals extends Block /** * Get discount * - * @return string + * @return string|null */ public function getDiscount() { - $discount = $this->_rootElement->find($this->discount, Locator::SELECTOR_XPATH)->getText(); - return $this->escapeCurrency($discount); + $priceElement = $this->_rootElement->find($this->discount, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Get shipping price * - * @return string + * @return string|null */ public function getShippingPrice() { - $shippingPrice = $this->_rootElement->find($this->shippingPriceSelector, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($shippingPrice); + $priceElement = $this->_rootElement->find($this->shippingPriceSelector, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** * Get shipping price * - * @return string + * @return string|null */ public function getShippingPriceInclTax() { - $shippingPrice = $this->_rootElement - ->find($this->shippingPriceInclTaxSelector, Locator::SELECTOR_CSS)->getText(); - return $this->escapeCurrency($shippingPrice); + $priceElement = $this->_rootElement->find($this->shippingPriceInclTaxSelector, Locator::SELECTOR_CSS); + return $priceElement->isVisible() ? $this->escapeCurrency($priceElement->getText()) : null; } /** diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Onepage/Link.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Onepage/Link.php index db25444ba3b5ce8e7d8efa201b9c3c77d4d7a4ea..cd1310aa639968bfc0f5dd54977c37a947c7d39d 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Onepage/Link.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Block/Onepage/Link.php @@ -6,7 +6,7 @@ namespace Magento\Checkout\Test\Block\Onepage; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Link diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertAddedProductToCartSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertAddedProductToCartSuccessMessage.php index fcfbe4fa3cfdf7758da3a16a8fe49aa697098e40..e45449de86fd3d5db18d779ead7d58574b36abaa 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertAddedProductToCartSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertAddedProductToCartSuccessMessage.php @@ -7,8 +7,8 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertAddedProductToCartSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartIsEmpty.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartIsEmpty.php index 5e9008fe85be9df695e842969b5129b2f5e0caab..884ade85b09646eb0fffead05613f3f585ab741c 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartIsEmpty.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartIsEmpty.php @@ -8,8 +8,8 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCartIsEmpty @@ -31,10 +31,10 @@ class AssertCartIsEmpty extends AbstractConstraint * Click here to continue shopping." where 'here' is link that leads to index page * * @param CheckoutCart $checkoutCart - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ - public function processAssert(CheckoutCart $checkoutCart, Browser $browser) + public function processAssert(CheckoutCart $checkoutCart, BrowserInterface $browser) { $checkoutCart->open(); $cartEmptyBlock = $checkoutCart->getCartEmptyBlock(); diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartItemsOptions.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartItemsOptions.php index 1daf7be9ffe79edd7585022eec2624d428addc3a..c2dc2534f436b3f8bc252f0cc1840fd3229a742b 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartItemsOptions.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertCartItemsOptions.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Fixture\Cart\Items; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert that cart item options for product(s) display with correct information block. diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertGrandTotalInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertGrandTotalInShoppingCart.php index cc6b3b6d8c0c986cab60b714c56db5c3c1cb603c..ae6092c120fba3391d9cba2473d5add9e3c8d632 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertGrandTotalInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertGrandTotalInShoppingCart.php @@ -8,7 +8,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGrandTotalInShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderSuccessPlacedMessage.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderSuccessPlacedMessage.php index cb4befc85d13c11d21012f6aa55ee743ae6605a9..752aaf9c871abeb1850d3a18c9d9a6a8130bf4e9 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderSuccessPlacedMessage.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderSuccessPlacedMessage.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutOnepageSuccess; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderSuccessPlacedMessage diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderTotalOnReviewPage.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderTotalOnReviewPage.php index 5639da766adf1b41e8d0aa72d6b96085972657f4..aefa6c7410fc279379592157ba91c170649fca72 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderTotalOnReviewPage.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertOrderTotalOnReviewPage.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutOnepage; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderTotalOnReviewPage diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertPriceInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertPriceInShoppingCart.php index b010de8e5dc8d2862a8d8e886590dd3adde43c89..3e45f83a879685dad3eda958b1a9c8dd3010cd0b 100755 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertPriceInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertPriceInShoppingCart.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Fixture\Cart\Items; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertPriceInShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductAbsentInMiniShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductAbsentInMiniShoppingCart.php index 64ee8bb3a267f199d15f0dc7c0f767df5679ea47..db61bb670866a1632beeebbb3f6ce2505a76a625 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductAbsentInMiniShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductAbsentInMiniShoppingCart.php @@ -7,8 +7,8 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductAbsentInMiniShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductIsNotEditable.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductIsNotEditable.php index cfce160ea5990d871cbcea2651100d36a15a00fd..b371ec3fc3a4a0dc4703f54a92a2fe3161693d51 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductIsNotEditable.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductIsNotEditable.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductIsNotEditable diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInMiniShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInMiniShoppingCart.php index 75c3ce9bf039746043c2ee8e0679fe9d6eeb81e6..4a64e5610c29e1db497e7e862ac8a7eacd57ed4b 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInMiniShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInMiniShoppingCart.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductPresentInMiniShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInShoppingCart.php index 1fd9499bdba0678799de0604293fc60d808d54f0..f01fb902ebdfa31c09a975b1959feef186f62d3a 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductPresentInShoppingCart.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductPresentInShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInMiniShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInMiniShoppingCart.php index 23e4a1662f856f432ab299a4ea7089f41cb665ae..8a0dd741d1859c01524b596356c7c5f2f7e02df4 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInMiniShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInMiniShoppingCart.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Fixture\Cart\Items; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductQtyInMiniShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInShoppingCart.php index c104a7172dafe11e7d5d7e53a4225fa6422feb9c..b8c353c3f316f418bf40f6ade30b60130b4b6cc3 100755 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductQtyInShoppingCart.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Fixture\Cart\Items; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductQtyInShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductsAbsentInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductsAbsentInShoppingCart.php index 1486d72d50c903a071297719549d49e290455617..515b7433ede70aec87a9c0ddb6003aaadd09f54c 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductsAbsentInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertProductsAbsentInShoppingCart.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\Constraint; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that products are absent in shopping cart. diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertSubtotalInShoppingCart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertSubtotalInShoppingCart.php index 81d8c95bef265a443a0394c244eef4f6a4e878da..770595ed2bd3bac943902bbbdc15075301a0eace 100755 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertSubtotalInShoppingCart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Constraint/AssertSubtotalInShoppingCart.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Fixture\Cart\Items; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertSubtotalInShoppingCart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart.php index 4a2db34cc9c1301044ce55c8c095e1d901b28d32..aab39fa9e4e6d47ddb5c91854a98be4d97e590b5 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart.php @@ -6,7 +6,7 @@ namespace Magento\Checkout\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Cart diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart/Items.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart/Items.php index de23b4c2811bdc8f8d1605e0a97eca67c5bf1881..6ca6c12cc218cfbbb0d6a65ecef8e99c40b8dfd2 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart/Items.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/Fixture/Cart/Items.php @@ -6,8 +6,8 @@ namespace Magento\Checkout\Test\Fixture\Cart; -use Mtf\Fixture\FixtureInterface; -use Mtf\ObjectManager; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\ObjectManager; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.php index ed545771b6579d4c1076deaef0fad213f76e686a..8bfa4789d0ef329d869850606da31d13e302bb09 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/AddProductsToShoppingCartEntityTest.php @@ -8,10 +8,10 @@ namespace Magento\Checkout\Test\TestCase; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureFactory; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for AddProductsToShoppingCartEntity @@ -40,7 +40,7 @@ class AddProductsToShoppingCartEntityTest extends Injectable /** * Browser interface * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -68,14 +68,14 @@ class AddProductsToShoppingCartEntityTest extends Injectable /** * Prepare test data * - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureFactory $fixtureFactory * @param CatalogProductView $catalogProductView * @param CheckoutCart $cartPage * @return void */ public function __prepare( - Browser $browser, + BrowserInterface $browser, FixtureFactory $fixtureFactory, CatalogProductView $catalogProductView, CheckoutCart $cartPage diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductFromMiniShoppingCartTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductFromMiniShoppingCartTest.php index fe869f8eb6002e721ad85c76782ae3033dfedcac..b3ae8fdbd934efe933c2ad70b9c945d2da272c02 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductFromMiniShoppingCartTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductFromMiniShoppingCartTest.php @@ -8,10 +8,10 @@ namespace Magento\Checkout\Test\TestCase; use Magento\Checkout\Test\Page\CheckoutCart; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Class DeleteProductFromMiniShoppingCartTest diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.php index da8ca1bba79e8bbbdbafe3f9ee34840274f2eb67..87b1cd5997332bd938d6a5bd7fe4c7a95863fb6d 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/DeleteProductsFromShoppingCartTest.php @@ -8,11 +8,11 @@ namespace Magento\Checkout\Test\TestCase; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Class DeleteProductsFromShoppingCartTest @@ -39,7 +39,7 @@ class DeleteProductsFromShoppingCartTest extends Injectable /** * Browser interface * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -67,14 +67,14 @@ class DeleteProductsFromShoppingCartTest extends Injectable /** * Prepare test data * - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureFactory $fixtureFactory * @param CatalogProductView $catalogProductView * @param CheckoutCart $cartPage * @return void */ public function __prepare( - Browser $browser, + BrowserInterface $browser, FixtureFactory $fixtureFactory, CatalogProductView $catalogProductView, CheckoutCart $cartPage diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.php index a4a01f195a57eb68e746079b5d62d100d798bcc9..f5d30d2f9bdc2f376563ee8964537b6758553fb2 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateProductFromMiniShoppingCartEntityTest.php @@ -8,9 +8,9 @@ namespace Magento\Checkout\Test\TestCase; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php index 2c15007d11119a5f5c5dd762389eab51fa593a0c..bd3f7381fb4ad87b90eb55fec967c9dccef684ee 100755 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestCase/UpdateShoppingCartTest.php @@ -10,9 +10,9 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Fixture\Cart; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update ShoppingCart @@ -42,7 +42,7 @@ class UpdateShoppingCartTest extends Injectable /** * Browser interface * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -70,11 +70,11 @@ class UpdateShoppingCartTest extends Injectable /** * Prepare test data * - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureFactory $fixtureFactory * @return void */ - public function __prepare(Browser $browser, FixtureFactory $fixtureFactory) + public function __prepare(BrowserInterface $browser, FixtureFactory $fixtureFactory) { $this->browser = $browser; $this->fixtureFactory = $fixtureFactory; diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/AddProductsToTheCartStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/AddProductsToTheCartStep.php index 2b4528b8253221ba12939a105534ecf6ea94fd82..bc314698d1fe275333ca9843f2eb538f52e66f42 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/AddProductsToTheCartStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/AddProductsToTheCartStep.php @@ -9,8 +9,8 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Client\Browser; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class AddProductsToTheCartStep @@ -49,7 +49,7 @@ class AddProductsToTheCartStep implements TestStepInterface /** * Interface Browser * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -58,14 +58,14 @@ class AddProductsToTheCartStep implements TestStepInterface * @param CatalogProductView $catalogProductView * @param CheckoutCart $checkoutCart * @param CmsIndex $cmsIndex - * @param Browser $browser + * @param BrowserInterface $browser * @param array $products */ public function __construct( CatalogProductView $catalogProductView, CheckoutCart $checkoutCart, CmsIndex $cmsIndex, - Browser $browser, + BrowserInterface $browser, array $products ) { $this->products = $products; diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillBillingInformationStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillBillingInformationStep.php index 40deeb5db847456359624cb6f6811f9390e1082f..1c0ce87c6880e0dd9b298e487d12973e63d2a338 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillBillingInformationStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillBillingInformationStep.php @@ -9,7 +9,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutOnepage; use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class FillBillingInformationStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillShippingMethodStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillShippingMethodStep.php index 0d051665e6efb4694123bc192b757166ed179029..df510f1e2e80cee8c1e4efd7f77f42089fc1486c 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillShippingMethodStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/FillShippingMethodStep.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutOnepage; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class FillShippingMethodStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/PlaceOrderStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/PlaceOrderStep.php index 3b72746e08c1518a7d7696647dcf8c6279bb72e0..7adfc7fc1ac63ea36b5a5eb242356dc80690ac82 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/PlaceOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/PlaceOrderStep.php @@ -9,7 +9,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Constraint\AssertOrderTotalOnReviewPage; use Magento\Checkout\Test\Page\CheckoutOnepage; use Magento\Checkout\Test\Page\CheckoutOnepageSuccess; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class PlaceOrderStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/ProceedToCheckoutStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/ProceedToCheckoutStep.php index 2776d137891760976c25488190243c5840c839a8..6fdee3ab31755a96be9776bac991c2c1a40f4729 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/ProceedToCheckoutStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/ProceedToCheckoutStep.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutCart; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class ProceedToCheckoutStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectCheckoutMethodStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectCheckoutMethodStep.php index 154ccf108102f1ca984f8ad41e9ca78e305a7707..3d37267a82e6213597df1323b717503bb205a011 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectCheckoutMethodStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectCheckoutMethodStep.php @@ -8,7 +8,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutOnepage; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectCheckoutMethodStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectPaymentMethodStep.php b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectPaymentMethodStep.php index ba5eee6cc936ffd2317c14e07afd61d5d525ec36..f17bc063c16bf56c06b74c663f7620888b6720f1 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectPaymentMethodStep.php +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/TestStep/SelectPaymentMethodStep.php @@ -7,7 +7,7 @@ namespace Magento\Checkout\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutOnepage; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectPaymentMethodStep diff --git a/dev/tests/functional/tests/app/Magento/Checkout/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/Checkout/Test/etc/scenario.xml index ab0fe4da4e6d0fa88e35671641be4ce4c2e8b5de..bef12be128cdf135313f5438de2a29774c26417e 100644 --- a/dev/tests/functional/tests/app/Magento/Checkout/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/Checkout/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="OnePageCheckoutTest" module="Magento_Checkout"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/CmsBlockInterface.php b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/CmsBlockInterface.php index 128aee14bafe44dbef6870ebfb8ce7f086585ad7..20685db1cdedc533a0dc078f0aa6813d13304580 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/CmsBlockInterface.php +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/CmsBlockInterface.php @@ -6,7 +6,7 @@ namespace Magento\Cms\Test\Handler\CmsBlock; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CmsBlockInterface diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/Curl.php b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/Curl.php index 2c716b8c99374efb63363f65155096bc11a50529..49f62f95f8582fe9532503d2ed9fcb223f817a8a 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsBlock/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Cms\Test\Handler\CmsBlock; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/CmsPageInterface.php b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/CmsPageInterface.php index 5c3ce1b3c1788801ae678a0eae8d71da0ac6e88f..35f8db75513c5c86dc503cad6080ff3d90a0bcd9 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/CmsPageInterface.php +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/CmsPageInterface.php @@ -6,7 +6,7 @@ namespace Magento\Cms\Test\Handler\CmsPage; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CmsPageInterface diff --git a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/Curl.php b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/Curl.php index 012448057df9a7e549100d7a5ce410c32d4e2db3..85e033bcf4a4d95331c4159e5103b330de770bfc 100644 --- a/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Cms/Test/Handler/CmsPage/Curl.php @@ -7,11 +7,11 @@ namespace Magento\Cms\Test\Handler\CmsPage; use Magento\Backend\Test\Handler\Conditions; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/AffectedAttributeSet.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/AffectedAttributeSet.php index a2c0e6923bd39d474063b361e074e375bfabaa0b..1385164d592ac0608f057730e41b2897938ae55f 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/AffectedAttributeSet.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/AffectedAttributeSet.php @@ -6,10 +6,11 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Backend\Test\Block\Widget\Form as ParentForm; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; /** * Class AffectedAttributeSet @@ -35,10 +36,10 @@ class AffectedAttributeSet extends ParentForm * Fill popup form * * @param FixtureInterface $product - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @return $this */ - public function fill(FixtureInterface $product, Element $element = null) + public function fill(FixtureInterface $product, SimpleElement $element = null) { $affectedAttributeSet = $product->getData('affected_attribute_set'); diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Composite/Configure.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Composite/Configure.php index fd89c189a2f5d167325618b19ae0a226d9ac4ee9..8470504b7f254583d16945c893389afc3a259fa8 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Composite/Configure.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Composite/Configure.php @@ -7,7 +7,7 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Composite; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Configure diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config.php index 60295a147a7ea83bcac921a8883ad8d43d114e79..c402668ebfe6925e27c7796150ab4beb5ca4efc7 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config.php @@ -8,8 +8,10 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Supe use Magento\Backend\Test\Block\Template; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Catalog\Test\Fixture\CatalogCategory; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; /** * Class Config @@ -84,10 +86,10 @@ class Config extends Tab * Fill variations fieldset * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $attributes = isset($fields['configurable_attributes_data']['value']) ? $fields['configurable_attributes_data']['value'] @@ -175,10 +177,10 @@ class Config extends Tab * Get data of tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $data = []; @@ -196,9 +198,9 @@ class Config extends Tab */ public function deleteAttributes() { - $attributeElements = $this->_rootElement->find($this->attributeElement)->getElements(); + $attributeElements = $this->_rootElement->getElements($this->attributeElement); $this->_rootElement->find($this->variationsContent)->click(); - foreach ($attributeElements as $element) { + foreach (array_reverse($attributeElements) as $element) { $element->find($this->deleteVariationButton)->click(); } } diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute.php index 4aa8b5f1803350cdd5d4a874d98e78b7c253fe8b..eecdf4f31ddbf1743f6db9cd71a4c49783810111 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute.php @@ -6,10 +6,10 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config; +use Magento\Mtf\Client\Locator; use Magento\Backend\Test\Block\Widget\Form; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config\Attribute\AttributeSelector; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; /** * Attribute block in Variation section. @@ -253,11 +253,11 @@ class Attribute extends Form /** * Check is visible option * - * @param Element $attributeBlock + * @param SimpleElement $attributeBlock * @param int $number * @return bool */ - protected function isVisibleOption(Element $attributeBlock, $number) + protected function isVisibleOption(SimpleElement $attributeBlock, $number) { return $attributeBlock->find( sprintf($this->optionContainerByNumber, $number), @@ -303,7 +303,7 @@ class Attribute extends Form $optionMapping = $this->dataMapping(); $count = 1; - /** @var Element $attributeBlock */ + /** @var SimpleElement $attributeBlock */ $attributeBlock = $this->_rootElement->find(sprintf($this->attributeBlock, $count), Locator::SELECTOR_XPATH); while ($attributeBlock->isVisible()) { $this->showAttributeContent($attributeBlock); @@ -312,9 +312,9 @@ class Attribute extends Form 'label' => $attributeBlock->find($this->attributeLabel)->getValue(), 'options' => [], ]; - $options = $attributeBlock->find($this->optionContainer, Locator::SELECTOR_XPATH)->getElements(); + $options = $attributeBlock->getElements($this->optionContainer, Locator::SELECTOR_XPATH); foreach ($options as $optionKey => $option) { - /** @var Element $option */ + /** @var SimpleElement $option */ if ($option->isVisible()) { $attribute['options'][$optionKey] = $this->_getData($optionMapping, $option); $attribute['options'][$optionKey] += $this->getOptionalFields($option); @@ -335,10 +335,10 @@ class Attribute extends Form /** * Show attribute content * - * @param Element $attribute + * @param SimpleElement $attribute * @return void */ - protected function showAttributeContent(Element $attribute) + protected function showAttributeContent(SimpleElement $attribute) { if (!$attribute->find($this->attributeContent)->isVisible()) { $this->_rootElement->find($this->configContent)->click(); @@ -371,11 +371,11 @@ class Attribute extends Form /** * Get optional fields * - * @param Element $context + * @param SimpleElement $context * @param array $fields * @return array */ - protected function getOptionalFields(Element $context, array $fields = []) + protected function getOptionalFields(SimpleElement $context, array $fields = []) { $data = []; @@ -383,6 +383,7 @@ class Attribute extends Form foreach ($fields as $name => $params) { $data[$name] = $context->find($params['selector'], $params['strategy'])->getText(); } + return $data; } } diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/AttributeSelector.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/AttributeSelector.php index 650d09f119544c2be712c7005f113793357df901..7fac90081181236c028ba2a8af2c5c103a820fa9 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/AttributeSelector.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/AttributeSelector.php @@ -6,8 +6,8 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config\Attribute; +use Magento\Mtf\Client\Element\SuggestElement; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; -use Mtf\Client\Driver\Selenium\Element\SuggestElement; /** * Class AttributeSelector diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/ToggleDropdown.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/ToggleDropdown.php index 7c84a33b13dbe4925e41972323d48e71b00e07b2..fffb5b80c8e24be658218a67237811ef690bd942 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/ToggleDropdown.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Attribute/ToggleDropdown.php @@ -6,14 +6,14 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config\Attribute; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; /** * Class ToggleDropdown * Class for toggle dropdown elements. */ -class ToggleDropdown extends Element +class ToggleDropdown extends SimpleElement { /** * Selector for field value @@ -44,7 +44,7 @@ class ToggleDropdown extends Element */ public function setValue($value) { - $this->_eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); + $this->eventManager->dispatchEvent(['set_value'], [__METHOD__, $this->getAbsoluteSelector()]); if ($value != $this->getValue()) { $value = ('Yes' == $value) ? '%' : '$'; @@ -62,7 +62,7 @@ class ToggleDropdown extends Element */ public function getValue() { - $this->_eventManager->dispatchEvent(['get_value'], [(string)$this->_locator]); + $this->eventManager->dispatchEvent(['get_value'], [__METHOD__, $this->getAbsoluteSelector()]); $value = $this->find($this->field, Locator::SELECTOR_XPATH)->getText(); return ('%' == $value) ? 'Yes' : 'No'; diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Matrix.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Matrix.php index e04457ba67c9a1095cb7067927ae1f5cc06e1376..11db5ed304636b2e2f25019e3c7b08bc5d8ac1f5 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Matrix.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/Edit/Tab/Super/Config/Matrix.php @@ -6,10 +6,10 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config; +use Magento\Mtf\Client\Locator; use Magento\Backend\Test\Block\Template; use Magento\Backend\Test\Block\Widget\Form; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Matrix @@ -120,11 +120,11 @@ class Matrix extends Form /** * Assign product to variation matrix * - * @param Element $variationRow + * @param SimpleElement $variationRow * @param int $productId * @return void */ - protected function assignProduct(Element $variationRow, $productId) + protected function assignProduct(SimpleElement $variationRow, $productId) { $variationRow->find($this->configurableAttribute)->click(); $this->getTemplateBlock()->waitLoader(); @@ -142,10 +142,10 @@ class Matrix extends Form public function getVariationsData() { $data = []; - $variationRows = $this->_rootElement->find($this->variationRow, Locator::SELECTOR_XPATH)->getElements(); + $variationRows = $this->_rootElement->getElements($this->variationRow, Locator::SELECTOR_XPATH); foreach ($variationRows as $key => $variationRow) { - /** @var Element $variationRow */ + /** @var SimpleElement $variationRow */ if ($variationRow->isVisible()) { $data[$key] = $this->_getData($this->dataMapping(), $variationRow); $data[$key] += $this->getOptionalFields($variationRow, $this->mappingGetFields); @@ -158,11 +158,11 @@ class Matrix extends Form /** * Get optional fields * - * @param Element $context + * @param SimpleElement $context * @param array $fields * @return array */ - protected function getOptionalFields(Element $context, array $fields) + protected function getOptionalFields(SimpleElement $context, array $fields) { $data = []; diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/FormPageActions.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/FormPageActions.php index e6793ccdc1bc04d1194034afdcd504a433ca78d8..b1822f54f0eb8d131c2cca45748f240a9b0c026e 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/FormPageActions.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/FormPageActions.php @@ -6,8 +6,8 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class FormPageActions diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/ProductForm.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/ProductForm.php index b3b9946ebf78e1c93c253d1922b2d641717adbf4..7a666e370751ac9aaa7e7fed02aecffefd86e524 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/ProductForm.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Adminhtml/Product/ProductForm.php @@ -6,11 +6,12 @@ namespace Magento\ConfigurableProduct\Test\Block\Adminhtml\Product; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Fixture\DataFixture; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; use Magento\Backend\Test\Block\Widget\FormTabs; -use Mtf\Client\Element; -use Mtf\Fixture\DataFixture; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class ProductForm @@ -22,11 +23,11 @@ class ProductForm extends \Magento\Catalog\Test\Block\Adminhtml\Product\ProductF * Fill the product form * * @param FixtureInterface $product - * @param Element|null $element [optional] + * @param SimpleElement|null $element [optional] * @param FixtureInterface|null $category [optional] * @return FormTabs */ - public function fill(FixtureInterface $product, Element $element = null, FixtureInterface $category = null) + public function fill(FixtureInterface $product, SimpleElement $element = null, FixtureInterface $category = null) { $tabs = $this->getFieldsByTabs($product); ksort($tabs); @@ -101,6 +102,7 @@ class ProductForm extends \Magento\Catalog\Test\Block\Adminhtml\Product\ProductF ], ]; unset($tabs['variations']['variations-matrix']); + return $tabs; } } diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View.php index 99d42204d7c3bd92d0a9e07c87e0c77aab8066f8..f7b417ba6583d09a0cbd058a5f36fb56a89d35d7 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\Block\Product; use Magento\ConfigurableProduct\Test\Block\Product\View\ConfigurableOptions; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class View diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View/ConfigurableOptions.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View/ConfigurableOptions.php index 216e2a645230e67cfc01a40b7a42553e3321ad7e..c191f1397062d4c7f8c89dc009f821eb17b74eb9 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View/ConfigurableOptions.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Block/Product/View/ConfigurableOptions.php @@ -9,10 +9,11 @@ namespace Magento\ConfigurableProduct\Test\Block\Product\View; use Magento\Catalog\Test\Block\Product\View\CustomOptions; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class ConfigurableOptions @@ -61,7 +62,7 @@ class ConfigurableOptions extends CustomOptions throw new \Exception("Can't find option: \"{$title}\""); } - /** @var Element $optionElement */ + /** @var SimpleElement $optionElement */ $optionElement = $listOptions[$title]; $typeMethod = preg_replace('/[^a-zA-Z]/', '', $option['frontend_input']); $getTypeData = 'get' . ucfirst(strtolower($typeMethod)) . 'Data'; diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductIsNotDisplayedSeparately.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductIsNotDisplayedSeparately.php index 6ba16adff2697032d2af502f6fe844aff65d1cba..49ed7543a012207c03a8cf3d336c52a984fa122e 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductIsNotDisplayedSeparately.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductIsNotDisplayedSeparately.php @@ -9,7 +9,7 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\CatalogSearch\Test\Page\CatalogsearchResult; use Magento\Cms\Test\Page\CmsIndex; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertChildProductIsNotDisplayedSeparately diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductsInGrid.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductsInGrid.php index 3cb601b648536e8e13fa70768d4bad9f35cb0f09..80446fef978798ea9f7d1b3ea7a9a3757124cabe 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductsInGrid.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertChildProductsInGrid.php @@ -8,7 +8,7 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertChildProductsInGrid diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesAbsentOnProductPage.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesAbsentOnProductPage.php index a2ba3b8d62c3236c78321a1b6ef73aed6f254afa..22695040b347c80306492fe414bfa939a0edd640 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesAbsentOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesAbsentOnProductPage.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that deleted configurable attributes are absent on product page on frontend. @@ -25,14 +25,14 @@ class AssertConfigurableAttributesAbsentOnProductPage extends AbstractConstraint * Assert that deleted configurable attributes are absent on product page on frontend. * * @param CatalogProductAttribute[] $deletedProductAttributes - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param ConfigurableProductInjectable $product * @return void */ public function processAssert( array $deletedProductAttributes, - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, ConfigurableProductInjectable $product ) { diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesBlockIsAbsentOnProductPage.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesBlockIsAbsentOnProductPage.php index 6844bf30090e91c143cbfc4351eb6c8d965fd474..e43779622b8f1b96ea1dd16881d2b9a849becf8a 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesBlockIsAbsentOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableAttributesBlockIsAbsentOnProductPage.php @@ -8,8 +8,8 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that all configurable attributes is absent on product page on frontend. @@ -23,13 +23,13 @@ class AssertConfigurableAttributesBlockIsAbsentOnProductPage extends AbstractCon /** * Assert that all configurable attributes is absent on product page on frontend. * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param ConfigurableProductInjectable $product * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, ConfigurableProductInjectable $product ) { diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductDuplicateForm.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductDuplicateForm.php index 7e8a9bce0120ccd116b3b0b859d2beac33cbadb0..7bc07b5c9907c3cae720dea19f65fb6cdbe9e9c3 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductDuplicateForm.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductDuplicateForm.php @@ -8,7 +8,7 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert form data equals duplicate product configurable data. diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCart.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCart.php index bded697687312df48a1e1c679c33e6cc0f0fcc2d..0cf25ed3ed81e063db68b3078d000ce6ff3e1540 100755 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCart.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCart.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertConfigurableProductInCart @@ -21,14 +21,14 @@ class AssertConfigurableProductInCart extends AbstractConstraint /** * Assertion that the product is correctly displayed in cart * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param CheckoutCart $checkoutCart * @param ConfigurableProductInjectable $product * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, CheckoutCart $checkoutCart, ConfigurableProductInjectable $product diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCustomerWishlistOnBackendGrid.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCustomerWishlistOnBackendGrid.php index d96b2f6eb8cccd4e658fd73b8cf09344ec07e0c4..2b27a259c1eb58a0b45ae59be382ce34646e8936 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCustomerWishlistOnBackendGrid.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInCustomerWishlistOnBackendGrid.php @@ -8,7 +8,7 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; use Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertConfigurableProductInCustomerWishlistOnBackendGrid diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInItemsOrderedGrid.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInItemsOrderedGrid.php index 729f19f2a7655abb1a273c0e54eee74333094d3d..5b7a08c049a62b29896147eed4d8165639acf0cb 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInItemsOrderedGrid.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertConfigurableProductInItemsOrderedGrid.php @@ -8,7 +8,7 @@ namespace Magento\ConfigurableProduct\Test\Constraint; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; use Magento\Sales\Test\Constraint\AssertProductInItemsOrderedGrid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertConfigurableProductInItemsOrderedGrid diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeAbsenceInVariationsSearch.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeAbsenceInVariationsSearch.php index 0b45b5dbed3c36b7e18e88ae352fbef849425838..5a3965dca39c254463b4929455a83091cdda9dde 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeAbsenceInVariationsSearch.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeAbsenceInVariationsSearch.php @@ -11,7 +11,7 @@ use Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Conf use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductAttributeAbsenceInVariationsSearch diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeIsConfigurable.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeIsConfigurable.php index a8c49f6f1774506f8d070ae630575d8c64daa669..402b06c7ab2477c2bafa5be345e37f6b116ad302 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeIsConfigurable.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Constraint/AssertProductAttributeIsConfigurable.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; use Magento\ConfigurableProduct\Test\Block\Adminhtml\Product\Edit\Tab\Super\Config as TabVariation; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert check whether the attribute is used to create a configurable products. diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/Cart/Item.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/Cart/Item.php index 29b62650fa427983e91c464c426c89e1702bff95..80aa5bd293b9fb53aff50688e9673e0502e1e474 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/Cart/Item.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/Cart/Item.php @@ -7,7 +7,7 @@ namespace Magento\ConfigurableProduct\Test\Fixture\Cart; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProduct.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProduct.php index 1be0737898bb5d918f84c70ed2c363a60dd53d67..8dedc818972413912ac5370d92228d8b1b65113a 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProduct.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProduct.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\Fixture; use Magento\Catalog\Test\Fixture\Product; use Magento\Catalog\Test\Fixture\ProductAttribute; use Magento\ConfigurableProduct\Test\Repository\ConfigurableProduct as Repository; -use Mtf\Factory\Factory; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\System\Config; /** * Class ConfigurableProduct diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable.php index b2db8a8a3d851da5fd1d4da69c9782d5c2e7c0e2..99f2309d0d8f327ff1cd770cdbf7f15dc6ff3ef6 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable.php @@ -6,12 +6,12 @@ namespace Magento\ConfigurableProduct\Test\Fixture; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\HandlerFactory; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Config; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Config; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Configurable product fixture. diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable/ConfigurableAttributesData.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable/ConfigurableAttributesData.php index 4a9959eaec9284fd96eadf22455c403819172b26..17e00b49ce77aee73143db957bcf2d738ef85f9d 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable/ConfigurableAttributesData.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Fixture/ConfigurableProductInjectable/ConfigurableAttributesData.php @@ -8,9 +8,9 @@ namespace Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class ConfigurableAttributesData diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/ConfigurableProductInjectableInterface.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/ConfigurableProductInjectableInterface.php index df17a44e65f01a34f28675342af76dee5140d21d..ac4eed63d169f6a81bbc01261cd9b0471f3a2d9e 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/ConfigurableProductInjectableInterface.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/ConfigurableProductInjectableInterface.php @@ -6,7 +6,7 @@ namespace Magento\ConfigurableProduct\Test\Handler\ConfigurableProductInjectable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface ConfigurableProductInjectableInterface diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/Curl.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/Curl.php index 9532613a3425cd0f3e50a91ed7446aa55323b5d8..2a354d1e6d4ae9e06afa006bedea92886dec227a 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/ConfigurableProductInjectable/Curl.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\Handler\ConfigurableProductInjectable use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Handler\CatalogProductSimple\Curl as ProductCurl; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable\ConfigurableAttributesData; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/Curl/CreateConfigurable.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/Curl/CreateConfigurable.php index 4f96c8c35f7ce3700811456040f05b9f05a0cb4e..8b584d3b549605b51b9bf3569654436cfaac18cf 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/Curl/CreateConfigurable.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Handler/Curl/CreateConfigurable.php @@ -8,12 +8,12 @@ namespace Magento\ConfigurableProduct\Test\Handler\Curl; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Create Configurable Product diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Repository/ConfigurableProductInjectable.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Repository/ConfigurableProductInjectable.php index 6de4962e9911a9f6da59bce1ef6e8bf5dfc9a312..aab0344ffb6dc28688290afcd20fd59f228624a7 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Repository/ConfigurableProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/Repository/ConfigurableProductInjectable.php @@ -6,7 +6,7 @@ namespace Magento\ConfigurableProduct\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class ConfigurableProductInjectable diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.php index 20dc365fb548b1aadd0936e0e5170597b8131e5e..95a0ed331c176aceaa5f51c7c5eb21eee69e8f03 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableProductEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\ConfigurableProduct\Test\TestCase; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Coverage for CreateConfigurableProductEntity diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableTest.php index 971ca6fc17d2c1672bae8764d54bba1393a98d71..d2b92908b86e7d2a7258a2be8af7c11fc8331dc1 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateConfigurableTest.php @@ -7,8 +7,8 @@ namespace Magento\ConfigurableProduct\Test\TestCase; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateConfigurableTest diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateWithAttributeTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateWithAttributeTest.php index c273b8db9f6bfa8e7d9b8af22a6558ada6f52d13..6d3a0ebdd9db086512900404c3d9fd8e625964e5 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateWithAttributeTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/CreateWithAttributeTest.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\TestCase; use Magento\Catalog\Test\Fixture\Product; use Magento\Catalog\Test\Fixture\ProductAttribute; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateWithAttributeTest diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/EditConfigurableTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/EditConfigurableTest.php index 3cf47fcf6e0305f365071b5b7113168cf80b5717..568fce2a32a3a329018b95586c7f4e5b61378b0d 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/EditConfigurableTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/EditConfigurableTest.php @@ -6,7 +6,7 @@ namespace Magento\ConfigurableProduct\Test\TestCase; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class EditConfigurableTest diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php index 707dca5ee811644ba2d5f7b5ecec1d1b6ad2a53d..e42c08cd992d2053585932d3020313b5a3f5048d 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestCase/UpdateConfigurableProductEntityTest.php @@ -6,7 +6,7 @@ namespace Magento\ConfigurableProduct\Test\TestCase; -use Mtf\TestCase\Scenario; +use Magento\Mtf\TestCase\Scenario; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestStep/UpdateConfigurableProductStep.php b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestStep/UpdateConfigurableProductStep.php index 46edf7236034ec4cfb6ceb24e3e31a134c7c35aa..d750752c960473b18f70910b70ff29589bb505be 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestStep/UpdateConfigurableProductStep.php +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/TestStep/UpdateConfigurableProductStep.php @@ -9,8 +9,8 @@ namespace Magento\ConfigurableProduct\Test\TestStep; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProductInjectable; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestStep\TestStepInterface; /** * Update configurable product step. diff --git a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/etc/scenario.xml index 5736b9ae666a14e74ad854a7a65e1a2d95aece0b..b53a78e864b816ff2689db034097a86c73975368 100644 --- a/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/ConfigurableProduct/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="UpdateConfigurableProductEntityTest" module="Magento_ConfigurableProduct"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Block/Adminhtml/System/Variable/FormPageActions.php b/dev/tests/functional/tests/app/Magento/Core/Test/Block/Adminhtml/System/Variable/FormPageActions.php index 2a674959d152c954a32a56996c54b12415da4eb6..719bbdc16f03f16378ff08938e13ed34cd02de79 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Block/Adminhtml/System/Variable/FormPageActions.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Block/Adminhtml/System/Variable/FormPageActions.php @@ -7,7 +7,7 @@ namespace Magento\Core\Test\Block\Adminhtml\System\Variable; use Magento\Backend\Test\Block\FormPageActions as AbstractFormPageActions; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class FormPageActions @@ -41,7 +41,7 @@ class FormPageActions extends AbstractFormPageActions * * @param string $storeName * @throws \Exception - * @return void|bool + * @return null|bool */ public function selectStoreView($storeName) { @@ -57,6 +57,8 @@ class FormPageActions extends AbstractFormPageActions } else { throw new \Exception('Store View with name \'' . $storeName . '\' is not visible!'); } - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); + + return null; } } diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Block/Messages.php b/dev/tests/functional/tests/app/Magento/Core/Test/Block/Messages.php index c92ef1060d8604452f5363faa8bf6be5c7385984..c90426413c9254fe321c1ef6adb43ce78cb6b946 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Block/Messages.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Block/Messages.php @@ -6,8 +6,8 @@ namespace Magento\Core\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Global messages block @@ -68,7 +68,7 @@ class Messages extends Block public function getSuccessMessages() { $this->waitForElementVisible($this->successMessage); - $elements = $this->_rootElement->find($this->successMessage)->getElements(); + $elements = $this->_rootElement->getElements($this->successMessage); $messages = []; foreach ($elements as $key => $element) { diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableForm.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableForm.php index b8fe842e0753b289ab1f252de99edb6a2e785f75..331d1d315840e294ee5bec85a8bc8b9a6ffd6700 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableForm.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableForm.php @@ -10,7 +10,7 @@ use Magento\Core\Test\Fixture\SystemVariable; use Magento\Core\Test\Page\Adminhtml\SystemVariableIndex; use Magento\Core\Test\Page\Adminhtml\SystemVariableNew; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertCustomVariableForm diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInGrid.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInGrid.php index 4a1ea3bf6f16549cf72c26e6c7b37e00c412ad2f..399d1cf657923db16ec3becb8a128ffbb2dfaf2a 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Core\Test\Constraint; use Magento\Core\Test\Fixture\SystemVariable; use Magento\Core\Test\Page\Adminhtml\SystemVariableIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomVariableInGrid diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInPage.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInPage.php index 787d76fe15b2d6e2aa1868ca9f9bd76ef0605fa7..ea924d0c9bbb653a6a5ff736b2bb416d009e61f6 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInPage.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableInPage.php @@ -9,9 +9,9 @@ namespace Magento\Core\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Core\Test\Fixture\SystemVariable; use Magento\Store\Test\Fixture\Store; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertCustomVariableInPage @@ -30,7 +30,7 @@ class AssertCustomVariableInPage extends AbstractConstraint * @param CmsIndex $cmsIndex * @param SystemVariable $variable * @param FixtureFactory $fixtureFactory - * @param Browser $browser + * @param BrowserInterface $browser * @param Store $storeOrigin * @param SystemVariable $customVariableOrigin * @return void @@ -40,7 +40,7 @@ class AssertCustomVariableInPage extends AbstractConstraint CmsIndex $cmsIndex, SystemVariable $variable, FixtureFactory $fixtureFactory, - Browser $browser, + BrowserInterface $browser, Store $storeOrigin = null, SystemVariable $customVariableOrigin = null ) { diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInCmsPageForm.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInCmsPageForm.php index e3909d23062cbc465de2a8a8341dcfc580b78fac..ba47a15cbc34d81dc85837eb1ea3fe337aa6148d 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInCmsPageForm.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInCmsPageForm.php @@ -8,7 +8,7 @@ namespace Magento\Core\Test\Constraint; use Magento\Cms\Test\Page\Adminhtml\CmsNew; use Magento\Core\Test\Fixture\SystemVariable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomVariableNotInCmsPageForm diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInGrid.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInGrid.php index ba1bf51c401e1f5e1d6b15394d550c6ecf886e6e..1f7b0a5f6e936f5cddc96bb1a589ab588e87a7aa 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Core\Test\Constraint; use Magento\Core\Test\Fixture\SystemVariable; use Magento\Core\Test\Page\Adminhtml\SystemVariableIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomVariableNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessDeleteMessage.php index ea8310074348001ab0779f14b730da3b93c2740f..f25ff181eb14ab712a860775463ac6765aed7053 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Core\Test\Constraint; use Magento\Core\Test\Page\Adminhtml\SystemVariableIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomVariableSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessSaveMessage.php index 56ca2bf06616c37dca694201266a5b753271f1e0..a6107f10dd3cb1b03b906cd0e9fb6470fea13ac2 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Constraint/AssertCustomVariableSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Core\Test\Constraint; use Magento\Core\Test\Page\Adminhtml\SystemVariableIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomVariableSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/ConfigData.php b/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/ConfigData.php index ef5afdf6641f29284d6c840d64f82a3dda540f59..0dd119e2d360536ac7e540ccb2f1d6822ebe9b11 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/ConfigData.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/ConfigData.php @@ -6,7 +6,7 @@ namespace Magento\Core\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class ConfigData diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/SystemVariable.php b/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/SystemVariable.php index 8671a384d5ff1cb011f7b9ec4838e68053545f2f..5dc92e19efbd6b0001e37691c8cbc4655337f256 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/SystemVariable.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Fixture/SystemVariable.php @@ -6,7 +6,7 @@ namespace Magento\Core\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class SystemVariable diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/ConfigDataInterface.php b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/ConfigDataInterface.php index 46e280e3a7bfb8a4acaf6ca648b7d485e1f339ad..7189e812293c5c57bc88b57a542b68f4157ab533 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/ConfigDataInterface.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/ConfigDataInterface.php @@ -6,7 +6,7 @@ namespace Magento\Core\Test\Handler\ConfigData; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface ConfigDataInterface diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/Curl.php b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/Curl.php index 3f17403f0c09bb7bf556bcca994c6f15aaef9dc6..f2168174fcc827aa57ea68c77f01ca1fe21d7444 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/ConfigData/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Core\Test\Handler\ConfigData; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/Curl.php b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/Curl.php index 43eaa3b5902aec02954857135255e6d5fcbfe188..696d8aca6f0a0cef69d8df72e1de101f1436ed7c 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Core\Test\Handler\SystemVariable; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/SystemVariableInterface.php b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/SystemVariableInterface.php index 03b49763dd3fdf79644101256726169f81a37ad4..342213d9c6141b6082aaf07bbc8f35101186b0ac 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/SystemVariableInterface.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Handler/SystemVariable/SystemVariableInterface.php @@ -6,7 +6,7 @@ namespace Magento\Core\Test\Handler\SystemVariable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface SystemVariableInterface diff --git a/dev/tests/functional/tests/app/Magento/Core/Test/Repository/SystemVariable.php b/dev/tests/functional/tests/app/Magento/Core/Test/Repository/SystemVariable.php index 330590dcb95a49a210cdb1eb81a8d936f3cb5112..4135d0431d54d8786026f075280b0fe88a69e653 100644 --- a/dev/tests/functional/tests/app/Magento/Core/Test/Repository/SystemVariable.php +++ b/dev/tests/functional/tests/app/Magento/Core/Test/Repository/SystemVariable.php @@ -6,7 +6,7 @@ namespace Magento\Core\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class SystemVariable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesAdditional.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesAdditional.php index 809b7ad1d5eef36221a27a6e822e0866d7514c5c..36c96877890735d281c7ecc87b8204ebdf628b76 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesAdditional.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesAdditional.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Block\Account; use Magento\Customer\Test\Fixture\AddressInjectable; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class AddressesAdditional @@ -47,7 +47,7 @@ class AddressesAdditional extends Block { $this->_rootElement->find(sprintf($this->addressSelector, $address->getStreet()), Locator::SELECTOR_XPATH) ->find($this->deleteAddressLink)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesDefault.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesDefault.php index 4995ec61087063241e915b6c273231a34efd4707..61b9e79d94d1fe9bfc187083cfdc74f22a772f4a 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesDefault.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/AddressesDefault.php @@ -6,8 +6,8 @@ */ namespace Magento\Customer\Test\Block\Account; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Addresses default block diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Address.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Address.php index d64bd7ec75bf9590054a96a057ad19f18de2bc84..d9210fe4c9dd462cc702a58a3ed2920c0cf09a1b 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Address.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Address.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Block\Account\Dashboard; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Address diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Info.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Info.php index 80775eacd6055e83cc3eebaa150423eed0450540..752cf03df70ab1684767459e1cfca477cf3fd6f8 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Info.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Dashboard/Info.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Block\Account\Dashboard; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Info diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Links.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Links.php index 3cd43f6a338e64b79516b86d2efce39dea26cace..2f3745944d452571bc1c8081623033d35c38bdd2 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Links.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Account/Links.php @@ -6,8 +6,8 @@ namespace Magento\Customer\Test\Block\Account; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Links diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Address/Edit.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Address/Edit.php index 121323247c3544889c34d4d25f02b96d192b27c1..d5278db123f9a5d6306b4ed916e3446ff63162f4 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Address/Edit.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Address/Edit.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Block\Address; use Magento\Customer\Test\Fixture\Address; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Edit diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/CustomerForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/CustomerForm.php index 0be09cdef87b3d694b4959fdd133da76c6702508..cdf70642bbd4a707fb358cd5ccb08de1ee8d2045 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/CustomerForm.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/CustomerForm.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Block\Adminhtml\Edit; use Magento\Backend\Test\Block\Widget\FormTabs; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CustomerForm diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/Tab/Addresses.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/Tab/Addresses.php index be673d63459615fabeb22b2b567b10faafdecd08..864fbb11f815d45dbb2247475908e2c6f466e254 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/Tab/Addresses.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Adminhtml/Edit/Tab/Addresses.php @@ -8,9 +8,10 @@ namespace Magento\Customer\Test\Block\Adminhtml\Edit\Tab; use Magento\Backend\Test\Block\Widget\Tab; use Magento\Customer\Test\Fixture\AddressInjectable; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Addresses @@ -146,12 +147,12 @@ class Addresses extends Tab * Get data to fields on tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array * * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { /* Skip get data for standard method. Use getDataAddresses. */ return []; @@ -196,6 +197,7 @@ class Addresses extends Tab sprintf($this->customerAddress, $addressNumber), Locator::SELECTOR_XPATH ); + return $addressTab->isVisible(); } } diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php index 4e5506983371786cf705d4cba494cdceb930b2d4..21b2410a61593fc8829bc3c81ffb77b331ba148f 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/CustomerForm.php @@ -6,9 +6,9 @@ namespace Magento\Customer\Test\Block\Form; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Fixture\FixtureInterface; use Magento\Customer\Test\Fixture\CustomerInjectable; /** @@ -51,10 +51,10 @@ class CustomerForm extends Form * Fill the customer data * * @param FixtureInterface $customer - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fill(FixtureInterface $customer, Element $element = null) + public function fill(FixtureInterface $customer, SimpleElement $element = null) { /** @var CustomerInjectable $customer */ if ($customer->hasData()) { diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/ForgotPassword.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/ForgotPassword.php index 3e871afd22a50a3755657a5e72546e29f5775979..b8a9dc7afbdaf6038c2dd52e534931b86db627c4 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/ForgotPassword.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/ForgotPassword.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Block\Form; use Magento\Customer\Test\Fixture\Customer; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** */ diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Login.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Login.php index a2b5b5a6e357fb68c1cc2e3cc64a39d59aeef3ce..2b009be57196041cf519be1179ac42721123c99f 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Login.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Login.php @@ -6,9 +6,9 @@ namespace Magento\Customer\Test\Block\Form; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Login diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Register.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Register.php index a3afdead31092538d9ca58478345fdffbb27eb1d..d5de5868dba76339fe1fc00741d348f9bf65c3d1 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Register.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Block/Form/Register.php @@ -6,9 +6,9 @@ namespace Magento\Customer\Test\Block\Form; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Register diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedBackend.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedBackend.php index ab8cdd7a09d54667b8ba15358664a75fe60cdc5f..6259e116b41a252db5720f27971fa4287dcb241d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedBackend.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedBackend.php @@ -10,7 +10,7 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAddressDeletedBackend diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedFrontend.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedFrontend.php index 59d7c65a957b095ee012479b716feae80270597f..c6cbb07fb13f853d72adc88afe35ae7b53b60128 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertAddressDeletedFrontend.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAddressDeletedFrontend diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertChangePasswordFailMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertChangePasswordFailMessage.php index 78d026849c1c65e5248c77c9dd702438db6d5bf6..8c27d596f972de51eea470cfe2a896a674884ba8 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertChangePasswordFailMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertChangePasswordFailMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertChangePasswordFailMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerAddressSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerAddressSuccessSaveMessage.php index 1c20d0279f4f6930ef7b59b7980e90070b9030eb..ab7ac43f7956c3ce63a90deb354fda0552e03f4d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerAddressSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerAddressSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerAddressSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerDefaultAddresses.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerDefaultAddresses.php index e57976560066a9d62db95ad20839ef77890764d0..3fb0c59976d8e2fdb7d0f8faff7211b8c0dfa7a3 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerDefaultAddresses.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerDefaultAddresses.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerDefaultAddresses diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerFailRegisterMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerFailRegisterMessage.php index c628151dc7688bdedfd97aaa3d6292a5f3b34fd8..36fe9c355c17b72fdf9fd69446753ab5987b9e39 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerFailRegisterMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerFailRegisterMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountCreate; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerFailRegisterMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerForm.php index de31e2f323f2db4386134c74c487c43b2c9c9d08..0c55f3cd04a0641c3a4e1df340a73ebc3b155fb4 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerForm.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerForm.php @@ -10,7 +10,7 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerForm diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupAlreadyExists.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupAlreadyExists.php index 16c8aae67ba77c90f4ea313cca5755d89d580896..8307c220fe220799e7c5ec9286f6506fbef8a4c5 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupAlreadyExists.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupAlreadyExists.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupAlreadyExists diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupForm.php index f868758d3ecb0da9408339dac49d486b25dd1d66..6cc186ea9e5e6782970f7839250e3fc148a0e0bd 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupForm.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupForm.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupForm diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupInGrid.php index 6d51e076e3805a8e307d11c2db20bb0bd5b38ead..1d938173f9ec89dd7a84cc69b8a42746721da49c 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupNotInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupNotInGrid.php index 93e5357f6f90bfa204fe00b529d5d58fda1a83b1..cabf657058a48bbd89c09f448d23b086a48b7460 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupOnCustomerForm.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupOnCustomerForm.php index 784167e2aeafa4d87f37ef7d507a1e7a895ec134..10d3c750d07e3d1d4093cadc8ffcc9c8232cbcf9 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupOnCustomerForm.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupOnCustomerForm.php @@ -10,8 +10,8 @@ use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexNew; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertCustomerGroupOnCustomerForm diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessDeleteMessage.php index 469bb37c53fd159bf266e56e22b47a3dccb17fdc..311a8e0bafbc7cccaa36a0b8c5132d359cb59f7e 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessSaveMessage.php index 4876b0d1bd3285c64476a76f4f4a6de7d016c650..6c32ceb281dc2c2c16084ca2cce279066432bd78 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerGroupSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerGroupSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInGrid.php index 56c20f0a97eb2387ec8dcac5bd3397c915d992fa..569e949e9170a2b086008fb3a84053ba171ae7d0 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInfoSuccessSavedMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInfoSuccessSavedMessage.php index 068def78da9ff50bf2e0d6196aa76f6ae2e6cdc1..6f9d6d9c144ef294d321bbc1e42b06847710e4e6 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInfoSuccessSavedMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInfoSuccessSavedMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerInfoSuccessSavedMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInvalidEmail.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInvalidEmail.php index 83cc134fe2ab0eeae84d23576109871c319b4b6f..63c178507c63c7601f39fb59a995019acb6199be 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInvalidEmail.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerInvalidEmail.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerInvalidEmail diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteInGrid.php index 9e8c1e10099cf2f9cc57032978204ae69ee3f8be..f309e6ac9db5c67187fa266e7664253ec8dc3676 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerMassDeleteInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteNotInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteNotInGrid.php index 163ffab9417b3828dc7d6126cf16ae72a7219985..c2bbd18879b42b3aa8003d93a4f0abff6821da00 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerMassDeleteNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteSuccessMessage.php index 0ca2636625327a3832c0973f9001360936afbe3f..77e7ada00429e917fc98e2b59df09d123f154ed8 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerMassDeleteSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerMassDeleteSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerNotInGrid.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerNotInGrid.php index 42ed108c63b9365c8a0427e0bc9d5965219ff9b1..69104a54536b321bcfe7cf0d284d88d8cbf28c46 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerPasswordChanged.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerPasswordChanged.php index 07ce3870907eb698d0359e1b3dcf6c1efae6fbe1..67e2021c36e6a69dc7657c28274d1dbeb5a1361c 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerPasswordChanged.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerPasswordChanged.php @@ -8,8 +8,8 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Check that login again to frontend with new password was success. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerRedirectToDashboard.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerRedirectToDashboard.php index c77502129d65e2d114503b457fd044cd7a18e671..80a41da9d27a05f19a04ff9736bdac0074f1afe6 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerRedirectToDashboard.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerRedirectToDashboard.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check that after clicking to "Create account" button customer redirected to Dashboard. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessDeleteMessage.php index 4bc212dc9c1f250250be60befad1d4b9db0df4a2..c18809771870908fcbfb48953945c42451cf6028 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessRegisterMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessRegisterMessage.php index 4f3646e6d4a34393b4c249a359abd19d07f3bcc9..3ad80d98d85ed5a89459b2868d2e045dae98576f 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessRegisterMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessRegisterMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountCreate; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerSuccessRegisterMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessSaveMessage.php index c6939cb4d1a6271ebaf685e10d41f2d1f2a1ec97..198d824e70570e78d35ec2f3effd849af10ce03d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertCustomerSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertMassActionSuccessUpdateMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertMassActionSuccessUpdateMessage.php index 9ac88c66c5486f2821a65e4fe2c978da256dcd3b..cdd9c6c2cd2064fe13d79d6d24c99e3135533481 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertMassActionSuccessUpdateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertMassActionSuccessUpdateMessage.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertMassActionSuccessUpdateMessage diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertWrongPassConfirmationMessage.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertWrongPassConfirmationMessage.php index 3deee0d1f818774d3c574ff9c368da77f159a1b0..341c4befe32eb46bc877358129a3f1986ee81f4f 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertWrongPassConfirmationMessage.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Constraint/AssertWrongPassConfirmationMessage.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check that conformation message is present. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Address.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Address.php index 4d141c5eb60ff9dbf3eb3e606fec5f90facbc88c..3419fc5b42e85dbc05a56747275d8533b9f2c261 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Address.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Address.php @@ -6,9 +6,9 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Address diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressBook.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressBook.php index f1e15852d1ccb9583a21a277d0df1ed386a62b19..9ef1a4ea240bb4892f10c2bcab72d77d3c420d49 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressBook.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressBook.php @@ -9,10 +9,10 @@ namespace Magento\Customer\Test\Fixture; /** * Address of registered customer */ -class AddressBook extends \Mtf\Fixture\DataFixture +class AddressBook extends \Magento\Mtf\Fixture\DataFixture { /** - * @var \Mtf\Fixture\DataFixture + * @var \Magento\Mtf\Fixture\DataFixture */ protected $_addressFixture; @@ -26,9 +26,9 @@ class AddressBook extends \Mtf\Fixture\DataFixture /** * Set address fixture * - * @param \Mtf\Fixture\DataFixture $address + * @param \Magento\Mtf\Fixture\DataFixture $address */ - public function setAddress(\Mtf\Fixture\DataFixture $address) + public function setAddress(\Magento\Mtf\Fixture\DataFixture $address) { $this->_addressFixture = $address; } diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressInjectable.php index c021f8acfa48fc8ba50cfa4325c9e2e7914c2cfc..be272903ddeae9dc588845121e7303e2e172c542 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/AddressInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AddressInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Customer.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Customer.php index 01e4950e494ed91e13857db5d13643173187e836..52bd27ee085e32cbbf70fa3d2c3477920d0c504b 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Customer.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/Customer.php @@ -6,8 +6,8 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class Customer diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerBackend.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerBackend.php index 1d51c93d08a4eff949b9e6adfd81827f81090c2a..274b3d8c81f96260826437580159a3917573d7a1 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerBackend.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerBackend.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Customer in Backend diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup.php index 5b461b44136be2fb19049a7f3b2a9676f67d067a..f905b2dca67956e704059cbf9988fbeca84f70fd 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup.php @@ -6,8 +6,8 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class Customer Group Fixture diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup/TaxClassIds.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup/TaxClassIds.php index 08b310d5c17476366927faf98ff8e24c5c80f028..db297d43bb3bbe9165cacff046042e5ea5489fa7 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup/TaxClassIds.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroup/TaxClassIds.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Fixture\CustomerGroup; use Magento\Tax\Test\Fixture\TaxClass; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class TaxClassIds diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroupInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroupInjectable.php index 8367374caf1c035219b8a99fbab6aac6ed8984e7..067628370b1dd00edae62668116500699128ae03 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroupInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerGroupInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CustomerGroupInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable.php index 6a662d177f22821f3ccbc12b7a86ba77461cc201..aa935e1a85c450d16e057eac136fe7eb854bbd02 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class CustomerInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/Address.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/Address.php index e1157be1a9fa051385ea910f3770c1e3bd6a029d..7a5d580c6b4b933c43fa867fa09ba8fce70975e3 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/Address.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/Address.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Fixture\AddressInjectable; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Address diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/GroupId.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/GroupId.php index 91b7c0bdb737d861556eee2d5cea83348f55b88b..1c728b16ec4240b04c7dbbe57e50411116d6f754 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/GroupId.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Fixture/CustomerInjectable/GroupId.php @@ -7,8 +7,8 @@ namespace Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class GroupId diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomer.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomer.php index b51d232c2e63394096261d69cc2b0cc244dfbe56..03e09cebf8e4176843959e8a5b908cdeb3888c5c 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomer.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomer.php @@ -7,10 +7,10 @@ namespace Magento\Customer\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; /** * Class CreateCustomer. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerBackend.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerBackend.php index 8c9535e677a5ab5176a1c2d34cb1fc0ab0e3173e..f2ef96f3636633c2b0b8fdff2cfbc59fac76ed87 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerBackend.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerBackend.php @@ -7,12 +7,12 @@ namespace Magento\Customer\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Curl handler for creating customer in admin diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerGroup.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerGroup.php index 02140bcc66178cfd2761ac18f873381bfa78e63e..4c14cc431138a0934ee3fa327ba8b4513d4b16a6 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerGroup.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/CreateCustomerGroup.php @@ -6,12 +6,12 @@ namespace Magento\Customer\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Curl handler for creating customer group in admin diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/SaveCustomerWithAddress.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/SaveCustomerWithAddress.php index 5e2662520ba4a5b0f19c4d6db882ff9d5aa36607..945abc71934629a461bffd58a534e925ca405305 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/SaveCustomerWithAddress.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Curl/SaveCustomerWithAddress.php @@ -6,10 +6,10 @@ namespace Magento\Customer\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; /** * Curl handler for saving customer address in admin diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/Curl.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/Curl.php index 83b7d6086ad21924e5e10f62bf5dd482e24562fa..bcc05fc52095ef748e54218399dd8b8a60bbcb34 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/Curl.php @@ -7,12 +7,12 @@ namespace Magento\Customer\Test\Handler\CustomerGroupInjectable; use Magento\Backend\Test\Handler\Extractor; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/CustomerGroupInjectableInterface.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/CustomerGroupInjectableInterface.php index a21630e2009ab5730d4eff2da062f3ac88df3c3e..c9388a4daf98ca307b62ea8ec4030db1d52e2d03 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/CustomerGroupInjectableInterface.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerGroupInjectable/CustomerGroupInjectableInterface.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Handler\CustomerGroupInjectable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CustomerGroupInjectableInterface diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/Curl.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/Curl.php index c102f9aac7eedf6de39b497c7e8d848a311d53a8..52b1c48dfbf9eeb96f7a86c67e9a987bb48ee637 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/Curl.php @@ -7,12 +7,12 @@ namespace Magento\Customer\Test\Handler\CustomerInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/CustomerInjectableInterface.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/CustomerInjectableInterface.php index 9c0215484c9c0006c89aacbdac7ba7dfe212679c..a97cbe97367ae6ff0d1d23c08d28507b7c36ae9f 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/CustomerInjectableInterface.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/CustomerInjectable/CustomerInjectableInterface.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Handler\CustomerInjectable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface CustomerInjectableInterface diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Ui/CreateAddress.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Ui/CreateAddress.php index 24a066b4d3ac079030934e5b7a323ff1004cbfff..adc3d2d273153cccee4431f945e09d1790811ee9 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Ui/CreateAddress.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Ui/CreateAddress.php @@ -7,13 +7,13 @@ namespace Magento\Customer\Test\Handler\Ui; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; /** * UI handler for creating customer address. */ -class CreateAddress extends \Mtf\Handler\Ui +class CreateAddress extends \Magento\Mtf\Handler\Ui { /** * Execute handler diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Webapi/CreateCustomer.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Webapi/CreateCustomer.php index 64444bdfa342b927502fa29e94250820a895a401..5d3e2251705e98469dedffe63a03bd5fceb5bdce 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Webapi/CreateCustomer.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Handler/Webapi/CreateCustomer.php @@ -7,9 +7,9 @@ namespace Magento\Customer\Test\Handler\Webapi; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Webapi; -use Mtf\Util\Protocol\SoapTransport; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Webapi; +use Magento\Mtf\Util\Protocol\SoapTransport; /** * Class CreateCustomer diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/Address/DefaultAddress.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/Address/DefaultAddress.php index fb623d168658295e60793b42ce4941a0ed5d2cbe..54b9775dbecbe8d35daf7fd4dae8be061df9d893 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/Address/DefaultAddress.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/Address/DefaultAddress.php @@ -7,9 +7,9 @@ namespace Magento\Customer\Test\Page\Address; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class DefaultAddress diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountForgotPassword.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountForgotPassword.php index a56696efc09dcd6629217ab86a64e4518f6d0c87..ff129b94eb17217dfd85f29dadac635191f7e87c 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountForgotPassword.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountForgotPassword.php @@ -6,9 +6,9 @@ namespace Magento\Customer\Test\Page; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** */ diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountLogout.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountLogout.php index 0bf0bea1b74cb8bb19e0bde9d2442f5376493247..9c34d17af3cd8e4eddac3d3357118ded860902ab 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountLogout.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAccountLogout.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\Page; -use Mtf\Page\Page; +use Magento\Mtf\Page\Page; /** * Class CustomerAccountLogout diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAddressEdit.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAddressEdit.php index 096beeca4a7eb9149d04559408b6f564de0b9840..91fbd97193bbd96f61e384c6adc4f3b952601e6b 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAddressEdit.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Page/CustomerAddressEdit.php @@ -7,9 +7,9 @@ namespace Magento\Customer\Test\Page; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Customer Address Edit page. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.php index 17560e76c41c89a9171cae815e57fbaf53d550fc..6012db8cdd17d501e64154dfe8892b8c14dcc2f3 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Address.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Address Repository diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/AddressInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/AddressInjectable.php index ea198cb5e265bd984bbf59efd74e61342cef807d..e980970452aeaec19f1f353dda59ebf15a449f20 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/AddressInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/AddressInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class AddressInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Customer.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Customer.php index a65111b1185dccc056101453bd2ee9cc43747406..c0d1a73894069fa223618bb90540662338706398 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Customer.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/Customer.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Customer Repository diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroup.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroup.php index 08199c67c04f49a8b53c9971a7c48affb62bba72..a54e62a838b7c31ab4cee723e1f1b39453bc931d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroup.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroup.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Customer Group Repository diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroupInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroupInjectable.php index 6b50700abd593b936616f11f1f51ca876f1661f7..f9ef35f9a952b9f81ecb75d87fad74dad223ffc3 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroupInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerGroupInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CustomerGroupInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerInjectable.php b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerInjectable.php index 13fcff343ea83b6aa7371ea9b1843003a86b6d93..8154cf0f2186fa1755228078d7b1a21458e99e5e 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/Repository/CustomerInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Customer\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class CustomerInjectable diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/BackendCustomerCreateTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/BackendCustomerCreateTest.php index e3733a3423fb7e035e2abb95fa835325b2566b2a..c979cd41c25bb5f14320658cf8b9b4d80958f914 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/BackendCustomerCreateTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/BackendCustomerCreateTest.php @@ -6,8 +6,8 @@ namespace Magento\Customer\Test\TestCase; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; class BackendCustomerCreateTest extends Functional { diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.php index 617ee04eaf95e345efcf6a6361ff21080744ddf3..ec75d23b1047effcd32d0281454ee96f88759c25 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerBackendEntityTest.php @@ -10,7 +10,7 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Coverage for CreateCustomerBackendEntityTest diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php index 82d2fa120f65b3da3f55a638aef5cdd5820b0c8f..8ba1a89d841e71f50afa76ee752b859dfe359f1a 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateCustomerGroupEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateCustomerGroupEntity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateExistingCustomerFrontendEntity.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateExistingCustomerFrontendEntity.php index 56253f8b97fce65f692af214ecd3433975145f69..6ab2dd30c72d30f936d730d848b497c9aafceb7d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateExistingCustomerFrontendEntity.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/CreateExistingCustomerFrontendEntity.php @@ -10,7 +10,7 @@ use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountCreate; use Magento\Customer\Test\Page\CustomerAccountLogout; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateExistingCustomerFrontendEntity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php index 42ff1a7f39d6ac18db91e2eaa40a24c5bd365521..22d2be27760f60955b12b35e13e6a42224480f26 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerAddressTest.php @@ -10,7 +10,7 @@ use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Customer\Test\Page\CustomerAccountLogin; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteCustomerAddress diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerBackendEntityTest.php index f847ee0f4be5db37b337de410da04b35d53dbecb..d6fe3981534da79cca3b0746a0378839a6235e92 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerBackendEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test creation for DeleteCustomerBackendEntity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerGroupEntityTest.php index 1946240cdd9d4248c22d1a2175b4947d5e1bdd32..dda7cbc0c85ec1f6c29d57e8e8f1992e350a4efd 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/DeleteCustomerGroupEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteCustomerGroupEntity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/ForgotPasswordOnFrontendTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/ForgotPasswordOnFrontendTest.php index 9294155fe0b5c0c659c9768f65853a2cc4c4a2f3..b07f1dd1a0388ead172b762f8fb9fd3c3515d26d 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/ForgotPasswordOnFrontendTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/ForgotPasswordOnFrontendTest.php @@ -6,8 +6,8 @@ namespace Magento\Customer\Test\TestCase; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Reset password on frontend diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.php index eee60e547ff936f9c39a754b05e1fd51e12305f6..fa1782e8a4dd8482386f6d0dcabb8e4e656e3b55 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassAssignCustomerGroupTest.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test creation for MassAssignCustomerGroup diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.php index cb0213e5e54b473acbd99365daeb8bd18fc1bf3e..99efcb8300d9fcc46d855fa3adfae58f27062199 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/MassDeleteCustomerBackendEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test creation for MassDeleteCustomerBackendEntityTest diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.php index 377641038f2b0215fd11d96b6d7b45d432eb7d2a..586084a5fa7311d3e26bb68ed24b2c39ddf54981 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/RegisterCustomerFrontendEntityTest.php @@ -10,7 +10,7 @@ use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountCreate; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Page\CustomerAccountLogout; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.php index f3a9a814d187710b3fa0a0382b289fe8788bd7dd..ed3e94fc950aa82507abe5220ab1d31f4147d44b 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerBackendEntityTest.php @@ -10,7 +10,7 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateCustomerBackendEntity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerFrontendEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerFrontendEntityTest.php index e95db553f49d85e1bebf722894e5b2a8a6656d3a..9c1822ed88b7c6e980d717983a4156fc08eff4d6 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerFrontendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerFrontendEntityTest.php @@ -14,8 +14,8 @@ use Magento\Customer\Test\Page\CustomerAccountEdit; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAddressEdit; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php index ded609bad23a96a02a53f3648da509c9498ddf9c..1b544914dce25ec287a23798a134ebb4d29a8f40 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestCase/UpdateCustomerGroupEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerGroupInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerGroupNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update Customer Group Entity diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateCustomerStep.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateCustomerStep.php index 75564372ab8a1851187d35fcc83df1a4af9f9e4d..e3c28182eef964d949f248610151d533b9016fba 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateCustomerStep.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateCustomerStep.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\TestStep; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class CreateCustomerStep diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateOrderFromCustomerAccountStep.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateOrderFromCustomerAccountStep.php index b226fbfbf71bd93f1f9ed88ed7601f55036a0c0f..21d3291f6498a53e1dcbd6ea645e7881cdddaba1 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateOrderFromCustomerAccountStep.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/CreateOrderFromCustomerAccountStep.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\TestStep; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class CreateOrderFromCustomerAccountStep diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LoginCustomerOnFrontendStep.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LoginCustomerOnFrontendStep.php index 12902e16cf98db3d9b63449c4bd021e499811d69..4cc77cfa414dd1b3a7d8550c9938c707b692bb4e 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LoginCustomerOnFrontendStep.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LoginCustomerOnFrontendStep.php @@ -9,7 +9,7 @@ namespace Magento\Customer\Test\TestStep; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountLogin; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Login customer on frontend. diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LogoutCustomerOnFrontendStep.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LogoutCustomerOnFrontendStep.php index b49ea09db7bd665c196669f7687cec5eb9cb6b5d..57fb8c5d9527d6aef60e7d82d67b317bea811a58 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LogoutCustomerOnFrontendStep.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/LogoutCustomerOnFrontendStep.php @@ -7,7 +7,7 @@ namespace Magento\Customer\Test\TestStep; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class LogoutCustomerOnFrontendStep diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/OpenCustomerOnBackendStep.php b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/OpenCustomerOnBackendStep.php index d63e0ba60d96acb7030a79e4d07d234ab67bf514..5182c34ee7cb1f96525f5d882ae21de178059763 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/OpenCustomerOnBackendStep.php +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/TestStep/OpenCustomerOnBackendStep.php @@ -8,7 +8,7 @@ namespace Magento\Customer\Test\TestStep; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class OpenCustomerOnBackendStep diff --git a/dev/tests/functional/tests/app/Magento/Customer/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/Customer/Test/etc/scenario.xml index 1d0c77e04beea4b66604335a0367e990e2b365e9..1ffe25557c9650a4d7af52d4d1da65238208f844 100644 --- a/dev/tests/functional/tests/app/Magento/Customer/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/Customer/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="CreateOrderFromCustomerPageTest" module="Magento_Customer"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable.php index ae20f760c1fcaf3091766e008cad476a1df8ec48..9bb1f70601cd3e2330df8e9dd023e65cafed9713 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable.php @@ -6,9 +6,10 @@ namespace Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Downloadable @@ -35,11 +36,11 @@ class Downloadable extends Tab * Get Downloadable block * * @param string $type - * @param Element $element + * @param SimpleElement $element * @return \Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable\Samples | * \Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable\Links */ - public function getDownloadableBlock($type, Element $element = null) + public function getDownloadableBlock($type, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; return $this->blockFactory->create( @@ -52,10 +53,10 @@ class Downloadable extends Tab * Get data to fields on downloadable tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $newFields = []; if (isset($fields['downloadable_sample']['value'])) { @@ -76,10 +77,10 @@ class Downloadable extends Tab * Fill downloadable information * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (isset($fields['downloadable_sample']['value'])) { $this->getDownloadableBlock('Samples')->fillSamples($fields['downloadable_sample']['value']); diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/LinkRow.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/LinkRow.php index aeae55fd0ecd4cff9b614a88c65c2bca20f10359..3cdd191ec083013eb612085cf0002bbd86fd71a1 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/LinkRow.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/LinkRow.php @@ -5,7 +5,7 @@ */ namespace Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class LinkRow diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php index e6ae647e0ec2104157c532b8c6e85a3d9785a78c..cd799e849f69eb2f382ca4bf674bf588c845696d 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Links.php @@ -5,9 +5,9 @@ */ namespace Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Links @@ -55,10 +55,10 @@ class Links extends Form * Get Downloadable link item block * * @param int $index - * @param Element $element + * @param SimpleElement $element * @return LinkRow */ - public function getRowBlock($index, Element $element = null) + public function getRowBlock($index, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; return $this->blockFactory->create( @@ -71,10 +71,10 @@ class Links extends Form * Fill links block * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return void */ - public function fillLinks(array $fields, Element $element = null) + public function fillLinks(array $fields, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; if (!$element->find($this->title, Locator::SELECTOR_XPATH)->isVisible()) { @@ -98,10 +98,10 @@ class Links extends Form * Get data links block * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataLinks(array $fields = null, Element $element = null) + public function getDataLinks(array $fields = null, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; if (!$element->find($this->title, Locator::SELECTOR_XPATH)->isVisible()) { diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/SampleRow.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/SampleRow.php index 6574b462fe22f582f8fa3b2d0e2fb70af539900e..32e504efe5a40ea22017bf9f1e204e8710873a4e 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/SampleRow.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/SampleRow.php @@ -5,7 +5,7 @@ */ namespace Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class SampleRow diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php index 4a20cda2b606e11b233b66bba468bdaf0101d80e..5678ebd679fbbc179ba717b14214246c368e7730 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Catalog/Product/Edit/Tab/Downloadable/Samples.php @@ -5,9 +5,9 @@ */ namespace Magento\Downloadable\Test\Block\Adminhtml\Catalog\Product\Edit\Tab\Downloadable; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class SampleRow @@ -48,10 +48,10 @@ class Samples extends Form * Get Downloadable sample item block * * @param int $index - * @param Element $element + * @param SimpleElement $element * @return SampleRow */ - public function getRowBlock($index, Element $element = null) + public function getRowBlock($index, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; return $this->blockFactory->create( @@ -64,10 +64,10 @@ class Samples extends Form * Fill samples block * * @param array|null $fields - * @param Element $element + * @param SimpleElement $element * @return void */ - public function fillSamples(array $fields = null, Element $element = null) + public function fillSamples(array $fields = null, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; if (!$element->find($this->samplesTitle, Locator::SELECTOR_XPATH)->isVisible()) { @@ -85,10 +85,10 @@ class Samples extends Form * Get data samples block * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataSamples(array $fields = null, Element $element = null) + public function getDataSamples(array $fields = null, SimpleElement $element = null) { $element = $element ?: $this->_rootElement; if (!$element->find($this->samplesTitle, Locator::SELECTOR_XPATH)->isVisible()) { diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Product/Composite/Configure.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Product/Composite/Configure.php index ec98b6311bc4819d11a4bb27743928dfe09ac89f..db10ef66ce1de8bde5e3d07449c1e89421d559b6 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Product/Composite/Configure.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Adminhtml/Product/Composite/Configure.php @@ -7,7 +7,7 @@ namespace Magento\Downloadable\Test\Block\Adminhtml\Product\Composite; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Configure diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View.php index 9ca97192dd1a76aa3bd890408d1bd6fc8b6e0bbd..c15b0acc3ee5db6504a17bcf122b4006c72a8373 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View.php @@ -7,8 +7,8 @@ namespace Magento\Downloadable\Test\Block\Catalog\Product; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class View diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Links.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Links.php index 1526fce0ebe52f8a163810b4c7f27257c0d9f5b5..fdd0aee5c6c0030f98767b541ad188682d1d5b5a 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Links.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Links.php @@ -6,8 +6,8 @@ namespace Magento\Downloadable\Test\Block\Catalog\Product\View; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Links @@ -110,7 +110,7 @@ class Links extends Block { $linksData = []; - $choiceLinks = $this->_rootElement->find($this->choiceLink, Locator::SELECTOR_XPATH)->getElements(); + $choiceLinks = $this->_rootElement->getElements($this->choiceLink, Locator::SELECTOR_XPATH); foreach ($choiceLinks as $choiceLink) { $link = $choiceLink->find($this->linkForChoice); $sample = $choiceLink->find($this->sampleLinkForChoice); diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Samples.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Samples.php index 8c73611925ee5c27bd4da353729d81430ea5f61d..2adfcbf438299ae42bc189a02473101cf004fe9a 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Samples.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Catalog/Product/View/Samples.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Block\Catalog\Product\View; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Samples @@ -46,7 +46,7 @@ class Samples extends Block */ public function getLinks() { - $links = $this->_rootElement->find($this->linkTitle)->getElements(); + $links = $this->_rootElement->getElements($this->linkTitle); $linksData = []; foreach ($links as $link) { diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Customer/Products/ListProducts.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Customer/Products/ListProducts.php index bc1222135b3d4a55a2184aac60a8560ff8507502..ae55ff3b18fbe3a65bb4013b22eaf06b4ebf0ccb 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Customer/Products/ListProducts.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Block/Customer/Products/ListProducts.php @@ -7,8 +7,8 @@ namespace Magento\Downloadable\Test\Block\Customer\Products; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class ListProducts diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxCalculationAfterCheckoutDownloadable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxCalculationAfterCheckoutDownloadable.php new file mode 100644 index 0000000000000000000000000000000000000000..f8bf3012cfa96847b662a9800f28357f909dc510 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxCalculationAfterCheckoutDownloadable.php @@ -0,0 +1,74 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +use Magento\Checkout\Test\Page\CheckoutCart; +use Magento\Checkout\Test\Page\CheckoutOnepage; +use Magento\Checkout\Test\Page\CheckoutOnepageSuccess; +use Magento\Customer\Test\Fixture\CustomerInjectable; +use Magento\Sales\Test\Page\OrderView; +use Mtf\Fixture\InjectableFixture; +use Magento\Tax\Test\Constraint\AbstractAssertTaxCalculationAfterCheckout; + +/** + * Checks that prices excl tax on order review and customer order pages are equal to specified in dataset. + */ +abstract class AbstractAssertTaxCalculationAfterCheckoutDownloadable extends AbstractAssertTaxCalculationAfterCheckout +{ + /** + * Constraint severeness + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Assert that prices on order review and customer order pages are equal to specified in dataset. + * + * @param array $prices + * @param InjectableFixture $product + * @param CheckoutCart $checkoutCart + * @param CheckoutOnepage $checkoutOnepage + * @param CheckoutOnepageSuccess $checkoutOnepageSuccess + * @param OrderView $orderView + * @return void + */ + public function processAssert( + array $prices, + InjectableFixture $product, + CheckoutCart $checkoutCart, + CheckoutOnepage $checkoutOnepage, + CheckoutOnepageSuccess $checkoutOnepageSuccess, + OrderView $orderView + ) { + $this->checkoutOnepage = $checkoutOnepage; + $this->orderView = $orderView; + + $checkoutCart->getProceedToCheckoutBlock()->proceedToCheckout(); + $checkoutOnepage->getBillingBlock()->clickContinue(); + $checkoutOnepage->getPaymentMethodsBlock()->selectPaymentMethod(['method' => 'check_money_order']); + $checkoutOnepage->getPaymentMethodsBlock()->clickContinue(); + $actualPrices = []; + $actualPrices = $this->getReviewPrices($actualPrices, $product); + $actualPrices = $this->getReviewTotals($actualPrices); + $prices = $this->preparePrices($prices); + //Order review prices verification + $message = 'Prices on order review should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + + $checkoutOnepage->getReviewBlock()->placeOrder(); + $checkoutOnepageSuccess->getSuccessBlock()->getGuestOrderId(); + $checkoutOnepageSuccess->getSuccessBlock()->openOrder(); + $actualPrices = []; + $actualPrices = $this->getOrderPrices($actualPrices, $product); + $actualPrices = $this->getOrderTotals($actualPrices); + + //Frontend order prices verification + $message = 'Prices on order view page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable.php new file mode 100644 index 0000000000000000000000000000000000000000..bd74cdb32ae3b5fc98fccaf33b388ede9db87917 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable.php @@ -0,0 +1,72 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +use Magento\Cms\Test\Page\CmsIndex; +use Magento\Catalog\Test\Page\Category\CatalogCategoryView; +use Magento\Catalog\Test\Page\Product\CatalogProductView; +use Magento\Checkout\Test\Page\CheckoutCart; +use Magento\Tax\Test\Constraint\AbstractAssertTaxRuleIsAppliedToAllPrices; +use Mtf\Fixture\FixtureFactory; +use Mtf\Fixture\InjectableFixture; + +/** + * Checks that product prices excl tax on category, product and cart pages are equal to specified in dataset. + */ +abstract class AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable extends AbstractAssertTaxRuleIsAppliedToAllPrices +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Assert that specified prices are actual on category, product and cart pages. + * + * @param InjectableFixture $product + * @param array $prices + * @param int $qty + * @param CmsIndex $cmsIndex + * @param CatalogCategoryView $catalogCategoryView + * @param CatalogProductView $catalogProductView + * @param CheckoutCart $checkoutCart + * @param FixtureFactory $fixtureFactory + * @return void + */ + public function processAssert( + InjectableFixture $product, + array $prices, + $qty, + CmsIndex $cmsIndex, + CatalogCategoryView $catalogCategoryView, + CatalogProductView $catalogProductView, + CheckoutCart $checkoutCart, + FixtureFactory $fixtureFactory + ) { + $this->cmsIndex = $cmsIndex; + $this->catalogCategoryView = $catalogCategoryView; + $this->catalogProductView = $catalogProductView; + $this->checkoutCart = $checkoutCart; + $actualPrices = []; + //Assertion steps + $productName = $product->getName(); + $productCategory = $product->getCategoryIds()[0]; + $this->openCategory($productCategory); + $actualPrices = $this->getCategoryPrices($productName, $actualPrices); + $catalogCategoryView->getListProductBlock()->openProductViewPage($productName); + $catalogProductView->getViewBlock()->fillOptions($product); + $actualPrices = $this->getProductPagePrices($actualPrices); + $catalogProductView->getViewBlock()->clickAddToCart(); + $actualPrices = $this->getCartPrices($product, $actualPrices); + $actualPrices = $this->getTotals($actualPrices); + //Prices verification + $message = 'Prices from dataset should be equal to prices on frontend'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableDuplicateForm.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableDuplicateForm.php index 75093a3f6a19df2fbebfe6129f85f486f7c949a8..4fc2eadf8a97259729a5fe8e051edcd6bbd84114 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableDuplicateForm.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableDuplicateForm.php @@ -9,7 +9,7 @@ namespace Magento\Downloadable\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductDuplicateForm; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertDownloadableDuplicateForm diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableLinksData.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableLinksData.php index ac485a722142ed98b3c3b712535134eafa3ee6c6..376b7af496f5101ac670b59933ea0a57e6f84b8a 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableLinksData.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableLinksData.php @@ -8,8 +8,8 @@ namespace Magento\Downloadable\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertDownloadableLinksData @@ -48,13 +48,13 @@ class AssertDownloadableLinksData extends AbstractAssertForm * * @param CatalogProductView $catalogProductView * @param DownloadableProductInjectable $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, DownloadableProductInjectable $product, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableProductInCustomerWishlistOnBackendGrid.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableProductInCustomerWishlistOnBackendGrid.php index 3b2d61a5554791d118a851645495ccbdd2a13c8d..e1be5aba24be859a48670d5c650a723c9a528f2c 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableProductInCustomerWishlistOnBackendGrid.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableProductInCustomerWishlistOnBackendGrid.php @@ -8,7 +8,7 @@ namespace Magento\Downloadable\Test\Constraint; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; use Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertDownloadableProductInCustomerWishlistOnBackendGrid diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableSamplesData.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableSamplesData.php index 42321469ce3f556fdc50e9ea8f0811152b20e280..17c1132ce710915a1cd3131ca2056f3184e2895d 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableSamplesData.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertDownloadableSamplesData.php @@ -8,8 +8,8 @@ namespace Magento\Downloadable\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertDownloadableSamplesData @@ -46,13 +46,13 @@ class AssertDownloadableSamplesData extends AbstractAssertForm * * @param CatalogProductView $productView * @param DownloadableProductInjectable $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $productView, DownloadableProductInjectable $product, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..64896843ae68b3b461a90ccd060d8b9d42dc186d --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax.php @@ -0,0 +1,63 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +/** + * Checks that prices excl and incl tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax extends + AbstractAssertTaxCalculationAfterCheckoutDownloadable +{ + /** + * Constraint severeness + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = $reviewBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $reviewBlock->getSubtotalInclTax(); + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $reviewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotalInclTax(); + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..60a4e36293d08ae72d3b49153029ee4ff6fc8cb9 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableExcludingTax.php @@ -0,0 +1,66 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +use Magento\Customer\Test\Fixture\CustomerInjectable; + +/** + * Checks that prices excl tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutDownloadableExcludingTax extends + AbstractAssertTaxCalculationAfterCheckoutDownloadable +{ + /** + * Constraint severeness + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = $reviewBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableIncludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..653b30217dbb1d9fc5c4652b93e1863e7aca336f --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxCalculationAfterCheckoutDownloadableIncludingTax.php @@ -0,0 +1,63 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +/** + * Checks that prices incl tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutDownloadableIncludingTax extends + AbstractAssertTaxCalculationAfterCheckoutDownloadable +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $reviewBlock->getSubtotal(); + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $reviewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotal(); + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..2ea9f0bc5bd24c4244a5a80e510bf907f67d3907 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax.php @@ -0,0 +1,73 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +/** + * Checks that prices excl tax on category, product and cart pages are equal to specified in dataset. + */ +class AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax extends + AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get prices on category page. + * + * @param $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = $priceBlock->getPriceExcludingTax(); + $actualPrices['category_price_incl_tax'] = $priceBlock->getPriceIncludingTax(); + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = $viewBlock->getProductPriceExcludingTax(); + $actualPrices['product_view_price_incl_tax'] = $viewBlock->getProductPriceIncludingTax(); + + return $actualPrices; + } + + /** + * Get totals. + * + * @param $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotalExcludingTax(); + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotalIncludingTax(); + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExcludingTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalIncludingTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..eaa5d5e115f5908ac9449ee4ed5a05e14d30383a --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax.php @@ -0,0 +1,74 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +/** + * Checks that product prices excl tax on category, product and cart pages are equal to specified in dataset. + */ +class AssertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax extends + AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + + /** + * Get prices on category page. + * + * @param $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = $priceBlock->getEffectivePrice(); + $actualPrices['category_price_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = $viewBlock->getPriceBlock()->getEffectivePrice(); + $actualPrices['product_view_price_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get totals. + * + * @param array $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..31fc3a1154b3d669e5e9e406251adda9953b3fd4 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax.php @@ -0,0 +1,73 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Constraint; + +/** + * Checks that prices incl tax on category, product and cart pages are equal to specified in dataset. + */ +class AssertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax extends + AbstractAssertTaxRuleIsAppliedToAllPricesDownloadable +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get prices on category page. + * + * @param string $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = null; + $actualPrices['category_price_incl_tax'] = $priceBlock->getEffectivePrice(); + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = null; + $actualPrices['product_view_price_incl_tax'] = $viewBlock->getPriceBlock()->getEffectivePrice(); + + return $actualPrices; + } + + /** + * Get totals. + * + * @param $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExcludingTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalIncludingTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/Cart/Item.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/Cart/Item.php index c33a55a4e2d45465da9bba4828ff358746f16ed6..6962509496d831b195563ef0c6d7b31dd68b6c1e 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/Cart/Item.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/Cart/Item.php @@ -7,7 +7,7 @@ namespace Magento\Downloadable\Test\Fixture\Cart; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct.php index f4d380731114ad060640bb68bdaaa216b17af516..96407f349a198b4ad375ae801f34981ca95bd8b9 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Fixture; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class DownloadableProduct diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksNotPurchasedSeparately.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksNotPurchasedSeparately.php index c51edf7d793837221d5046c67c2027bdaaf45130..cc71d919ab80285dae4f793a59d493f6ab78d354 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksNotPurchasedSeparately.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksNotPurchasedSeparately.php @@ -5,7 +5,7 @@ */ namespace Magento\Downloadable\Test\Fixture\DownloadableProduct; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class LinksNotPurchasedSeparately diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksPurchasedSeparately.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksPurchasedSeparately.php index c9013f0375e3147e0ff45dd03b2511147b1525a8..0151c23348f831c92dd29d8d6c81e08f24e81d37 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksPurchasedSeparately.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProduct/LinksPurchasedSeparately.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Fixture\DownloadableProduct; use Magento\Downloadable\Test\Fixture\DownloadableProduct; -use Mtf\Factory\Factory; +use Magento\Mtf\Factory\Factory; /** * Class LinksPurchasedSeparately diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable.php index ae72fdb25a22df5ec2f4d12ca3362c4f96c4277b..b7c127fee461f3c8ef3b68e2a69ec48448167515 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class DownloadableProductInjectable @@ -144,7 +144,7 @@ class DownloadableProductInjectable extends InjectableFixture 'default_value' => '', 'input' => 'text', 'group' => 'advanced-pricing', - 'source' => 'Magento\Catalog\Test\Fixture\CatalogProductSimple\GroupPriceOptions', + 'source' => '\Magento\Downloadable\Test\Fixture\DownloadableProductInjectable\GroupPriceOptions' ]; protected $has_options = [ diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/CheckoutData.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/CheckoutData.php index 3607174b0c716bd3e070b285b329e8ecd8394680..6273955c5ba95a1b40d661c01e8192d4de22bcfe 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/CheckoutData.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/CheckoutData.php @@ -80,6 +80,23 @@ class CheckoutData extends \Magento\Catalog\Test\Fixture\CatalogProductSimple\Ch ], ], ], + + 'one_custom_option_and_downloadable_link' => [ + 'options' => [ + 'custom_options' => [ + [ + 'title' => 'attribute_key_0', + 'value' => 'option_key_0' + ], + ], + 'links' => [ + [ + 'label' => 'link_1', + 'value' => 'Yes' + ] + ], + ] + ], ]; return isset($presets[$name]) ? $presets[$name] : []; } diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/GroupPriceOptions.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/GroupPriceOptions.php new file mode 100644 index 0000000000000000000000000000000000000000..2d0b2c8f339dfa6a6f6c3bc64fe96af88a37f836 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/GroupPriceOptions.php @@ -0,0 +1,43 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; + +/** + * Group price options fixture for downloadable product + */ +class GroupPriceOptions extends \Magento\Catalog\Test\Fixture\CatalogProductSimple\GroupPriceOptions +{ + /** + * Get preset array + * + * @param string $name + * @return mixed|null + */ + protected function getPreset($name) + { + $presets = [ + 'default' => [ + [ + 'price' => 20, + 'website' => 'All Websites [USD]', + 'customer_group' => 'NOT LOGGED IN', + ], + ], + 'downloadable_with_tax' => [ + [ + 'price' => 20.00, + 'website' => 'All Websites [USD]', + 'customer_group' => 'General', + ], + ], + ]; + if (!isset($presets[$name])) { + return null; + } + return $presets[$name]; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Links.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Links.php index 54db055d0c8f9bb66e80cc0e4984c44dc5bf4109..89189d993b23508e58b742bd4a369e5d5278fee0 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Links.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Links.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Links diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Samples.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Samples.php index 31ace5f042906e2a03b188625b4dccde669714c7..e7e7a3a1bc878b48d2898f577a9364049f617e2e 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Samples.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Fixture/DownloadableProductInjectable/Samples.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Samples diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/Curl/CreateDownloadable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/Curl/CreateDownloadable.php index 36c4d0570d1898b6c53411f4833ac0d06b272849..34466591d866524a628a65465b7cc584c83c8179 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/Curl/CreateDownloadable.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/Curl/CreateDownloadable.php @@ -5,12 +5,12 @@ */ namespace Magento\Downloadable\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; class CreateDownloadable extends Curl { diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/Curl.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/Curl.php index 2c34a5381e8591295a1f866a933ca7f330ed87d3..fc45d141f131b0fb31aa272322b9d2f8341c90ef 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/Curl.php @@ -7,11 +7,11 @@ namespace Magento\Downloadable\Test\Handler\DownloadableProductInjectable; use Magento\Catalog\Test\Handler\CatalogProductSimple\Curl as ProductCurl; -use Mtf\Fixture\FixtureInterface; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/DownloadableProductInjectableInterface.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/DownloadableProductInjectableInterface.php index af455199b7d0ca9d145bb9320fa93506f4e83edd..04c50ffa5bed5602d181ab6e2b43f8a0964a6b79 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/DownloadableProductInjectableInterface.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Handler/DownloadableProductInjectable/DownloadableProductInjectableInterface.php @@ -5,7 +5,7 @@ */ namespace Magento\Downloadable\Test\Handler\DownloadableProductInjectable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface DownloadableProductInjectableInterface diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Repository/DownloadableProductInjectable.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Repository/DownloadableProductInjectable.php index de7dda22fc1d3b40c3f2a9d1a3c0189ec1f40149..462ff906b32dc9c18db4c1540f7bc9a5357f3d92 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/Repository/DownloadableProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/Repository/DownloadableProductInjectable.php @@ -6,7 +6,7 @@ namespace Magento\Downloadable\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class DownloadableProductInjectable @@ -21,6 +21,7 @@ class DownloadableProductInjectable extends AbstractRepository * @param array $defaultData [optional] * * @SuppressWarnings(PHPMD.UnusedFormalParameter) + * @SuppressWarnings(PHPMD.ExcessiveMethodLength) */ public function __construct(array $defaultConfig = [], array $defaultData = []) { @@ -74,5 +75,65 @@ class DownloadableProductInjectable extends AbstractRepository 'downloadable_links' => ['preset' => 'with_two_separately_links'], 'checkout_data' => ['preset' => 'with_two_bought_links'], ]; + $this->_data['with_two_separately_links_special_price_and_category'] = [ + 'name' => 'Downloadable product %isolation%', + 'sku' => 'downloadable_product_%isolation%', + 'type_id' => 'downloadable', + 'url_key' => 'downloadable-product-%isolation%', + 'price' => ['value' => '30'], + 'special_price' => '20', + 'tax_class_id' => ['dataSet' => 'Taxable Goods'], + 'quantity_and_stock_status' => [ + 'qty' => 1111, + 'is_in_stock' => 'In Stock' + ], + 'status' => 'Product online', + 'category_ids' => ['presets' => 'default'], + 'visibility' => 'Catalog, Search', + 'is_virtual' => 'Yes', + 'website_ids' => ['Main Website'], + 'downloadable_links' => ['preset' => 'with_two_separately_links'], + 'checkout_data' => ['preset' => 'with_two_separately_links'] + ]; + $this->_data['with_two_separately_links_group_price_and_category'] = [ + 'name' => 'Downloadable product %isolation%', + 'sku' => 'downloadable_product_%isolation%', + 'type_id' => 'downloadable', + 'url_key' => 'downloadable-product-%isolation%', + 'price' => ['value' => '30'], + 'group_price' => ['preset' => 'downloadable_with_tax'], + 'tax_class_id' => ['dataSet' => 'Taxable Goods'], + 'quantity_and_stock_status' => [ + 'qty' => 1111, + 'is_in_stock' => 'In Stock' + ], + 'status' => 'Product online', + 'category_ids' => ['presets' => 'default'], + 'visibility' => 'Catalog, Search', + 'is_virtual' => 'Yes', + 'website_ids' => ['Main Website'], + 'downloadable_links' => ['preset' => 'with_two_separately_links'], + 'checkout_data' => ['preset' => 'with_two_separately_links'] + ]; + $this->_data['with_two_separately_links_custom_options_and_category'] = [ + 'name' => 'Downloadable product %isolation%', + 'sku' => 'downloadable_product_%isolation%', + 'type_id' => 'downloadable', + 'url_key' => 'downloadable-product-%isolation%', + 'price' => ['value' => '20'], + 'tax_class_id' => ['dataSet' => 'Taxable Goods'], + 'quantity_and_stock_status' => [ + 'qty' => 1111, + 'is_in_stock' => 'In Stock' + ], + 'status' => 'Product online', + 'category_ids' => ['presets' => 'default'], + 'visibility' => 'Catalog, Search', + 'is_virtual' => 'Yes', + 'website_ids' => ['Main Website'], + 'custom_options' => ['preset' => 'drop_down_with_one_option_percent_price'], + 'downloadable_links' => ['preset' => 'with_two_separately_links'], + 'checkout_data' => ['preset' => 'one_custom_option_and_downloadable_link'] + ]; } } diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/Create/LinksPurchasedSeparatelyTest.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/Create/LinksPurchasedSeparatelyTest.php index d32fc67d1402151f0b8f4a556f3cf6b26b85f7cc..3d92e2ab47b2bb8a98b4c34afaefb901250ba142 100755 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/Create/LinksPurchasedSeparatelyTest.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/Create/LinksPurchasedSeparatelyTest.php @@ -7,8 +7,8 @@ namespace Magento\Downloadable\Test\TestCase\Create; use Magento\Downloadable\Test\Fixture\DownloadableProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class LinksPurchasedSeparatelyTest diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.php index 8f7fa66882f69521a10b0fdded17c5889e820c53..5256ad90ced946d63a7e1b951f3b40bdfb876a15 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/CreateDownloadableProductEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create DownloadableProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php index e53607eecbce7fca0a3009e50f54b9991eaa501d..cdc9b9946008acf1930b2a8c296e885024dc36fa 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/TestCase/UpdateDownloadableProductEntityTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Downloadable\Test\Fixture\DownloadableProductInjectable; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update DownloadableProductEntity diff --git a/dev/tests/functional/tests/app/Magento/Downloadable/Test/etc/constraint.xml b/dev/tests/functional/tests/app/Magento/Downloadable/Test/etc/constraint.xml index 61e5435814dbc77d02cc7553390f97ef10f2b0be..6ada223124d4b220e4447a899d99b036ea926ded 100644 --- a/dev/tests/functional/tests/app/Magento/Downloadable/Test/etc/constraint.xml +++ b/dev/tests/functional/tests/app/Magento/Downloadable/Test/etc/constraint.xml @@ -20,10 +20,37 @@ <require> <productGrid class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex" /> <productPage class="Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit" /> - <product class="Mtf\Fixture\FixtureInterface" /> + <product class="Magento\Mtf\Fixture\FixtureInterface" /> </require> </assertDownloadableDuplicateForm> <assertDownloadableProductInCustomerWishlistOnBackendGrid module="Magento_Downloadable"> <severity>low</severity> </assertDownloadableProductInCustomerWishlistOnBackendGrid> + <assertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesDownloadableExcludingTax> + <assertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesDownloadableIncludingTax> + <assertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesDownloadableExcludingIncludingTax> + <assertTaxCalculationAfterCheckoutDownloadableExcludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutDownloadableExcludingTax> + <assertTaxCalculationAfterCheckoutDownloadableIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutDownloadableIncludingTax> + <assertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutDownloadableExcludingIncludingTax> + <assertOrderTaxOnBackendDownloadableExcludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertOrderTaxOnBackendDownloadableExcludingTax> + <assertOrderTaxOnBackendDownloadableIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertOrderTaxOnBackendDownloadableIncludingTax> + <assertOrderTaxOnBackendDownloadableExcludingIncludingTax module="Magento_Downloadable"> + <severeness>high</severeness> + </assertOrderTaxOnBackendDownloadableExcludingIncludingTax> </constraint> diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Form.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Form.php index 773ec98686742dee1211699c591dba7d3c7aa501..874fcf8b3aac0e930f0ea130f640eb1bcab53bdb 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Form.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Form.php @@ -6,9 +6,9 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\Create; -use Mtf\Block\Form as ParentForm; -use Mtf\Client\Element; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Block\Form as ParentForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Form @@ -27,10 +27,10 @@ class Form extends ParentForm * Fill backend GiftMessage item form. * * @param FixtureInterface $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fill(FixtureInterface $fixture, Element $element = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null) { parent::fill($fixture, $element); $this->_rootElement->find($this->okButton)->click(); diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/GiftOptions.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/GiftOptions.php index 18c8184ddcc0713f4e6842feec78deb04150001c..dc4cd18309225b15af820330550275f99bd0efb3 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/GiftOptions.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/GiftOptions.php @@ -10,7 +10,7 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\Create; * Class GiftOptions * Backend GiftMessage for order form. */ -class GiftOptions extends \Mtf\Block\Form +class GiftOptions extends \Magento\Mtf\Block\Form { // } diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items.php index f106ed84f56577b6fef24fba9f670e198d3ad400..8a607e2a3657aa55a4d71c939714fcc580f8575d 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items.php @@ -7,8 +7,8 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\Create; use Magento\GiftMessage\Test\Block\Adminhtml\Order\Create\Items\ItemProduct; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Items diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php index 4a68cb3ca9b903e2d5d92254b39ffe18731f523b..3627d161b35ab583e5f5c7ab4a1c919d473c2c6c 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php @@ -6,9 +6,8 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\Create\Items; +use Magento\Mtf\Client\Locator; use Magento\GiftMessage\Test\Fixture\GiftMessage; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; /** * Item product block on backend create order page. diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Form.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Form.php index da81852927de79840cc83868d37cbd62c77bf643..48ce7e6ad176174e30a437bae186fb57b5ee46d1 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Form.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Form.php @@ -6,7 +6,7 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\View; -use Mtf\Block\Form as ParentForm; +use Magento\Mtf\Block\Form as ParentForm; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/GiftOptions.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/GiftOptions.php index f2343fe5361c6db112b15ee252339df3c9cb2306..79e0184c7d51f992bfe181eb826111a9aee425a1 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/GiftOptions.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/GiftOptions.php @@ -10,7 +10,7 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\View; * Class GiftOptions * Backend GiftMessage for order from. */ -class GiftOptions extends \Mtf\Block\Form +class GiftOptions extends \Magento\Mtf\Block\Form { // } diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items.php index 6db86ef354ca9dd20c1a48c47e6d34c7ff41c4f8..f6df838ca03bfb52db0485a3ed49f826474adbee 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items.php @@ -7,8 +7,8 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\View; use Magento\GiftMessage\Test\Block\Adminhtml\Order\View\Items\ItemProduct; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Items diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items/ItemProduct.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items/ItemProduct.php index 4495f3a04c98b137fa6f30178cf56e583d422a29..46440c49f3c407bfb6d0040af66457f01357d475 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items/ItemProduct.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Adminhtml/Order/View/Items/ItemProduct.php @@ -6,9 +6,8 @@ namespace Magento\GiftMessage\Test\Block\Adminhtml\Order\View\Items; +use Magento\Mtf\Client\Locator; use Magento\GiftMessage\Test\Fixture\GiftMessage; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; /** * Class ItemProduct diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline.php index b067cfe9f51e595d9e165ed90e9b2fe209f62ce1..0c41872447b7796c0ee47861fa32e44403797dbf 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline.php @@ -7,8 +7,8 @@ namespace Magento\GiftMessage\Test\Block\Message; use Magento\GiftMessage\Test\Fixture\GiftMessage; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Inline diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline/GiftMessageForm.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline/GiftMessageForm.php index 704799a725d8df411530483daf640c9f9108b5fe..2c1a696e6929dc5c6bec4daa66abe309ccb4432a 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline/GiftMessageForm.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Inline/GiftMessageForm.php @@ -6,7 +6,7 @@ namespace Magento\GiftMessage\Test\Block\Message\Inline; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class GiftMessageForm diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Order/Items/View.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Order/Items/View.php index cf13507fe464284c01c3cb20645bee3744dd6436..b3c29e2252085a4470eaeb586d78fe42b8d8109a 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Order/Items/View.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Block/Message/Order/Items/View.php @@ -6,8 +6,8 @@ namespace Magento\GiftMessage\Test\Block\Message\Order\Items; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Gift message block for order's items on order view page. diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInBackendOrder.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInBackendOrder.php index bd5d809d0af4df54c97ba7145dab0d67140933a9..fe543f8c3bdeb468ee24e25d1c1532c31f38d4a7 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInBackendOrder.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInBackendOrder.php @@ -9,7 +9,7 @@ namespace Magento\GiftMessage\Test\Constraint; use Magento\GiftMessage\Test\Fixture\GiftMessage; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertGiftMessageInBackendOrder diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrder.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrder.php index 9e4204a5e4e304da90ca74d95c87f5780ad9ae9b..9a2946618d87a876f28cecf4326c2d5fe90e9dd1 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrder.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrder.php @@ -11,7 +11,7 @@ use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\GiftMessage\Test\Fixture\GiftMessage; use Magento\Sales\Test\Page\OrderHistory; use Magento\Sales\Test\Page\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGiftMessageInFrontendOrder diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrderItems.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrderItems.php index 693e0fa892463ce2116532647b7d943a280fccc7..09c931ac7a31d4c762cd4f48924b4c242417e7a7 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrderItems.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Constraint/AssertGiftMessageInFrontendOrderItems.php @@ -11,7 +11,7 @@ use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\GiftMessage\Test\Fixture\GiftMessage; use Magento\Sales\Test\Page\OrderHistory; use Magento\Sales\Test\Page\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGiftMessageInFrontendOrderItems diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage.php index 6e65e3ae4fe7b058b00500d1695c1e9269ea02d7..d5857c0b99c216753009c80645559d79ee63fbc8 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage.php @@ -6,7 +6,7 @@ namespace Magento\GiftMessage\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class GiftMessage diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage/Items.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage/Items.php index bff6852923d24f4bc0f2e22f49ff85265da751ef..d53cc71937440951f1334e325d5fb514b1c504ab 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage/Items.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Fixture/GiftMessage/Items.php @@ -6,8 +6,8 @@ namespace Magento\GiftMessage\Test\Fixture\GiftMessage; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Items diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Repository/GiftMessage.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Repository/GiftMessage.php index 436fee4c6bcd0817dddcb6c00379603573a1765a..c0aae33db525f0b1a690d436859bea25ffc476bd 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Repository/GiftMessage.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/Repository/GiftMessage.php @@ -6,7 +6,7 @@ namespace Magento\GiftMessage\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class GiftMessage diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageBackendStep.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageBackendStep.php index 793ac9f616e832f05d6446ff9ce64fc3ff9ebb8e..18848d9e75d2cb6c1974f15e874aec73599f12a6 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageBackendStep.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageBackendStep.php @@ -8,7 +8,7 @@ namespace Magento\GiftMessage\Test\TestStep; use Magento\GiftMessage\Test\Fixture\GiftMessage; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class AddGiftMessageBackendStep diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageStep.php b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageStep.php index 2e1cabbb6545067b901cc7f459c5a1c3eb138ee7..190de05c9eecdf1d89c29a6aeea3cc18416de37e 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageStep.php +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/TestStep/AddGiftMessageStep.php @@ -8,7 +8,7 @@ namespace Magento\GiftMessage\Test\TestStep; use Magento\Checkout\Test\Page\CheckoutOnepage; use Magento\GiftMessage\Test\Fixture\GiftMessage; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class AddGiftMessageStep diff --git a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/etc/scenario.xml index 27b48d7e39f72cb612b8cf04ada12d0894bac281..71282278e78b01ffea89c26e43056ecb8d6bc1c5 100644 --- a/dev/tests/functional/tests/app/Magento/GiftMessage/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/GiftMessage/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="CheckoutWithGiftMessagesTest" module="Magento_GiftMessage"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Block/Adminhtml/Types/Edit/GoogleShoppingForm.php b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Block/Adminhtml/Types/Edit/GoogleShoppingForm.php index fb13e2063d0ad701189597bbec4e5ac2cefca501..dcf5ad4f512e480c9a79567d526e05003a46d170 100644 --- a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Block/Adminhtml/Types/Edit/GoogleShoppingForm.php +++ b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Block/Adminhtml/Types/Edit/GoogleShoppingForm.php @@ -6,9 +6,9 @@ namespace Magento\GoogleShopping\Test\Block\Adminhtml\Types\Edit; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class GoogleShoppingForm @@ -34,10 +34,10 @@ class GoogleShoppingForm extends Form * Fill specified form data * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return void */ - protected function _fill(array $fields, Element $element = null) + protected function _fill(array $fields, SimpleElement $element = null) { $context = ($element === null) ? $this->_rootElement : $element; foreach ($fields as $field) { @@ -87,7 +87,7 @@ class GoogleShoppingForm extends Form */ protected function getOptions() { - $elements = $this->_rootElement->find($this->attributeOptions, Locator::SELECTOR_XPATH)->getElements(); + $elements = $this->_rootElement->getElements($this->attributeOptions, Locator::SELECTOR_XPATH); $options = []; foreach ($elements as $key => $element) { diff --git a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Constraint/AssertProductAttributeAbsenceForAttributeMapping.php b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Constraint/AssertProductAttributeAbsenceForAttributeMapping.php index 37ce5a91a8c578d396ebec640460e9fba19fa174..7177cd74856af71e12a52bc5ac80992869a41e2f 100644 --- a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Constraint/AssertProductAttributeAbsenceForAttributeMapping.php +++ b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Constraint/AssertProductAttributeAbsenceForAttributeMapping.php @@ -9,8 +9,8 @@ namespace Magento\GoogleShopping\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; use Magento\GoogleShopping\Test\Page\Adminhtml\GoogleShoppingTypesIndex; use Magento\GoogleShopping\Test\Page\Adminhtml\GoogleShoppingTypesNew; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertProductAttributeAbsenceForAttributeMapping diff --git a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute.php b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute.php index dcfa2ffe5ff364a5e25ea2a2fccc4439965e0dcf..88734fe6eb2ef2d48054e8b29e24fef7b77eb1c6 100644 --- a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute.php +++ b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute.php @@ -6,7 +6,7 @@ namespace Magento\GoogleShopping\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class GoogleShoppingAttribute diff --git a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute/AttributeSetId.php b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute/AttributeSetId.php index 2cb95ff70ccd41f790b37eab92a6b1f294b9688e..cfaf1d46249e040ed7ce1632d72addfd245ee75c 100644 --- a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute/AttributeSetId.php +++ b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Fixture/GoogleShoppingAttribute/AttributeSetId.php @@ -7,8 +7,8 @@ namespace Magento\GoogleShopping\Test\Fixture\GoogleShoppingAttribute; use Magento\Catalog\Test\Fixture\CatalogAttributeSet; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AttributeSetId diff --git a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Repository/GoogleShoppingAttribute.php b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Repository/GoogleShoppingAttribute.php index a7977ac9b2c197bbd9e7e8ee193c3ebb24fd91be..cbf687a07409e6f3abe18bdff066d386796bdd30 100644 --- a/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Repository/GoogleShoppingAttribute.php +++ b/dev/tests/functional/tests/app/Magento/GoogleShopping/Test/Repository/GoogleShoppingAttribute.php @@ -6,7 +6,7 @@ namespace Magento\GoogleShopping\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class GoogleShoppingAttribute diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Composite/Configure.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Composite/Configure.php index df8cf85c629de6dcfb03a38b5ca6f035a5b6997b..11da495aceed0a9a2b98bb4e9e0f1ecee6a68ef3 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Composite/Configure.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Composite/Configure.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Block\Adminhtml\Product\Composite; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Configure diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts.php index 06f553e19358648bdbe5e4a99d97d2e1ef41eef1..037331074bd67e80d91100360b4381f7dfb3c200 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts.php @@ -7,8 +7,9 @@ namespace Magento\GroupedProduct\Test\Block\Adminhtml\Product\Grouped; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; /** * Class AssociatedProducts @@ -74,15 +75,15 @@ class AssociatedProducts extends Tab * Fill data to fields on tab * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { if (isset($fields['associated'])) { - $options = $this->_rootElement->find($this->deleteButton)->getElements(); + $options = $this->_rootElement->getElements($this->deleteButton); if (count($options)) { - foreach ($options as $option) { + foreach (array_reverse($options) as $option) { $option->click(); } } @@ -101,10 +102,10 @@ class AssociatedProducts extends Tab * Get data to fields on group tab * * @param array|null $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return array */ - public function getDataFormTab($fields = null, Element $element = null) + public function getDataFormTab($fields = null, SimpleElement $element = null) { $newFields = []; if (isset($fields['associated'])) { diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php index e5d4641eca230f9724a8385f366698f0d61855eb..1151e76c0324da4b3f05a6683a4f127b4a751893 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts.php @@ -6,9 +6,8 @@ namespace Magento\GroupedProduct\Test\Block\Adminhtml\Product\Grouped\AssociatedProducts; -use Mtf\Block\Form; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class ListAssociatedProducts diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php index 34dd3ac6333e8907293f2c4327cd25f0d0b7efe0..f7a644f9d9386db21ecaadf47a222815a2b9ab96 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/ListAssociatedProducts/Product.php @@ -6,7 +6,7 @@ namespace Magento\GroupedProduct\Test\Block\Adminhtml\Product\Grouped\AssociatedProducts\ListAssociatedProducts; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Product diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/Search/Grid.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/Search/Grid.php index 86a0e3a5a0e2283d5fe89c5946a10644cd1479a0..f40ea0ad580ae254ceebc9423bddbaefe1c593a9 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/Search/Grid.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Adminhtml/Product/Grouped/AssociatedProducts/Search/Grid.php @@ -7,7 +7,6 @@ namespace Magento\GroupedProduct\Test\Block\Adminhtml\Product\Grouped\AssociatedProducts\Search; use Magento\Backend\Test\Block\Widget\Grid as GridInterface; -use Mtf\Client\Element; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View.php index 710eb38c9e7b3ea0209a3edd2f6b6bc8dcb5187f..fd8184a473a931c9b2504de28c5226000842ffd9 100755 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Block\Catalog\Product; use Magento\Catalog\Test\Block\Product\View as ParentView; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class View diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View/Type/Grouped.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View/Type/Grouped.php index e32363960d5001b713f43cd5f8933ba58f0e58b2..0cacb9adcf16618694af9a0f559d7430c34943c8 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View/Type/Grouped.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Catalog/Product/View/Type/Grouped.php @@ -9,10 +9,10 @@ namespace Magento\GroupedProduct\Test\Block\Catalog\Product\View\Type; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\GroupedProduct\Test\Fixture\GroupedProduct; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Grouped diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart.php index 3a6e060af8075b5fec918493612d1e06553eea7b..3826d9a341e5d45c3c36545e8f5fd5450bee6aa9 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Block\Checkout; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Cart diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart/CartItem.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart/CartItem.php index 010a45b9aaaa90aef81abc2058d67061fb09ec8d..72674513efd9ab4e5341f989d970d98ff306bdb5 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart/CartItem.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Block/Checkout/Cart/CartItem.php @@ -116,7 +116,6 @@ class CartItem extends AbstractCartItem { foreach ($this->config['associated_cart_items'] as $cartItem) { /** @var CheckoutCartItem $cartItem */ - $cartItem->reinitRootElement(); $cartItem->removeItem(); } } diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AbstractAssertPriceOnGroupedProductPage.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AbstractAssertPriceOnGroupedProductPage.php index eaa50598d87bb1bf40dd23f6634cc0775e90da99..5627b7785a3be4f37aa9c721a545d8403c10a35d 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AbstractAssertPriceOnGroupedProductPage.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AbstractAssertPriceOnGroupedProductPage.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Constraint\AssertPriceOnProductPageInterface; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that displayed grouped price on product page equals passed from fixture. @@ -38,7 +38,7 @@ abstract class AbstractAssertPriceOnGroupedProductPage extends AbstractConstrain * @param GroupedProductInjectable $product * @param CatalogProductView $catalogProductView * @param AssertPriceOnProductPageInterface $object - * @param Browser $browser + * @param BrowserInterface $browser * @param string $typePrice [optional] * @return bool|string */ @@ -46,7 +46,7 @@ abstract class AbstractAssertPriceOnGroupedProductPage extends AbstractConstrain GroupedProductInjectable $product, CatalogProductView $catalogProductView, AssertPriceOnProductPageInterface $object, - Browser $browser, + BrowserInterface $browser, $typePrice = '' ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedPriceOnGroupedProductPage.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedPriceOnGroupedProductPage.php index 3e1072cf877414b1f7751475b926bf838570d065..d471c60f1eed2871a60357f153d3735fb685a9a2 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedPriceOnGroupedProductPage.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedPriceOnGroupedProductPage.php @@ -9,7 +9,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductGroupedPriceOnProductPage; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Client\Browser; +use Magento\Mtf\Client\BrowserInterface; /** * Class AssertGroupedPriceOnGroupedProductPage @@ -41,14 +41,14 @@ class AssertGroupedPriceOnGroupedProductPage extends AbstractAssertPriceOnGroupe * @param CatalogProductView $catalogProductView * @param GroupedProductInjectable $product * @param AssertProductGroupedPriceOnProductPage $groupedPrice - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, GroupedProductInjectable $product, AssertProductGroupedPriceOnProductPage $groupedPrice, - Browser $browser + BrowserInterface $browser ) { $this->processAssertPrice($product, $catalogProductView, $groupedPrice, $browser); } diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductForm.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductForm.php index 974ba950e37f1756063454c4827e2db360a627f0..fe78ef841ca38bac22f7c4897240da6b7b6a875a 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductForm.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductForm.php @@ -9,7 +9,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductForm; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertGroupedProductForm diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInCustomerWishlistOnBackendGrid.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInCustomerWishlistOnBackendGrid.php index 44be1c0072b5bb12aa5fceaf703c72c02f2c959c..4128f39dede6b63814f80c4fff5fd57aee08ca52 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInCustomerWishlistOnBackendGrid.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInCustomerWishlistOnBackendGrid.php @@ -8,7 +8,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; use Magento\Wishlist\Test\Constraint\AssertProductInCustomerWishlistOnBackendGrid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertGroupedProductInCustomerWishlistOnBackendGrid diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInItemsOrderedGrid.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInItemsOrderedGrid.php index 122ee4e04d1be2234df1540a5d051dc1d9d5ac0c..c91d1af7add20f758ed1867ecd5957c46c91a4d3 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInItemsOrderedGrid.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductInItemsOrderedGrid.php @@ -8,7 +8,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Sales\Test\Block\Adminhtml\Order\Create\Items; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertGroupedProductInItemsOrderedGrid diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductsDefaultQty.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductsDefaultQty.php index 48e97bb209f6917fa39a08c3d18222e0292c7e63..0ec0c06eff5b80b56e0b9446f645dfa954651c15 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductsDefaultQty.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertGroupedProductsDefaultQty.php @@ -8,8 +8,8 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertGroupedProductsDefaultQty @@ -26,13 +26,13 @@ class AssertGroupedProductsDefaultQty extends AbstractAssertForm * * @param CatalogProductView $groupedProductView * @param GroupedProductInjectable $product - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $groupedProductView, GroupedProductInjectable $product, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); $associatedProducts = $product->getAssociated(); diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertSpecialPriceOnGroupedProductPage.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertSpecialPriceOnGroupedProductPage.php index f68082aef3d42e5d9254a27c5714543bd26092da..0fd5cdd5b924ac567da439a7740e7745e022d853 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertSpecialPriceOnGroupedProductPage.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertSpecialPriceOnGroupedProductPage.php @@ -9,7 +9,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductSpecialPriceOnProductPage; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Client\Browser; +use Magento\Mtf\Client\BrowserInterface; /** * Class AssertSpecialPriceOnGroupedProductPage @@ -40,14 +40,14 @@ class AssertSpecialPriceOnGroupedProductPage extends AbstractAssertPriceOnGroupe * @param CatalogProductView $catalogProductView * @param GroupedProductInjectable $product * @param AssertProductSpecialPriceOnProductPage $specialPrice - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, GroupedProductInjectable $product, AssertProductSpecialPriceOnProductPage $specialPrice, - Browser $browser + BrowserInterface $browser ) { $this->processAssertPrice($product, $catalogProductView, $specialPrice, $browser); } diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertTierPriceOnGroupedProductPage.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertTierPriceOnGroupedProductPage.php index 86f1d5af2813213d96309ee1c10df690522d4f6e..c640d5b6aa25babf59f75d463715ea0851f499b5 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertTierPriceOnGroupedProductPage.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Constraint/AssertTierPriceOnGroupedProductPage.php @@ -9,7 +9,7 @@ namespace Magento\GroupedProduct\Test\Constraint; use Magento\Catalog\Test\Constraint\AssertProductTierPriceOnProductPage; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Client\Browser; +use Magento\Mtf\Client\BrowserInterface; /** * Class AssertTierPriceOnGroupedProductPage @@ -41,14 +41,14 @@ class AssertTierPriceOnGroupedProductPage extends AbstractAssertPriceOnGroupedPr * @param CatalogProductView $catalogProductView * @param GroupedProductInjectable $product * @param AssertProductTierPriceOnProductPage $tierPrice - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, GroupedProductInjectable $product, AssertProductTierPriceOnProductPage $tierPrice, - Browser $browser + BrowserInterface $browser ) { $this->processAssertPrice($product, $catalogProductView, $tierPrice, $browser, 'Tier'); } diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/Cart/Item.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/Cart/Item.php index 5b6988cfa0efd11c53842e4cf38334a035186d99..3e91ccb257870bb4a156f51c5094df152599c373 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/Cart/Item.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/Cart/Item.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Fixture\Cart; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProduct.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProduct.php index e53b8efd41061261cb786e6160c82fdd90b07e69..1a9779e60448d82d05da3b17bf4a21bbf38cc6e7 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProduct.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProduct.php @@ -7,8 +7,8 @@ namespace Magento\GroupedProduct\Test\Fixture; use Magento\Catalog\Test\Fixture\Product; -use Mtf\Factory\Factory; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\System\Config; /** * Class GroupedProduct diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable.php index 8cdbacd0153c4fe686185709b1b006ce6afa1256..3f1d1d5f4dc73d984ce79814c023ca5fd1d60c83 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable.php @@ -6,12 +6,12 @@ namespace Magento\GroupedProduct\Test\Fixture; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\HandlerFactory; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Config; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Config; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Class GroupedProductInjectable diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Associated.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Associated.php index 416c89c7287aa26fa366ac99354a3b622f2fcfe5..4065bfa0221ab4455b515fe7eee31efd33891a00 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Associated.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Associated.php @@ -6,9 +6,9 @@ namespace Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Associated diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Price.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Price.php index 017b60e5a8d04bb41c60c45dcabc332fb142e658..b6811384f498b87a05949632188875636d57d284 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Price.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Fixture/GroupedProductInjectable/Price.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; use Magento\Catalog\Test\Fixture\CatalogProductSimple\Price as ParentPrice; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Price diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/Curl.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/Curl.php index fe470516ed1ce6c10cbffec3054fb832ef6b128c..1880721ab7e36c20818cfb94ace4f403634bceeb 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/Curl.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/Curl.php @@ -7,7 +7,7 @@ namespace Magento\GroupedProduct\Test\Handler\GroupedProductInjectable; use Magento\Catalog\Test\Handler\CatalogProductSimple\Curl as AbstractCurl; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/GroupedProductInjectableInterface.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/GroupedProductInjectableInterface.php index a3fdc3388de8f20ab5fc756954f399c4f41ca96f..59a19e47ffd54a00dd67f5d670f8ccf0607c93f4 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/GroupedProductInjectableInterface.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Handler/GroupedProductInjectable/GroupedProductInjectableInterface.php @@ -6,7 +6,7 @@ namespace Magento\GroupedProduct\Test\Handler\GroupedProductInjectable; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface GroupedProductInjectableInterface diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Repository/GroupedProductInjectable.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Repository/GroupedProductInjectable.php index 4d70d99c53e2bd58171d51d5348b51838d09311f..54f00cd5e1f89875ba671e043ec7ac6d9f26211e 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Repository/GroupedProductInjectable.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/Repository/GroupedProductInjectable.php @@ -6,7 +6,7 @@ namespace Magento\GroupedProduct\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class GroupedProductInjectable diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.php index 7644612df2db1a0905f7682e32528523cf9d2286..722034257409954a952dac5d5dae17214608a5aa 100755 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedProductEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductNew; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateGroupedProductEntity diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedTest.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedTest.php index 4acbf23ba517e9a6f3fae1b4723ba95fe7ecd7b8..0c59909268d2bb1b5ca84d121ace20acf7794769 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedTest.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/CreateGroupedTest.php @@ -7,8 +7,8 @@ namespace Magento\GroupedProduct\Test\TestCase; use Magento\GroupedProduct\Test\Fixture\GroupedProduct; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; /** * Class CreateGroupedTest diff --git a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.php b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.php index 5628179fcbc7c29ca581d4a9ad8d9596375c9bed..a437d49447bf087889e782e0b82d06d888466a56 100644 --- a/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/GroupedProduct/Test/TestCase/UpdateGroupedProductEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\GroupedProduct\Test\TestCase; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductEdit; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; use Magento\GroupedProduct\Test\Fixture\GroupedProductInjectable; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update GroupedProductEntity diff --git a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Block/Adminhtml/Export/Edit/Form.php b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Block/Adminhtml/Export/Edit/Form.php index 3a6c6f623ff881dad308f1b53581b7a8eca354ec..7073a781039ea74f438d5db43c9d0cdd3cdc0d2e 100644 --- a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Block/Adminhtml/Export/Edit/Form.php +++ b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Block/Adminhtml/Export/Edit/Form.php @@ -6,7 +6,7 @@ namespace Magento\ImportExport\Test\Block\Adminhtml\Export\Edit; -use Mtf\Block\Form as AbstractForm; +use Magento\Mtf\Block\Form as AbstractForm; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Constraint/AssertProductAttributeAbsenceForExport.php b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Constraint/AssertProductAttributeAbsenceForExport.php index 2ad78d38fe59470fa34b7d6c541e75653a2a779c..db5002a395008cb6b75a2d9c55e669c643e4e0ce 100644 --- a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Constraint/AssertProductAttributeAbsenceForExport.php +++ b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Constraint/AssertProductAttributeAbsenceForExport.php @@ -9,7 +9,7 @@ namespace Magento\ImportExport\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductAttribute; use Magento\ImportExport\Test\Fixture\ImportExport; use Magento\ImportExport\Test\Page\Adminhtml\AdminExportIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAbsenceProductAttributeForExport diff --git a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Fixture/ImportExport.php b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Fixture/ImportExport.php index c825aff87c6b4bd4047ce98c3444c282c6c51ee7..e45bd649867d2f49d666f7a2438e22ca30be4641 100644 --- a/dev/tests/functional/tests/app/Magento/ImportExport/Test/Fixture/ImportExport.php +++ b/dev/tests/functional/tests/app/Magento/ImportExport/Test/Fixture/ImportExport.php @@ -6,7 +6,7 @@ namespace Magento\ImportExport\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class ImportExport diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/CreateAdmin.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/CreateAdmin.php index ac62896eea14910aac7d042d26ecbe6ddf7c821d..549d7d2b9b3a6899dae252096b1d232307588f9e 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/CreateAdmin.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/CreateAdmin.php @@ -6,8 +6,10 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Create Admin Account block. @@ -21,6 +23,13 @@ class CreateAdmin extends Form */ protected $next = "[ng-click*='next']"; + /** + * First field selector + * + * @var string + */ + protected $firstField = '[name="adminUsername"]'; + /** * Click on 'Next' button. * @@ -30,4 +39,17 @@ class CreateAdmin extends Form { $this->_rootElement->find($this->next, Locator::SELECTOR_CSS)->click(); } + + /** + * Ensure the form is loaded and fill the root form + * + * @param FixtureInterface $fixture + * @param SimpleElement|null $element + * @return $this + */ + public function fill(FixtureInterface $fixture, SimpleElement $element = null) + { + $this->waitForElementVisible($this->firstField); + return parent::fill($fixture, $element); + } } diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/CustomizeStore.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/CustomizeStore.php index 220775d9ec536cc84aa755db8ed4ef809a8f803e..c6f992c5dfba1aebdff011d121d380e04c6b28c1 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/CustomizeStore.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/CustomizeStore.php @@ -6,8 +6,10 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Customize Your Store block. @@ -21,6 +23,13 @@ class CustomizeStore extends Form */ protected $next = "[ng-click*='next']"; + /** + * First field selector + * + * @var string + */ + protected $firstField = '[ng-model*="language"]'; + /** * Click on 'Next' button. * @@ -30,4 +39,17 @@ class CustomizeStore extends Form { $this->_rootElement->find($this->next, Locator::SELECTOR_CSS)->click(); } + + /** + * Ensure the form is loaded and fill the root form + * + * @param FixtureInterface $fixture + * @param SimpleElement|null $element + * @return $this + */ + public function fill(FixtureInterface $fixture, SimpleElement $element = null) + { + $this->waitForElementVisible($this->firstField); + return parent::fill($fixture, $element); + } } diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Database.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Database.php index 3db7157b6f5f3446fe0d7d3774cbf9ea0fd54199..e1efe0955d55b1affbec3bd5ecce0045617dad7a 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Database.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Database.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Database form. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Install.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Install.php index ae12c3c6f16c40de6a369b20679545ce9def5da9..40ae967bfd54c2625a437282902df31fefc8c057 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Install.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Install.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Install block. @@ -61,9 +61,9 @@ class Install extends Block public function getAdminInfo() { $adminData = []; - $rows = $this->_rootElement->find('#admin-info .row')->getElements(); + $rows = $this->_rootElement->getElements('#admin-info .row'); foreach ($rows as $row) { - $dataRow = $row->find('div')->getElements(); + $dataRow = $row->getElements('div'); $key = strtolower(str_replace(' ', '_', str_replace(':', '', $dataRow[0]->getText()))); $adminData[$key] = $dataRow[1]->getText(); } @@ -79,9 +79,9 @@ class Install extends Block public function getDbInfo() { $dbData = []; - $rows = $this->_rootElement->find('#db-info .row')->getElements(); + $rows = $this->_rootElement->getElements('#db-info .row'); foreach ($rows as $row) { - $dataRow = $row->find('div')->getElements(); + $dataRow = $row->getElements('div'); $key = strtolower(str_replace(' ', '_', str_replace(':', '', $dataRow[0]->getText()))); $dbData[$key] = $dataRow[1]->getText(); } diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Landing.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Landing.php index 583d3f71de93007724f750164b788ed1b7b57621..8f3ddadef7e8d49b309de7069fd5e0c4071f1b41 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Landing.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Landing.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Landing block. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/License.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/License.php index a8d396a67826672945c51be72a44efaaeeae14f4..08f7f40dbffbf9d436989ba3ddb007ab5f3fcbd6 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/License.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/License.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * License block. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Readiness.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Readiness.php index 76f21eadcac00851a298586d98e1e860a19d3dd6..0e9a566b0d2108f451f66a3a35840a6034033fa0 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/Readiness.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/Readiness.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Readiness block. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Block/WebConfiguration.php b/dev/tests/functional/tests/app/Magento/Install/Test/Block/WebConfiguration.php index 865917e1212aca86e76a98669705dcd56364b648..654dd1ffc8fe3ad117cf1db3a7bb24ee7da00594 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Block/WebConfiguration.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Block/WebConfiguration.php @@ -6,7 +6,7 @@ namespace Magento\Install\Test\Block; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Web configuration block. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertAgreementTextPresent.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertAgreementTextPresent.php index 31fdded30b058f4c006e05a75643e9347d6cefb6..1b19c8a0ade9a2f89267e3e481ad409c604f15d1 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertAgreementTextPresent.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertAgreementTextPresent.php @@ -7,7 +7,7 @@ namespace Magento\Install\Test\Constraint; use Magento\Install\Test\Page\Install; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check that agreement text present on Terms & Agreement page during install. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertCurrencySelected.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertCurrencySelected.php index a7cea54acdc1c4d7ce76d5d5e3199bba676c9837..01f6a6e83417cdc0bd98d84bddd96bfed8358e9b 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertCurrencySelected.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertCurrencySelected.php @@ -7,7 +7,7 @@ namespace Magento\Install\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\Dashboard; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that selected currency symbol displays in admin. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertKeyCreated.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertKeyCreated.php index a18bfb1e9a98b8b70ce5b10e2e67bee052df5c37..45805d80ab396982026547d059175a1b88e4d194 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertKeyCreated.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertKeyCreated.php @@ -6,7 +6,7 @@ namespace Magento\Install\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Install\Test\Page\Install; use Magento\Install\Test\Fixture\Install as InstallConfig; diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertLanguageSelected.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertLanguageSelected.php index 99225403378673d7fded2e941766ba282589fa17..06a8eacf21b0fff576bf62eba8f04f39e561e46e 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertLanguageSelected.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertLanguageSelected.php @@ -7,7 +7,7 @@ namespace Magento\Install\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that selected language currently displays on frontend. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertRewritesEnabled.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertRewritesEnabled.php index 665a6a4d83ab758508ed884d00a3cc5019c39136..3248e930e920d293b2a1936e0f3b02d6cfdbc5dc 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertRewritesEnabled.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertRewritesEnabled.php @@ -7,8 +7,8 @@ namespace Magento\Install\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Client\Driver\Selenium\Browser; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; use Magento\Catalog\Test\Fixture\Category; /** @@ -25,9 +25,9 @@ class AssertRewritesEnabled extends AbstractConstraint * * @param Category $category * @param CmsIndex $homePage - * @param Browser $browser + * @param BrowserInterface $browser */ - public function processAssert(Category $category, CmsIndex $homePage, Browser $browser) + public function processAssert(Category $category, CmsIndex $homePage, BrowserInterface $browser) { $category->persist(); $homePage->open(); diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSecureUrlEnabled.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSecureUrlEnabled.php index d756b22583e2cda43ee2d6afe6c1b4179dae543c..d42cc5a9fb574a515fd8c64e90b542568cfef232 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSecureUrlEnabled.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSecureUrlEnabled.php @@ -6,8 +6,8 @@ namespace Magento\Install\Test\Constraint; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\Customer\Test\Page\CustomerAccountLogin; @@ -23,13 +23,13 @@ class AssertSecureUrlEnabled extends AbstractConstraint /** * Assert that Secure Urls Enabled. * - * @param Browser $browser + * @param BrowserInterface $browser * @param Dashboard $dashboard * @param CustomerAccountLogin $customerAccountLogin * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, Dashboard $dashboard, CustomerAccountLogin $customerAccountLogin ) { diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessInstall.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessInstall.php index 3a10bdc4cc19a26f7f11638077298e4587902412..9c8df14af250e3a8f783c9797d238b4572b9a72f 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessInstall.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessInstall.php @@ -8,7 +8,7 @@ namespace Magento\Install\Test\Constraint; use Magento\User\Test\Fixture\User; use Magento\Install\Test\Page\Install; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Install\Test\Fixture\Install as InstallConfig; /** diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessfulReadinessCheck.php b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessfulReadinessCheck.php index 32d69a4f44337302b745eccaa8aa7d14368cf6c1..ef42ae9ac9fdc60da320b3d4031bd46ea64826ea 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessfulReadinessCheck.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Constraint/AssertSuccessfulReadinessCheck.php @@ -7,7 +7,7 @@ namespace Magento\Install\Test\Constraint; use Magento\Install\Test\Page\Install; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Check that PHP Version, PHP Extensions and File Permission are ok. diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/Fixture/Install.php b/dev/tests/functional/tests/app/Magento/Install/Test/Fixture/Install.php index fe297aeb0d966ce9b0ceca184ed2e661d059e329..6a436e82d54a1998891764ec0f1c5c3ffd686742 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/Fixture/Install.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/Fixture/Install.php @@ -6,7 +6,7 @@ namespace Magento\Install\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Install diff --git a/dev/tests/functional/tests/app/Magento/Install/Test/TestCase/InstallTest.php b/dev/tests/functional/tests/app/Magento/Install/Test/TestCase/InstallTest.php index 943943cf5e9d5b64fbc1702c7a49909f573ba6ad..9231f84c67975da52b0a62328df5b83ec58f667d 100644 --- a/dev/tests/functional/tests/app/Magento/Install/Test/TestCase/InstallTest.php +++ b/dev/tests/functional/tests/app/Magento/Install/Test/TestCase/InstallTest.php @@ -10,9 +10,9 @@ use Magento\Cms\Test\Page\CmsIndex; use Magento\Install\Test\Page\Install; use Magento\Install\Test\Fixture\Install as InstallConfig; use Magento\User\Test\Fixture\User; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; -use Mtf\System\Config; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; +use Magento\Mtf\System\Config; use Magento\Install\Test\Constraint\AssertAgreementTextPresent; use Magento\Install\Test\Constraint\AssertSuccessfulReadinessCheck; diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid.php index b206797f1b20ff2f3482ce3365537352eff5ba95..734d91c42648b33370d85b2de7cd79af782ef19b 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid.php @@ -9,7 +9,7 @@ namespace Magento\Integration\Test\Block\Adminhtml\Integration; use Magento\Backend\Test\Block\Widget\Grid; use Magento\Integration\Test\Block\Adminhtml\Integration\IntegrationGrid\ResourcesPopup; use Magento\Integration\Test\Block\Adminhtml\Integration\IntegrationGrid\TokensPopup; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class IntegrationGrid diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/DeleteDialog.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/DeleteDialog.php index d13efbf55153dc75f2eb9b8e14fb065a4c530998..c3ef042b1c1f1e939677e7e9cfee9b6cdbb448cf 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/DeleteDialog.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/DeleteDialog.php @@ -6,8 +6,8 @@ namespace Magento\Integration\Test\Block\Adminhtml\Integration\IntegrationGrid; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class DeleteDialog diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/ResourcesPopup.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/ResourcesPopup.php index d4b21f3362ad04e0cb728ddde1864261896d22ff..6720168dc4f81385cae0b3095a22404193f30463 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/ResourcesPopup.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/ResourcesPopup.php @@ -6,7 +6,7 @@ namespace Magento\Integration\Test\Block\Adminhtml\Integration\IntegrationGrid; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class ResourcesPopup diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/TokensPopup.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/TokensPopup.php index 43651e1d78be0e73751cce96257c66072d712960..2c7c33b1db84c6183d34c7fd6783fccb25015f12 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/TokensPopup.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Block/Adminhtml/Integration/IntegrationGrid/TokensPopup.php @@ -6,7 +6,7 @@ namespace Magento\Integration\Test\Block\Adminhtml\Integration\IntegrationGrid; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class TokensPopup diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationForm.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationForm.php index af2f985126162740ce6bcc264ff7431602a69d4c..d32789af9ba8005ba14fa86e61e64dc76e4f1968 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationForm.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationForm.php @@ -9,7 +9,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; use Magento\Integration\Test\Page\Adminhtml\IntegrationNew; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertIntegrationForm diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationInGrid.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationInGrid.php index b770b325e65359dab7e98ad7708db1252318c936..81c5c22bab0324dfdcea88d5b9a5531e6d5f47e7 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationInGrid diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationNotInGrid.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationNotInGrid.php index 78468647fd0108c901a37c77c435cdad3395939d..3b2705ee7994d7bd5babdfa5a1ef8233db4e1cef 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationResourcesPopup.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationResourcesPopup.php index 7613e5c9728e74becea6d2adefd9b6020d741c36..f301fc6c00ff26e189c06d948e0b7e81fcd8dcc5 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationResourcesPopup.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationResourcesPopup.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationResourcesPopup diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessActivationMessage.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessActivationMessage.php index 7bc79c61f2e98ffe9418d80c99d63e5b87c5a573..fa8edc4ae44886f7d23e6a399115dea3f393cde6 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessActivationMessage.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessActivationMessage.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationSuccessActivationMessage diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessDeleteMessage.php index 044e26d231eb5f43757f927839837b6b67dcb9f3..6ee3320e396b9aa9fb5436f590eb97f2d2cda411 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessDeleteMessage.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessReauthorizeMessage.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessReauthorizeMessage.php index fc5543afdc28d470ae5d7503688e79513dd8f272..7abfeb28dac4b90dd73b46d644d90e123cf43ffc 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessReauthorizeMessage.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessReauthorizeMessage.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationSuccessReauthorizeMessage diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessSaveMessage.php index bfbf57ef093499e03856b4ac3a93c027ef98aeec..c143ae8f0f29a033f235850a642e26b8ad86b7e0 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationSuccessSaveMessage.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensAfterReauthorize.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensAfterReauthorize.php index d3643f0a469e4273153f1bdc58c549a507ba1e97..f0d6b8506720c0e87c027de513f60a3f3088d588 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensAfterReauthorize.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensAfterReauthorize.php @@ -9,7 +9,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; use Magento\Integration\Test\Page\Adminhtml\IntegrationNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationTokensAfterReauthorize diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensPopup.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensPopup.php index 2bc2fe80c513769b86fc247d4750d82ab8b4587a..79af964f4ecff561e3e7a75144bffdffc880c8d5 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensPopup.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Constraint/AssertIntegrationTokensPopup.php @@ -7,7 +7,7 @@ namespace Magento\Integration\Test\Constraint; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertIntegrationTokensPopup diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Fixture/Integration.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Fixture/Integration.php index f914c3d507dff8f6210edf00b0490f5ddb65f586..71a9b860f2fffa60d7b68ddf5ac0ab0502f9d7b6 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Fixture/Integration.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Fixture/Integration.php @@ -6,7 +6,7 @@ namespace Magento\Integration\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Integration diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/Curl.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/Curl.php index a96f9123ac2734579aa37c80433e8d92c981f82e..0550185ae18df253833fc0cb1e4c15c761cd8f43 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Integration\Test\Handler\Integration; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/IntegrationInterface.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/IntegrationInterface.php index f5abf4c7f2c1eb2cd685a10d31bf4fe5bfe941c8..4bfdf4efe2df26f5200250a7ff837680af2e6994 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/IntegrationInterface.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Handler/Integration/IntegrationInterface.php @@ -6,7 +6,7 @@ namespace Magento\Integration\Test\Handler\Integration; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface IntegrationInterface diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/Repository/Integration.php b/dev/tests/functional/tests/app/Magento/Integration/Test/Repository/Integration.php index af4e955fca7c8cbb9d9190d7147d2c07d4f2158c..78c01f185fc2f224effb56cb11c86a2e65a7c812 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/Repository/Integration.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/Repository/Integration.php @@ -6,7 +6,7 @@ namespace Magento\Integration\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Integration Repository diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ActivateIntegrationEntityTest.php b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ActivateIntegrationEntityTest.php index 43db84b40c5da25e67c299b01108584123f0eb5f..caf67686a3604ff01447238c7ed9fab3a68e3b60 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ActivateIntegrationEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ActivateIntegrationEntityTest.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\TestCase; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Activate Integration Entity diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/CreateIntegrationEntityTest.php b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/CreateIntegrationEntityTest.php index 31c234c3c045d7ecc71795ad371791a1b95c6c1e..2056ea6a9c7bb1e957ae4e3d5cab0bd14271a2d1 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/CreateIntegrationEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/CreateIntegrationEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Integration\Test\TestCase; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; use Magento\Integration\Test\Page\Adminhtml\IntegrationNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create Integration Entity diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/DeleteIntegrationEntityTest.php b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/DeleteIntegrationEntityTest.php index efdef5324b6c1a2f1a0a9c0d830c2591bdd88ec0..d1cbf03eaecd41730831dad4dcd4df1f56b947d0 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/DeleteIntegrationEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/DeleteIntegrationEntityTest.php @@ -8,7 +8,7 @@ namespace Magento\Integration\Test\TestCase; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete Integration Entity diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ReAuthorizeTokensIntegrationEntityTest.php b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ReAuthorizeTokensIntegrationEntityTest.php index 36c1743dccd3e32d50e616c463340e0db2cdc9b7..8519bb70812d705619e41be29766e9ff871dac38 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ReAuthorizeTokensIntegrationEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/ReAuthorizeTokensIntegrationEntityTest.php @@ -8,8 +8,8 @@ namespace Magento\Integration\Test\TestCase; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Reauthorize tokens for the Integration Entity. diff --git a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.php b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.php index 6fd90e31c2c42888f999c9c1a3432b0279f7d485..987c3c68b52dbcc4d35cd230a4dac4f9b6e6dd92 100644 --- a/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Integration/Test/TestCase/UpdateIntegrationEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Integration\Test\TestCase; use Magento\Integration\Test\Fixture\Integration; use Magento\Integration\Test\Page\Adminhtml\IntegrationIndex; use Magento\Integration\Test\Page\Adminhtml\IntegrationNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update Integration Entity diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Grid.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Grid.php index 2d52f6004069f379da0320853f2c78aaca10b5ed..972317cb5c7a2c7383d1de89d37baf02082245bb 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Grid.php @@ -6,7 +6,7 @@ namespace Magento\Newsletter\Test\Block\Adminhtml\Template; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Preview.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Preview.php index cb5536668301d38f70e0b2f02a04bc82d081e3ba..3de754dffa925d1f920b77c079b0df95a6cf63c7 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Preview.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Block/Adminhtml/Template/Preview.php @@ -6,9 +6,8 @@ namespace Magento\Newsletter\Test\Block\Adminhtml\Template; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Newsletter template preview. @@ -45,6 +44,7 @@ class Preview extends Block } ); $this->browser->switchToFrame(new Locator($this->iFrame)); + return $this->_rootElement->getText(); } } diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertCustomerIsSubscribedToNewsletter.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertCustomerIsSubscribedToNewsletter.php index a6fcb89baaf4db70b633d5fe66a476c0b9e6251d..7e41b346d1d2a5b4b85f15329218802c42aa4f58 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertCustomerIsSubscribedToNewsletter.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertCustomerIsSubscribedToNewsletter.php @@ -8,7 +8,7 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Newsletter\Test\Page\Adminhtml\SubscriberIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCustomerIsSubscribedToNewsletter diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterForm.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterForm.php index eee0651315b79759a805b645558b8a279a6bb638..fe8a56af636a8e9de0da03a45204673dda1d31b2 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterForm.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterForm.php @@ -9,7 +9,7 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateEdit; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertNewsletterForm diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterInGrid.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterInGrid.php index 182f10bc13c05e99ea8c479ddb0a7742c287eeb1..b5d1a1c72b4445aed56b6aeb7dd8bb37bd1a8ad5 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNewsletterInGrid diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterPreview.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterPreview.php index c3ffe3e95d2e58269a45175298fda4f3454875a1..aa0946c684dc1ec09ee7bf9b23d12c8a5e3e70df 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterPreview.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterPreview.php @@ -8,8 +8,8 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplatePreview; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNewsletterPreview @@ -24,13 +24,16 @@ class AssertNewsletterPreview extends AbstractConstraint /** * Assert that newsletter preview opened in new window and template content correct * - * @param Browser $browser + * @param BrowserInterface $browser * @param TemplatePreview $templatePreview * @param Template $newsletter * @return void */ - public function processAssert(Browser $browser, TemplatePreview $templatePreview, Template $newsletter) - { + public function processAssert( + BrowserInterface $browser, + TemplatePreview $templatePreview, + Template $newsletter + ) { $browser->selectWindow(); $content = $templatePreview->getContent()->getPageContent(); $browser->closeWindow(); diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterQueue.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterQueue.php index e1903f8ccc52abfe19132514633ba2c293b7d8a6..b9dbcdceb67d5f018a8f90a4300de9002c25e593 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterQueue.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterQueue.php @@ -8,7 +8,7 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateQueue; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertNewsletterQueue diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterSuccessCreateMessage.php index 21c32980f81a79bd85aa0fd0df8276fa8ac57e8d..0a71b2cc8ae57f78277e7df3e469c1f44bd9f3f2 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Constraint/AssertNewsletterSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Newsletter\Test\Constraint; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNewsletterSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Fixture/Template.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Fixture/Template.php index 44f92cc2b6fc4a8fa8a430ef6ff6fd79ea794008..da668a8e4a747f8eff3808836a7181f002a52ea6 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Fixture/Template.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Fixture/Template.php @@ -6,7 +6,7 @@ namespace Magento\Newsletter\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Template diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/Curl.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/Curl.php index 759a6177fb28122ad210cb1d8a86646cfc426022..0cb1f61c7459f14c41ee6a4e372ceec8208b8fcd 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Newsletter\Test\Handler\Template; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/TemplateInterface.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/TemplateInterface.php index cc4848f0dbe76bc6f4099321eecd009d0e47f73e..9b2628398266e0e39dae6d7a966b9b923348c721 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/TemplateInterface.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Handler/Template/TemplateInterface.php @@ -6,7 +6,7 @@ namespace Magento\Newsletter\Test\Handler\Template; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface TemplateInterface diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Repository/Template.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Repository/Template.php index 00f90b9ced37cf087c0a85bace9d067467424dfa..83669e31b8486c6b2cd15dc8e31f91aa963d454f 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/Repository/Template.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/Repository/Template.php @@ -6,7 +6,7 @@ namespace Magento\Newsletter\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class UrlRewrite diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php index 7f761fb67ab1ed15f629b498c433353015b813ce..1bffdfc6e1ae3211531fbedb405cb07e87ee9caf 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/ActionNewsletterTemplateEntityTest.php @@ -8,7 +8,7 @@ namespace Magento\Newsletter\Test\TestCase; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Action for Newsletter Template (Preview and Queue) diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/CreateNewsletterTemplateEntityTest.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/CreateNewsletterTemplateEntityTest.php index b2c733f77bc6bf0f050742e4899ffc0960fbdd5c..81a7e1a994942bf3e9255d539056d064a0db8eea 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/CreateNewsletterTemplateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/CreateNewsletterTemplateEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Newsletter\Test\TestCase; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; use Magento\Newsletter\Test\Page\Adminhtml\TemplateNewIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create Newsletter Template diff --git a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/UpdateNewsletterTemplateTest.php b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/UpdateNewsletterTemplateTest.php index c639664114124252a2ac4d581bfef3adb3b1e614..9442ee96d8edb9b4d46b83b359c94010a9ac3d98 100644 --- a/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/UpdateNewsletterTemplateTest.php +++ b/dev/tests/functional/tests/app/Magento/Newsletter/Test/TestCase/UpdateNewsletterTemplateTest.php @@ -9,7 +9,7 @@ namespace Magento\Newsletter\Test\TestCase; use Magento\Newsletter\Test\Fixture\Template; use Magento\Newsletter\Test\Page\Adminhtml\TemplateEdit; use Magento\Newsletter\Test\Page\Adminhtml\TemplateIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateNewsletterTemplate diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/AbstractFilter.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/AbstractFilter.php index 10965d8e33013271d4c0381b2e0773d47d880c7a..90eebe23e89a0b816abfc7ea7bfbad6308de09e9 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/AbstractFilter.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/AbstractFilter.php @@ -6,8 +6,8 @@ namespace Magento\Reports\Test\Block\Adminhtml; -use Mtf\Block\Form; -use Mtf\ObjectManager; +use Magento\Mtf\Block\Form; +use Magento\Mtf\ObjectManager; /** * Abstract Class Filter diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/AccountsGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/AccountsGrid.php index 52677cffebd985d14f8b1c2802d49d2681339836..0780cf35898c8a883dd4e5dd321723c362c4a431 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/AccountsGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/AccountsGrid.php @@ -6,8 +6,8 @@ namespace Magento\Reports\Test\Block\Adminhtml\Customer; -use Mtf\Client\Element\Locator; -use Mtf\ObjectManager; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\ObjectManager; /** * Class AccountsGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/Totals/Grid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/Totals/Grid.php index a7057bb927450800f5977d5ce2b06a32d308d6ab..3bf9e419499f8acb0d6610032cde8d7e3099aeda 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/Totals/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Customer/Totals/Grid.php @@ -6,8 +6,8 @@ namespace Magento\Reports\Test\Block\Adminhtml\Customer\Totals; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Grid @@ -62,7 +62,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid * @param array $filter * @param bool $isSearchable * @param bool $isStrict - * @return Element + * @return SimpleElement */ protected function getRow(array $filter, $isSearchable = true, $isStrict = true) { diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Refresh/Statistics/Grid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Refresh/Statistics/Grid.php index 10c49b57b7a21c5fbbc05e23b25d37c5a6a16e80..b36221e8fe0d6596b82ec0d81e77f0ba441bae37 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Refresh/Statistics/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Refresh/Statistics/Grid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Refresh\Statistics; use Magento\Backend\Test\Block\Widget\Grid as AbstractGrid; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Customer/Grid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Customer/Grid.php index 81381f65adbbb4eae062e500dcbb73409e62df0f..3eaae41b7e2bd327eb92e3af85bb9d56c1aca24e 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Customer/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Customer/Grid.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Review\Customer; use Magento\Backend\Test\Block\Widget\Grid as AbstractGrid; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Grid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Grid.php index cf97a199d6a75c13ba745e1646ca0c0701d3dc91..7c253b7b2f2874fa6ba1e8bfa4374ca792f13c82 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Grid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Review\Products; use Magento\Backend\Test\Block\Widget\Grid as AbstractGrid; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Viewed/ProductGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Viewed/ProductGrid.php index 8128e9cd6e825b82caf38075858cce3e6e8dd92e..e8f44efdbaa0c9f85fa2e0bf99a4a1cf18715651 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Viewed/ProductGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Review/Products/Viewed/ProductGrid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Review\Products\Viewed; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class ProductGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Orders/Viewed/FilterGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Orders/Viewed/FilterGrid.php index 92a22e656ea528a1a17b20ddf12a390109ccdd56..e3a36a9553e4502aa2788be8c955242beeaf4ad0 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Orders/Viewed/FilterGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Sales/Orders/Viewed/FilterGrid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Sales\Orders\Viewed; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class FilterGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Shopcart/Product/Grid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Shopcart/Product/Grid.php index 9831a4a710694ec60fa1a4354e4bc5490b6030c7..2186b442e7486ee8b79410d0bb1fbfaea49076d6 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Shopcart/Product/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Block/Adminhtml/Shopcart/Product/Grid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Block\Adminhtml\Shopcart\Product; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertCustomerOrderReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertCustomerOrderReportResult.php index deecca39c4321205ebb016d5fb35ff289b617f6f..82e4fe1f4b0a998e1603463ddcf74bdec7c424ad 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertCustomerOrderReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertCustomerOrderReportResult.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AbstractAssertCustomerOrderReportResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertInvoiceReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertInvoiceReportResult.php index 16c1fbcf29dc6b3cd88d98d5ac434c3bea42567a..df6e3fb9662d455e69f22dbe3b8238b743c143eb 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertInvoiceReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertInvoiceReportResult.php @@ -8,8 +8,8 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\SalesInvoiceReport; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; -use Mtf\ObjectManager; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\ObjectManager; /** * Class AbstractAssertInvoiceReportResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertSalesReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertSalesReportResult.php index 55fa321d281a96588e355fca53e65e7ff72702ce..16af632c450ab59a2e803b609454d6d832064d32 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertSalesReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AbstractAssertSalesReportResult.php @@ -7,8 +7,8 @@ namespace Magento\Reports\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Page\BackendPage; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Page\BackendPage; /** * Class AbstractAssertSalesReportResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertAbandonedCartCustomerInfoResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertAbandonedCartCustomerInfoResult.php index 7c38e4dfaa37fbc8847bad6e26e6f668dec24a3b..346f78a1c747a2ccede20e72264613c27067ac52 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertAbandonedCartCustomerInfoResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertAbandonedCartCustomerInfoResult.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Reports\Test\Page\Adminhtml\AbandonedCarts; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAbandonedCartCustomerInfoResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertBestsellerReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertBestsellerReportResult.php index 726d18a3aadacd379bb789e46bf2ce8bc53f09d4..350a81904f4e379d7a0d2207c10c551408c71d06 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertBestsellerReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertBestsellerReportResult.php @@ -9,7 +9,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Reports\Test\Page\Adminhtml\Bestsellers; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert bestseller info in report: date, product name and qty. diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertCouponReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertCouponReportResult.php index 685624924c9aaf9acf6e08d4cfc26da5810951c2..da229325e70c0b49298db2695385903961c97298 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertCouponReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertCouponReportResult.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\SalesCouponReportView; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCouponReportResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertDownloadsReportResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertDownloadsReportResult.php index 97f486de8c0a290ecddc6679cb9e10e654e8b722..c77ecc0cfb61c683b1b69ef92e947c4f285dd9fc 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertDownloadsReportResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertDownloadsReportResult.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\DownloadsReport; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertDownloadsReportResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertLowStockProductInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertLowStockProductInGrid.php index 8b1b7e8a7773305eda1faa02d61244a99c89d38f..bbdee1a27dab6400df685bec811108308a6d962c 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertLowStockProductInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertLowStockProductInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Reports\Test\Page\Adminhtml\ProductLowStock; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertLowStockProductInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertNewAccountsReportTotalResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertNewAccountsReportTotalResult.php index 8baf8d23c27650592d5d8cd98e7c7586b027a693..c3c051545097af9e227596356ad7745b17036e36 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertNewAccountsReportTotalResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertNewAccountsReportTotalResult.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\CustomerAccounts; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNewAccountsReportTotalResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertOrderedProductResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertOrderedProductResult.php index 1cb398a2d6d599c32448a92aea5dc9d0a9a28214..dc72afc3bd70b224e9ade7160ea9d7531d58d851 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertOrderedProductResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertOrderedProductResult.php @@ -9,7 +9,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Reports\Test\Page\Adminhtml\OrderedProductsReport; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderedProductResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductInCartResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductInCartResult.php index 37a3af3ddaf77f12849f63449420530351729714..5bf977eb479c2ccf44374ceac560182e68114b00 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductInCartResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductInCartResult.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Reports\Test\Page\Adminhtml\ShopCartProductReport; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductInCartResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerInGrid.php index 53f509fd4656ec92e3f8601e5cfa754b55c2d308..d537838adef6cd7795bcea1da0a8f2ae387cea9e 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerInGrid.php @@ -12,7 +12,7 @@ use Magento\Reports\Test\Page\Adminhtml\CustomerReportReview; use Magento\Review\Test\Constraint\AssertProductReviewInGrid; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReportByCustomerInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerNotInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerNotInGrid.php index 0a3d13e4d0a75cd0d708b8ca4ac5b4265c2b975d..76116fee9c8e8bbf2f8f2746e1f4a8c273f4090b 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReportByCustomerNotInGrid.php @@ -12,7 +12,7 @@ use Magento\Reports\Test\Page\Adminhtml\CustomerReportReview; use Magento\Review\Test\Constraint\AssertProductReviewNotInGrid; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReportByCustomerNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewIsAvailableForProduct.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewIsAvailableForProduct.php index 20e1610df69c149fc3fa14d9870c61f5211558c7..f3ce68ad8d140681942da4c5ac6f5657bd4ba943 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewIsAvailableForProduct.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewIsAvailableForProduct.php @@ -10,7 +10,7 @@ use Magento\Reports\Test\Page\Adminhtml\ProductReportReview; use Magento\Review\Test\Constraint\AssertProductReviewInGrid; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewIsVisibleInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewReportIsVisibleInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewReportIsVisibleInGrid.php index 61b45d29f0d38f639476dbe9b9233a17a93ea2ec..0d4604ec4400055dd45a4e3df8ce8c02a8c81b4a 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewReportIsVisibleInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewReportIsVisibleInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\ProductReportReview; use Magento\Review\Test\Fixture\Review; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewReportIsVisibleInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewsQtyByCustomer.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewsQtyByCustomer.php index d0d9400cf79c9243315dfc878f6fb53828315bd6..1ae6670b974ddd27fccefa888c02c28a51d054d5 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewsQtyByCustomer.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductReviewsQtyByCustomer.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Reports\Test\Page\Adminhtml\CustomerReportReview; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewsQtyByCustomer diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductViewsReportTotalResult.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductViewsReportTotalResult.php index 0afd5c6c6009f2a8ec0b66bc1d7dd952af6d49ca..152cd5aa4ee62ca4ff91bc5df3fb6e4d32fc98fd 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductViewsReportTotalResult.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertProductViewsReportTotalResult.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\ProductReportView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductViewsReportTotalResult diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermReportForm.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermReportForm.php index 004c3ad4f5811a7bc2013cefd6b4eb334c60a919..d1e75cff6ac8e97c330439ab6f7396ed12ac0585 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermReportForm.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermReportForm.php @@ -8,7 +8,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\CatalogSearch\Test\Page\Adminhtml\CatalogSearchEdit; use Magento\Reports\Test\Page\Adminhtml\SearchIndex; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertSearchTermReportForm diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermsInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermsInGrid.php index ac622368edafc0c89bbb66bd2eeab7f6a43cc128..cbb20b5cb97f315ba0f14c910981db9d8176ed89 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermsInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertSearchTermsInGrid.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\SearchIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSearchTermsInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportInGrid.php index 2443521f269ab786376f99c0c9160a8a3728a155..bf5d8478e6a7bddf3d7f9409e8ddbe0004da8ace 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportInGrid.php @@ -9,7 +9,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\SalesTaxReport; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxReportInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportNotInGrid.php b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportNotInGrid.php index 2e429dc13cdf2f32dff5f26f02c4ff36ce4da775..b7090947f14d8c7ca9a429cc74033b4ed382cc61 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/Constraint/AssertTaxReportNotInGrid.php @@ -9,7 +9,7 @@ namespace Magento\Reports\Test\Constraint; use Magento\Reports\Test\Page\Adminhtml\SalesTaxReport; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxReportNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php index e8350b5091736411c08f1eddd09f8923d9eb4368..bc27cf23ec8c3843b1b61b502862fd87fc252b20 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/AbandonedCartsReportEntityTest.php @@ -6,11 +6,11 @@ namespace Magento\Reports\Test\TestCase; -use Magento\Catalog\Test\Page\Product\CatalogProductView; +use Magento\Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Catalog\Test\Page\Product\CatalogProductView; /** * Test Flow: @@ -48,7 +48,7 @@ class AbandonedCartsReportEntityTest extends Injectable /** * Browser interface. * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -62,13 +62,13 @@ class AbandonedCartsReportEntityTest extends Injectable /** * Inject pages. * - * @param Browser $browser + * @param BrowserInterface $browser * @param FixtureFactory $fixtureFactory * @param CatalogProductView $catalogProductView * @return void */ public function __inject( - Browser $browser, + BrowserInterface $browser, FixtureFactory $fixtureFactory, CatalogProductView $catalogProductView ) { diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomerReviewReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomerReviewReportEntityTest.php index d116c2c492319592e3e9568da061834d17f443ac..28a4f7204b41d4ba7f3548e634da23b7a61eb59e 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomerReviewReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/CustomerReviewReportEntityTest.php @@ -15,9 +15,9 @@ use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\Reports\Test\Page\Adminhtml\ProductReportReview; use Magento\Review\Test\Fixture\Review; -use Mtf\Client\Browser; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CustomerReviewReportEntity @@ -136,7 +136,7 @@ class CustomerReviewReportEntityTest extends Injectable * @param CustomerInjectable $customer * @param $customerLogin * @param CatalogProductSimple $product - * @param Browser $browser + * @param BrowserInterface $browser * @return array * * @SuppressWarnings(PHPMD.ConstructorWithNameAsEnclosingClass) @@ -145,7 +145,7 @@ class CustomerReviewReportEntityTest extends Injectable Review $review, CustomerInjectable $customer, CatalogProductSimple $product, - Browser $browser, + BrowserInterface $browser, $customerLogin ) { // Preconditions diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/LowStockProductsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/LowStockProductsReportEntityTest.php index 557482ee2252be6a1a5d6834443e2e51bc53fba3..a81da13dd13add8b8e706c50379a0626e96e9183 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/LowStockProductsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/LowStockProductsReportEntityTest.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\TestCase; use Magento\Catalog\Test\Fixture\CatalogProductSimple; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for LowStockProductsReportEntityTest diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.php index 5a75c804d4b0475cd5ebb3d7966b31ecd591ddeb..62a4231bca01c1f55fbab71275e8578ddeea0425 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/NewAccountsReportEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Reports\Test\TestCase; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Reports\Test\Page\Adminhtml\CustomerAccounts; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductReviewReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductReviewReportEntityTest.php index a26acb68c4ebe4d59231daa1dc3a220c39d363c9..92b8ee33316e41343bacb0287a85088b48312488 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductReviewReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductReviewReportEntityTest.php @@ -7,7 +7,7 @@ namespace Magento\Reports\Test\TestCase; use Magento\Review\Test\Fixture\Review; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ProductReviewReportEntity diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductsInCartReportEntity.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductsInCartReportEntity.php index 09031687aa4bcd6cd88e8844286838a6ab199d18..59fcbb7b335fe2b3dbe3dbf1d2607d3111d6de1f 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductsInCartReportEntity.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ProductsInCartReportEntity.php @@ -12,8 +12,8 @@ use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAccountLogout; -use Mtf\Client\Browser; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ProductsInCartReportEntity @@ -109,14 +109,14 @@ class ProductsInCartReportEntity extends Injectable * @param CustomerInjectable $customer * @param CatalogProductSimple $product * @param string $isGuest - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function test( CustomerInjectable $customer, CatalogProductSimple $product, $isGuest, - Browser $browser + BrowserInterface $browser ) { // Preconditions $product->persist(); diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SearchTermsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SearchTermsReportEntityTest.php index b670f8024b218058f263cba0377b2cf9d906bf66..eba901312b7964fc68c1520c885529aee0c6297b 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SearchTermsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/SearchTermsReportEntityTest.php @@ -8,8 +8,8 @@ namespace Magento\Reports\Test\TestCase; use Magento\Cms\Test\Page\CmsIndex; use Magento\Reports\Test\Page\Adminhtml\SearchIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php index 13d029eaf34a8695c2f3dc229ec2979391e2bdf3..7ed40fc54cd1642bef310b41bde40e3e23caa320 100644 --- a/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Reports/Test/TestCase/ViewedProductsReportEntityTest.php @@ -6,9 +6,9 @@ namespace Magento\Reports\Test\TestCase; -use Mtf\Client\Browser; -use Mtf\TestCase\Injectable; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; use Magento\Reports\Test\Page\Adminhtml\ProductReportView; use Magento\Catalog\Test\Page\Adminhtml\CatalogProductIndex; @@ -55,7 +55,7 @@ class ViewedProductsReportEntityTest extends Injectable /** * Browser interface * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -76,13 +76,13 @@ class ViewedProductsReportEntityTest extends Injectable * * @param ProductReportView $productReportView * @param FixtureFactory $fixtureFactory - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function __inject( ProductReportView $productReportView, FixtureFactory $fixtureFactory, - Browser $browser + BrowserInterface $browser ) { $this->productReportView = $productReportView; $this->fixtureFactory = $fixtureFactory; diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Edit/RatingElement.php b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Edit/RatingElement.php index 49873ce0828ceae2cb426666dceed4285f57b310..4d51eea65d24a7fb218d73a3197683803e5fed53 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Edit/RatingElement.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/Edit/RatingElement.php @@ -6,14 +6,14 @@ namespace Magento\Review\Test\Block\Adminhtml\Edit; -use Mtf\Client\Driver\Selenium\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class RatingElement * Rating typified element */ -class RatingElement extends Element +class RatingElement extends SimpleElement { /** * Rating selector @@ -53,10 +53,10 @@ class RatingElement extends Element /** * Get rating vote * - * @param Element $rating + * @param SimpleElement $rating * @return int */ - protected function getRatingVote(Element $rating) + protected function getRatingVote(SimpleElement $rating) { $ratingVote = 5; $ratingVoteElement = $rating->find(sprintf($this->checkedRating, $ratingVote)); diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/ReviewForm.php b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/ReviewForm.php index 862a28a895e4854001f8b28955c524f53f6a02d2..76f821b010e92c37c3042141383c3fd895a3ed6d 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/ReviewForm.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Adminhtml/ReviewForm.php @@ -7,7 +7,8 @@ namespace Magento\Review\Test\Block\Adminhtml; use Magento\Backend\Test\Block\Widget\Form; -use Mtf\Client\Element\Locator; +use Magento\Review\Test\Fixture\ReviewInjectable; +use Magento\Mtf\Client\Locator; /** * Class Edit diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Form.php b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Form.php index d4627c25263afeb25285dcecc2334dbc4de41f8e..449bc91419bbdd368b4451d28887e03ed3661e56 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Form.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Form.php @@ -6,12 +6,12 @@ namespace Magento\Review\Test\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Fixture\Review; -use Mtf\Block\Form as AbstractForm; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Form as AbstractForm; /** * Review form on frontend. @@ -59,7 +59,7 @@ class Form extends AbstractForm /** * Get legend. * - * @return Element + * @return SimpleElement */ public function getLegend() { @@ -81,7 +81,7 @@ class Form extends AbstractForm * Get single product rating. * * @param Rating $rating - * @return Element + * @return SimpleElement */ protected function getRating(Rating $rating) { @@ -92,10 +92,10 @@ class Form extends AbstractForm * Fill the review form. * * @param FixtureInterface $review - * @param Element|null $element + * @param SimpleElement|null $element * @return $this */ - public function fill(FixtureInterface $review, Element $element = null) + public function fill(FixtureInterface $review, SimpleElement $element = null) { if ($review->hasData('ratings')) { $this->fillRatings($review->getRatings()); diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View.php b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View.php index 802a9be45927811f05a51904c6ee7b05e27145f3..ca08c912deca7eed4d5b87b963a5410708bcabb8 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Block\Product; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class View diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View/Summary.php b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View/Summary.php index 2793d96e52b98457c6dff62f8471ed0e5e827c32..c193a6af97ac82605499d556d50259df476922a4 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View/Summary.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Block/Product/View/Summary.php @@ -7,8 +7,8 @@ namespace Magento\Review\Test\Block\Product\View; -use Mtf\Block\Block; -use Mtf\Client\Element; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\ElementInterface; /** * Reviews frontend block. @@ -32,7 +32,7 @@ class Summary extends Block /** * Get add review link. * - * @return Element + * @return ElementInterface */ public function getAddReviewLink() { @@ -53,9 +53,9 @@ class Summary extends Block } /** - * Get view review link. + * Get view review link * - * @return Element + * @return ElementInterface */ public function getViewReviewLink() { diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInGrid.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInGrid.php index 9f0d60cf1a08a5b965ebb817c168af0159c5e33d..ffc1ab0c766c5c49462ca21b7469a40938a939ef 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingInGrid diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInProductPage.php index aa365cbc8dceeef29fc840e2d6fc8d684b1a1edc..2f1ab78b298c197e26f29afbb24304b10762cda6 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingInProductPage.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Fixture\Review; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingInProductPage @@ -27,7 +27,7 @@ class AssertProductRatingInProductPage extends AbstractConstraint * Assert that product rating is displayed on product review(frontend) * * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductSimple $product * @param Review|null $review [optional] * @param Rating|null $productRating [optional] @@ -35,7 +35,7 @@ class AssertProductRatingInProductPage extends AbstractConstraint */ public function processAssert( CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, CatalogProductSimple $product, Review $review = null, Rating $productRating = null diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInGrid.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInGrid.php index db3fdb0c528d1cbe21be04e38259a41304387606..9ec15f8d1444793edefca786175761f3ce7fd9ca 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInProductPage.php index e5fefcc26717c3eeb37044d64995a2716c8145e3..11a01165df1c8ce649628bfa563ab458fc7f2aef 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingNotInProductPage.php @@ -9,8 +9,8 @@ namespace Magento\Review\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Review\Test\Fixture\Rating; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingNotInProductPage @@ -27,14 +27,14 @@ class AssertProductRatingNotInProductPage extends AbstractConstraint * @param CatalogProductView $catalogProductView * @param CatalogProductSimple $product * @param Rating $productRating - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, CatalogProductSimple $product, Rating $productRating, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $product->getUrlKey() . '.html'); $catalogProductView->getReviewSummary()->getAddReviewLink()->click(); diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingOnReviewPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingOnReviewPage.php index 0c2568845893db95b82e481f25b40b61af28a979..a5db756a503b4a8f78db89d98279589109e94498 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingOnReviewPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingOnReviewPage.php @@ -9,7 +9,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertProductRatingOnReviewPage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessDeleteMessage.php index 95da16862d974f9a6d02608ca7e5d83512204611..4c9e6e5aab25303e4fe466719352e59cf84ef6b1 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessSaveMessage.php index 6168f31cbe824dba783ea61a49289aceb8374f04..36987feabff02e999f437cb00e526e21e364e3db 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductRatingSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductRatingSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewBackendSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewBackendSuccessSaveMessage.php index 8d1752909c02a740c09e009f125863106bcbe3bb..a7f527e20dd6bbf9b740e4505291af84ff1520d9 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewBackendSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewBackendSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewBackendSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewForm.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewForm.php index 2b8ce7fe0fe1e14abb534ec55c63b73f74127777..eb6cb92c40c0f270b3fab671135d6f00bcc364a2 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewForm.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewForm.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Constraint; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGrid.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGrid.php index 90485e15850fc0a42ec804e825605f2cd7f438e4..355bcd41faeb5ea088dac007164272f63e5d4ada 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGrid.php @@ -8,8 +8,8 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductReviewInGrid diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGridOnCustomerPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGridOnCustomerPage.php index 07071d976371ed7abff98f730bd7bb1e95bdffe3..1208bd72e4d808a975e6f4af00777ca168e33af8 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGridOnCustomerPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewInGridOnCustomerPage.php @@ -11,7 +11,7 @@ use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; use Magento\Review\Test\Block\Adminhtml\Product\Grid as ReviewsGrid; use Magento\Review\Test\Fixture\Review; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewInGridOnCustomerPage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewIsAbsentOnProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewIsAbsentOnProductPage.php index 14eddfbb268782060cbab4269cdfdd16a38f4419..b4852e19d6ee4d207bae45089a41041f25dc492f 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewIsAbsentOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewIsAbsentOnProductPage.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; /** diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessDeleteMessage.php index a20ebe47231a8ba3ee9c7ad1bf0cff631607ab6e..cf57f87ba429c9e5774e75163ce75c5403ab5da9 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessDeleteMessage.php @@ -8,7 +8,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewMassActionSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessMessage.php index 67d9c66a3ed9946bfb0919b7a1ddbee6f321d376..3f8d9c4c43c8e245c9cd8a6d6fe605c0bb636e54 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewMassActionSuccessMessage.php @@ -8,7 +8,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewMassActionSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotInGrid.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotInGrid.php index 70f0a5fa4a269f3290f15f1682ff7fcbada113e1..6776c3a651dc5533b9836052e1d084c61fff2c07 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotInGrid.php @@ -8,8 +8,8 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductReviewNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotOnProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotOnProductPage.php index 8b792568aa224fcdf367d5b364fefe210cc072fe..4146c9519cc3110c23351d8614f48969c267f72d 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewNotOnProductPage.php @@ -9,8 +9,8 @@ namespace Magento\Review\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Review\Test\Fixture\Review; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertProductReviewNotOnProductPage @@ -27,13 +27,13 @@ class AssertProductReviewNotOnProductPage extends AbstractConstraint * * @param CatalogProductView $catalogProductView * @param Review $reviewInitial - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( CatalogProductView $catalogProductView, Review $reviewInitial, - Browser $browser + BrowserInterface $browser ) { /** @var CatalogProductSimple $product */ $product = $reviewInitial->getDataFieldConfig('entity_id')['source']->getEntity(); diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewOnProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewOnProductPage.php index eb50b1a4340d9b2fddddbbbfeb8e795ef8df4e9a..2e15e5145665945743a65965cc6ab1604c2e1366 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertProductReviewOnProductPage.php @@ -9,9 +9,9 @@ namespace Magento\Review\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\AdminCache; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Review\Test\Fixture\Review; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert that product review available on product page. @@ -28,7 +28,7 @@ class AssertProductReviewOnProductPage extends AbstractConstraint * @param CatalogProductView $catalogProductView * @param Review $review * @param FixtureInterface $product - * @param Browser $browser + * @param BrowserInterface $browser * @param AdminCache $cachePage * @return void */ @@ -36,7 +36,7 @@ class AssertProductReviewOnProductPage extends AbstractConstraint CatalogProductView $catalogProductView, Review $review, FixtureInterface $product, - Browser $browser, + BrowserInterface $browser, AdminCache $cachePage ) { $errors = []; diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewCreationSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewCreationSuccessMessage.php index d421c2af7afc4ccc21c77ba645c27fa7a316f0f6..7ecf84f3dc1db0c990afa117ba4322e2d89bfcdc 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewCreationSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewCreationSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertReviewCreationSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewLinksIsPresentOnProductPage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewLinksIsPresentOnProductPage.php index 6feba8a2740e03438da51ee5440957ffb0d25ac7..e2aa568ff99d1d2a5ecaabc7e64a90b63f3aaf6c 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewLinksIsPresentOnProductPage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewLinksIsPresentOnProductPage.php @@ -6,10 +6,10 @@ namespace Magento\Review\Test\Constraint; -use Mtf\Client\Browser; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\Browser; +use Magento\Mtf\Fixture\InjectableFixture; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that add and view review links are present on product page. diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewSuccessSaveMessage.php index 947790e85ec4acf49dabc057de92ed6e96c2abfb..3c41e413e459332718a0263ab731cba35fee74c9 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertReviewSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Review\Test\Constraint; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertReviewSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertSetApprovedProductReview.php b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertSetApprovedProductReview.php index e30f73582091ec5ba013ad6746928f07c3ec391d..1e627941bd767bda72fe440332592e03926229a6 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertSetApprovedProductReview.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Constraint/AssertSetApprovedProductReview.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; use Magento\Backend\Test\Page\Adminhtml\AdminCache; diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Rating.php b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Rating.php index efa7bb2458aa9381ba4162857670df280ef3d51c..6991179a3702efb7601b585d50fd6d1f37cf3cb4 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Rating.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Rating.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Rating diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review.php b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review.php index 84226b39f9d626120399f9cccacbb539122d5d77..9c7c3175936d78b38d85b8edd6c865b793ede566 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Product review fixture. diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/EntityId.php b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/EntityId.php index 9cc4e25754dbbf0b7ae6f790adc8608806042d07..6dd94f98ea9058931abac6c1bf9168e3219a5dfb 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/EntityId.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/EntityId.php @@ -6,9 +6,9 @@ namespace Magento\Review\Test\Fixture\Review; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class EntityId diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/Ratings.php b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/Ratings.php index 473bcb90ad32b07f262d9579f0a1509973dfde63..c19487164c89538afe84d304cf024eada95ae6f4 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/Ratings.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Fixture/Review/Ratings.php @@ -6,8 +6,8 @@ namespace Magento\Review\Test\Fixture\Review; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; use Magento\Review\Test\Fixture\Rating; /** diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/Curl.php b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/Curl.php index d5f15eee9ff2e54ad431f3cb0073f05533d99e3c..8d81761803ba374e0a12c526ee75df22c7610792 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/Curl.php @@ -7,12 +7,12 @@ namespace Magento\Review\Test\Handler\Rating; use Magento\Backend\Test\Handler\Extractor; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/RatingInterface.php b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/RatingInterface.php index 68b0397aaebfe7f280b244d9403b2ba297ffbb75..b39248c7a5c4a9968bc9bbb05143a140cd475427 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/RatingInterface.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Rating/RatingInterface.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Handler\Rating; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface RatingInterface diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/Curl.php b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/Curl.php index 398258443501d7831cf7c1c75478079a0dc9f139..c99cac15199ddd5da9a745797ff37e8fb7f6d7fa 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/Curl.php @@ -6,15 +6,15 @@ namespace Magento\Review\Test\Handler\Review; -use Mtf\System\Config; -use Mtf\Fixture\FixtureInterface; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\System\Config; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; use Magento\Review\Test\Fixture\Rating; use Magento\Backend\Test\Handler\Extractor; use Magento\Review\Test\Fixture\Review; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; -use Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Handler\Curl as AbstractCurl; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/ReviewInterface.php b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/ReviewInterface.php index 7b5d19a59901536451d194552f42713554ee77d4..e8fadacfe34392e0e24589ae4646c4430819e010 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/ReviewInterface.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Handler/Review/ReviewInterface.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Handler\Review; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface ReviewInterface diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Rating.php b/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Rating.php index e3422aa73d4c528741e01e8604a46f7063dd0d9b..218bf96d0fb5a3f1fa28eba3096ab89fa9115600 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Rating.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Rating.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Rating diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Review.php b/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Review.php index bd4fc2a8bbd6610c69a34479baec0816f9f6c73e..537245718b6494350a66442f09d19dd2fa8e8d61 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Review.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/Repository/Review.php @@ -6,7 +6,7 @@ namespace Magento\Review\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Review diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductRatingEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductRatingEntityTest.php index d3e7a3cefcad9bf3e8a259fa7a79a0b4eb4629f4..aff4c995ddb807f1fa395feb7ad0feea5c6ffe59 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductRatingEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductRatingEntityTest.php @@ -10,8 +10,8 @@ use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\RatingNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create Backend Product Rating diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php index 81c648ac66cd558b327c8cbd60e875116c8f7012..d2042d8a8370e0c044c87d0a688e3e16e8a70ef2 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewBackendEntityTest.php @@ -12,7 +12,7 @@ use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create ProductReviewEntity Backend diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.php index 663824c91133b381ff707a2bbf49788b77f1834e..4345551308dc988c5c2e5258fd701978707ec504 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/CreateProductReviewFrontendEntityTest.php @@ -11,8 +11,8 @@ use Magento\Review\Test\Constraint\AssertProductReviewIsAbsentOnProductPage; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Client\Browser; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: @@ -90,13 +90,13 @@ class CreateProductReviewFrontendEntityTest extends Injectable * Run create frontend product rating test. * * @param Review $review - * @param Browser $browser + * @param BrowserInterface $browser * @param AssertProductReviewIsAbsentOnProductPage $assertProductReviewIsAbsentOnProductPage * @return array */ public function test( Review $review, - Browser $browser, + BrowserInterface $browser, AssertProductReviewIsAbsentOnProductPage $assertProductReviewIsAbsentOnProductPage ) { // Prepare for tear down diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/DeleteProductRatingEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/DeleteProductRatingEntityTest.php index 9a7495de2912b8fea60f4bb35bdc62e3781fb441..129b383ffe285a0684b215c2718e5acb9ed73a73 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/DeleteProductRatingEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/DeleteProductRatingEntityTest.php @@ -8,8 +8,8 @@ namespace Magento\Review\Test\TestCase; use Magento\Review\Test\Fixture\Rating; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteProductRatingEntity diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php index d9cce2e96703e4d62fb8e645958217dafc5ccf09..52f5bbe692b4ef9739de9bb3b14bf5a16d1c38b6 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ManageProductReviewFromCustomerPageTest.php @@ -17,8 +17,8 @@ use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; -use Mtf\Client\Browser; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ManageProductReviewFromCustomerPage @@ -83,7 +83,7 @@ class ManageProductReviewFromCustomerPageTest extends Injectable /** * Browser * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -142,7 +142,7 @@ class ManageProductReviewFromCustomerPageTest extends Injectable * @param CmsIndex $cmsIndex * @param CustomerAccountLogin $customerAccountLogin * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param RatingIndex $ratingIndex * @param RatingEdit $ratingEdit * @param ReviewEdit $reviewEdit @@ -154,7 +154,7 @@ class ManageProductReviewFromCustomerPageTest extends Injectable CmsIndex $cmsIndex, CustomerAccountLogin $customerAccountLogin, CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, RatingIndex $ratingIndex, RatingEdit $ratingEdit, ReviewEdit $reviewEdit diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/MassActionsProductReviewEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/MassActionsProductReviewEntityTest.php index b0e43e961e4019166776089038186703cc487fcc..9152f68dcf0e278104d32181f9d5b79b6e9f02aa 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/MassActionsProductReviewEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/MassActionsProductReviewEntityTest.php @@ -10,7 +10,7 @@ use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test creation for MassActions ProductReviewEntity diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ModerateProductReviewEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ModerateProductReviewEntityTest.php index 58a3a59ff25682ea1737a141707d4ac1966f14b0..a37ab005cfe5c5ecd591e2c74c713774ec018ba9 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ModerateProductReviewEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/ModerateProductReviewEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Review\Test\TestCase; use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Moderate ProductReview Entity diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.php index f92480f74c746c695a4ca0f8f3da6464bea18b52..08f69793f6f88c23e9d367ac6ae26726af94dbf9 100644 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityOnProductPageTest.php @@ -13,8 +13,8 @@ use Magento\Review\Test\Fixture\Review; use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateProductReviewEntity on product page diff --git a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.php b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.php index a204a9db0165b85357e18a2eddaf83c5952febd9..9d422a2a49a6eba014f8017ff25b8be326e2a2e5 100755 --- a/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Review/Test/TestCase/UpdateProductReviewEntityTest.php @@ -11,7 +11,7 @@ use Magento\Review\Test\Page\Adminhtml\RatingEdit; use Magento\Review\Test\Page\Adminhtml\RatingIndex; use Magento\Review\Test\Page\Adminhtml\ReviewEdit; use Magento\Review\Test\Page\Adminhtml\ReviewIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update Frontend Product Review diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm.php index fa48a0a91000fcfdaf58973c0c86a95fcb06a022..5e703ad9afd035e4e0a634469258df2037cde16d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Form @@ -81,7 +81,6 @@ abstract class AbstractForm extends Form return $element->isVisible() == false ? true : null; } ); - $this->reinitRootElement(); $this->_rootElement->find($this->send)->click(); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm/Product.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm/Product.php index 9c0993bfbe16a7c0d8ec38040e593d09dd3c2053..901ee9bba2b69cab6e55cedc29f906e223908aef 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm/Product.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractForm/Product.php @@ -6,7 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\AbstractForm; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Product @@ -14,6 +15,91 @@ use Mtf\Block\Form; */ class Product extends Form { + /** + * Product price excluding tax search mask + * + * @var string + */ + protected $itemExclTax = '//td[@class="col-price"]/div[@class="price-excl-tax"]/span[@class="price"]'; + + /** + * Product price including tax search mask + * + * @var string + */ + protected $itemInclTax = '//td[@class="col-price"]/div[@class="price-incl-tax"]/span[@class="price"]'; + + /** + * Product price subtotal excluding tax search mask + * + * @var string + */ + protected $itemSubExclTax = '//td[@class="col-subtotal"]/div[@class="price-excl-tax"]/span[@class="price"]'; + + /** + * Product price subtotal including tax search mask + * + * @var string + */ + protected $itemSubInclTax = '//td[@class="col-subtotal"]/div[@class="price-incl-tax"]/span[@class="price"]'; + + /** + * Get Item price excluding tax + * + * @return string|null + */ + public function getItemPriceExclTax() + { + $price = $this->_rootElement->find($this->itemExclTax, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price including tax + * + * @return string|null + */ + public function getItemPriceInclTax() + { + $price = $this->_rootElement->find($this->itemInclTax, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @return string|null + */ + public function getItemSubExclTax() + { + $price = $this->_rootElement->find($this->itemSubExclTax, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @return string|null + */ + + public function getItemSubInclTax() + { + $price = $this->_rootElement->find($this->itemSubInclTax, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Method that escapes currency symbols + * + * @param string $price + * @return string|null + */ + protected function escapeCurrency($price) + { + preg_match("/^\\D*\\s*([\\d,\\.]+)\\s*\\D*$/", $price, $matches); + return (isset($matches[1])) ? $matches[1] : null; + } + /** * Fill item product data * diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItems.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItems.php index b0496115c9c2090386a35e58a3000b81f166d3c0..88af288c29ce656cc6a8e8a2c77672c4da77f72c 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItems.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItems.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class AbstractItems @@ -77,7 +77,7 @@ class AbstractItems extends Block */ public function getData() { - $items = $this->_rootElement->find($this->rowItem)->getElements(); + $items = $this->_rootElement->getElements($this->rowItem); $data = []; foreach ($items as $item) { diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItemsNewBlock.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItemsNewBlock.php index dfa7aecce9a7faf4b5adc9520f7301afa89e158b..907992a7e2c54f7793f272aff8962caca90e6dda 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItemsNewBlock.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/AbstractItemsNewBlock.php @@ -7,8 +7,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; use Magento\Sales\Test\Block\Adminhtml\Order\AbstractForm\Product; -use Mtf\Block\Block; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AbstractItemsNewBlock diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Actions.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Actions.php index aa6a4c1740da31bb9ef66f0851a43c3e40c3e3c9..4d5bf937f8f114d8b7aecfc572af2e91f6ddaff6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Actions.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Actions.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Actions @@ -171,7 +171,7 @@ class Actions extends Block public function cancel() { $this->_rootElement->find($this->cancel)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php index 12ea727d10d320360fa1b05a763c46fbf94248c6..cfeedc7b3262168584cd68cd24870b1310a5a7f5 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create.php @@ -6,10 +6,10 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Create diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Address.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Address.php index a5084d3347c292b4e7f5bd6e322fa7616b6ffa8b..2b5688f592c83bb40a8e3e4f6e67e41d48ebc24d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Address.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Address.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\Billing; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class BillingAddress @@ -29,7 +29,6 @@ class Address extends Form */ public function getExistingAddresses() { - $this->reinitRootElement(); return explode("\n", $this->_rootElement->find($this->existingAddressSelector)->getText()); } } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Method.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Method.php index da0f65be72ee3d04ea835f4d56157f11ce0a03a4..6397d53754a38dd58e0913853b4b65b09c23e9c4 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Method.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Billing/Method.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\Billing; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Method diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Customer.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Customer.php index f077e90672c2ee13dde8b537f1fa683085625354..ba5f99b4e704c5277511aac30c9e56b6b7b11c38 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Customer.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Customer.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Customer diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities.php index 007f33ad32cef3b817f1f9cb5c2aa86913bad1eb..d475f5d0e9799413ae9e59c74d4910fd46ebab17 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities.php @@ -12,8 +12,8 @@ use Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar\R use Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar\RecentlyViewedItems; use Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar\RecentlyViewedProducts; use Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar\ShoppingCartItems; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class CustomerActivities diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar.php index 27af3bd6ee3670b9e879911bcb35008d4f652841..f9c089f1a25d99465df54d38fdc02023c7916d3f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Sidebar block. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar/RecentlyViewedProducts.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar/RecentlyViewedProducts.php index bd51355a2acddbbb2a55b4b74eb35aee211caf7a..81c03a862259e8230eba8af8e16331bfebb2eac0 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar/RecentlyViewedProducts.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/CustomerActivities/Sidebar/RecentlyViewedProducts.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar; use Magento\Sales\Test\Block\Adminhtml\Order\Create\CustomerActivities\Sidebar; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class RecentlyViewedProducts @@ -30,8 +30,7 @@ class RecentlyViewedProducts extends Sidebar public function getProducts() { $products = []; - $productNames = $this->_rootElement->find($this->recentlyViewedProducts, Locator::SELECTOR_XPATH) - ->getElements(); + $productNames = $this->_rootElement->getElements($this->recentlyViewedProducts, Locator::SELECTOR_XPATH); foreach ($productNames as $productName) { $products[] = $productName->getText(); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items.php index abe41f6b5499d6d3d04d37de06f19593455998f9..7d2aec9dd17a3a28781cb7bdaeedffc277252f1b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items.php @@ -7,8 +7,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create; use Magento\Backend\Test\Block\Template; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Items @@ -86,7 +86,7 @@ class Items extends Block { $this->getTemplateBlock()->waitLoader(); $this->_rootElement->click(); - $products = $this->_rootElement->find($this->productNames, Locator::SELECTOR_XPATH)->getElements(); + $products = $this->_rootElement->getElements($this->productNames, Locator::SELECTOR_XPATH); $pageData = []; foreach ($products as $product) { $pageData[] = $this->getItemProductByName($product->getText())->getCheckoutData($fields); diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php index ad197576e6bf263180b5b59c6bb3e18ecdbda8d2..03ec6f8187c16a1a697a93f64e6a8d861a0130fe 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Items/ItemProduct.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\Items; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class ItemProduct diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Address.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Address.php index a7bef1c77da3fc36c6384760c613c662691524d3..73e951594ff3368af589ee6be154d0b5e91a87dc 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Address.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Address.php @@ -7,8 +7,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\Shipping; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class ShippingAddress diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Method.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Method.php index a2bdd1e649c848564bbbb929dad1cf4c74a9558b..4f9877eeca53a150ebaac49adbfb908f9366ac64 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Method.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Shipping/Method.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create\Shipping; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Method diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Store.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Store.php index e2adf9500ecda3443efeb0d67dc8c0754a52524e..f48f0cbd9e3674a7a5c3485082bc7b4d60a9c86a 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Store.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Store.php @@ -8,9 +8,9 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create; use Magento\Store\Test\Fixture\Store as StoreFixture; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; /** * Class Store diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Totals.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Totals.php index fe25005b4c4e94504c0ecefa5382a13b7e403563..39adad4c9f1f3ca2393ffba15fedbf1ec8c65abd 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Totals.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Create/Totals.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Create; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Totals diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Grid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Grid.php index 5f5ad0669dc4dd6e82f14936fb30bd569db060d6..09919efbd1dba62122652d3e52e1317cd4005028 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Grid.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; use Magento\Backend\Test\Block\Widget\Grid as GridInterface; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class Grid @@ -43,6 +43,13 @@ class Grid extends GridInterface */ protected $editLink = 'td[class*=col-action] a'; + /** + * First row selector + * + * @var string + */ + protected $firstRowSelector = '//tbody/tr[1]//a'; + /** * {@inheritdoc} */ diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/History.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/History.php index fbc98583eed061430693a8552560a6a6a43f2053..17d1dd67238c0b4f00531ed5c604ab8ab416c393 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/History.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/History.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Totals diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form.php index 83f8ab5d76e9cb4ae98a7757c35e69051fa7c99b..d6578371062e9a8112127a854007724d6e7e818a 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form.php @@ -27,7 +27,7 @@ class Form extends AbstractForm * * @return Items */ - protected function getItemsBlock() + public function getItemsBlock() { return $this->blockFactory->create( 'Magento\Sales\Test\Block\Adminhtml\Order\Invoice\Form\Items', diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form/Items.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form/Items.php index 73114c21845f1807e7cf1b63c91329289fab0484..ed9f86ca74fa6a144a352f9f9e16efc69c0bd308 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form/Items.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Form/Items.php @@ -8,8 +8,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Invoice\Form; use Magento\Sales\Test\Block\Adminhtml\Order\AbstractItemsNewBlock; use Magento\Sales\Test\Block\Adminhtml\Order\Invoice\Form\Items\Product; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Items diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Grid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Grid.php index 218fa8ee64181e9f3482ce5b43acec21d9a0edbf..8b43fc9c27ba44de78336999a4abb55aa4278999 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Grid.php @@ -60,7 +60,7 @@ class Grid extends GridInterface } /** - * @return mixed|\Mtf\Client\Element + * @return mixed|\Magento\Mtf\Client\Element */ private function getInvoiceAmountElement() { diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Totals.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Totals.php index bd93e1b5bec55284236db2b6445e9691ef6e34ce..0d6ea9e35f77a10539f27bb3bf58a91d52ba324d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Totals.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Invoice/Totals.php @@ -6,14 +6,14 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Invoice; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Totals * Invoice totals block */ -class Totals extends Block +class Totals extends \Magento\Sales\Test\Block\Adminhtml\Order\Totals { /** * Submit invoice button selector @@ -45,7 +45,6 @@ class Totals extends Block return $element->isVisible() == false ? true : null; } ); - $this->reinitRootElement(); $this->_rootElement->find($this->submit)->click(); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/Totals.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/Totals.php index 802c0fd06e65f0e7829ae05243d4c5d2597f741c..b2ae1df8954b5f54206fa90e6af28af8a528f4ee 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/Totals.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/Totals.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Shipment; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Totals diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/View/Items.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/View/Items.php index d94630f31ed88ef8d8915fcdf6c516203eeaca12..55d5b3794342c6a12e21bb7a722a128e6ffab7a9 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/View/Items.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Shipment/View/Items.php @@ -21,7 +21,7 @@ class Items extends AbstractItems */ public function getData() { - $items = $this->_rootElement->find($this->rowItem)->getElements(); + $items = $this->_rootElement->getElements($this->rowItem); $data = []; foreach ($items as $item) { diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Status/Assign/AssignForm.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Status/Assign/AssignForm.php index abd4fe06e23edc960d5be7448dc157593642ab7a..aa776f8bb3051d2ad292dfe3566cea8d035ed050 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Status/Assign/AssignForm.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Status/Assign/AssignForm.php @@ -6,7 +6,7 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\Status\Assign; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class AssignForm diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Totals.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Totals.php index 7359618a265c04c95d55525840f209b9f7a6057a..9cec6a2dcc33a7a1e87cd0177895b154f47b6b81 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Totals.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/Totals.php @@ -6,27 +6,88 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** - * Class Totals - * Order totals block - * + * Invoice totals block */ class Totals extends Block { /** - * Grand total search mask + * Grand total search mask. * * @var string */ protected $grandTotal = '//tr[normalize-space(td)="Grand Total"]//span'; /** - * Get Grand Total Text + * Grand total excluding tax search mask. * - * @return array|string + * @var string + */ + protected $grandTotalExclTax = '//tr[normalize-space(td)="Grand Total (Excl.Tax)"]//span'; + + /** + * Grand total including tax search mask. + * + * @var string + */ + protected $grandTotalInclTax = '//tr[normalize-space(td)="Grand Total (Incl.Tax)"]//span'; + + /** + * Subtotal search mask. + * + * @var string + */ + protected $subtotal = '//tr[normalize-space(td)="Subtotal"]//span'; + + /** + * Subtotal excluding tax search mask. + * + * @var string + */ + protected $subtotalExclTax = '//tr[normalize-space(td)="Subtotal (Excl.Tax)"]//span'; + + /** + * Subtotal including tax search mask. + * + * @var string + */ + protected $subtotalInclTax = '//tr[normalize-space(td)="Subtotal (Incl.Tax)"]//span'; + + /** + * Tax search mask. + * + * @var string + */ + protected $tax = '//tr[normalize-space(td)="Tax"]//span'; + + /** + * Discount search mask. + * + * @var string + */ + protected $discount = '//tr[normalize-space(td)="Discount"]//span'; + + /** + * Shipping excluding tax search mask. + * + * @var string + */ + protected $shippingExclTax = '//tr[contains (.,"Shipping") and contains (.,"(Excl.Tax)")]//span'; + + /** + * Shipping including tax search mask. + * + * @var string + */ + protected $shippingInclTax = '//tr[contains (.,"Shipping") and contains (.,"(Incl.Tax)")]//span'; + + /** + * Get Grand Total Text. + * + * @return string */ public function getGrandTotal() { @@ -35,7 +96,106 @@ class Totals extends Block } /** - * Method that escapes currency symbols + * Get Grand Total Excluding Tax Text. + * + * @return string + */ + public function getGrandTotalExclTax() + { + $grandTotal = $this->_rootElement->find($this->grandTotalExclTax, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($grandTotal); + } + + /** + * Get Grand Total Including Tax Text. + * + * @return string + */ + public function getGrandTotalInclTax() + { + $grandTotal = $this->_rootElement->find($this->grandTotalInclTax, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($grandTotal); + } + + /** + * Get Tax text from Order Totals. + * + * @return string + */ + public function getTax() + { + $tax = $this->_rootElement->find($this->tax, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($tax); + } + + /** + * Get Tax text from Order Totals. + * + * @return string|null + */ + public function getDiscount() + { + $discount = $this->_rootElement->find($this->discount, Locator::SELECTOR_XPATH); + return $discount->isVisible() ? $this->escapeCurrency($discount->getText()) : null; + } + + /** + * Get Subtotal text. + * + * @return string + */ + public function getSubtotal() + { + $subTotal = $this->_rootElement->find($this->subtotal, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Subtotal text. + * + * @return string + */ + public function getSubtotalExclTax() + { + $subTotal = $this->_rootElement->find($this->subtotalExclTax, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Subtotal text. + * + * @return string + */ + public function getSubtotalInclTax() + { + $subTotal = $this->_rootElement->find($this->subtotalInclTax, Locator::SELECTOR_XPATH)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Shipping Excluding tax price text. + * + * @return string|null + */ + public function getShippingInclTax() + { + $subTotal = $this->_rootElement->find($this->shippingInclTax, Locator::SELECTOR_XPATH); + return $subTotal->isVisible() ? $this->escapeCurrency($subTotal->getText()) : null; + } + + /** + * Get Shipping Including tax price text. + * + * @return string|null + */ + public function getShippingExclTax() + { + $subTotal = $this->_rootElement->find($this->shippingExclTax, Locator::SELECTOR_XPATH); + return $subTotal->isVisible() ? $this->escapeCurrency($subTotal->getText()) : null; + } + + /** + * Method that escapes currency symbols. * * @param string $price * @return string|null diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Info.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Info.php index dd2f976734d011f0601a3a8a64feacccaf9dde67..cf49d099f2ade9778ab8f5f78cff88e6e837e876 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Info.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Info.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\View; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Block for information about customer on order page diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Items.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Items.php index 2ff583eeb4d8268244019eb716e75ee567481f7b..00da4a3db47cf4426ef78e5a3b35f68cec8e9b65 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Items.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Items.php @@ -8,8 +8,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\View; use Magento\Catalog\Test\Fixture\Product; use Magento\ConfigurableProduct\Test\Fixture\ConfigurableProduct; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Items @@ -24,6 +24,36 @@ class Items extends Block */ protected $priceSelector = '//div[@class="price-excl-tax"]//span[@class="price"]'; + // @codingStandardsIgnoreStart + /** + * Product price excluding tax search mask + * + * @var string + */ + protected $itemExclTax = '//tr[contains (.,"%s")]/td[@class="col-price"]/div[@class="price-excl-tax"]/span[@class="price"]'; + + /** + * Product price including tax search mask + * + * @var string + */ + protected $itemInclTax = '//tr[contains (.,"%s")]/td[@class="col-price"]/div[@class="price-incl-tax"]/span[@class="price"]'; + + /** + * Product price subtotal excluding tax search mask + * + * @var string + */ + protected $itemSubExclTax = '//tr[contains (.,"%s")]/td[@class="col-subtotal"]/div[@class="price-excl-tax"]/span[@class="price"]'; + + /** + * Product price subtotal including tax search mask + * + * @var string + */ + protected $itemSubInclTax = '//tr[contains (.,"%s")]/td[@class="col-subtotal"]/div[@class="price-incl-tax"]/span[@class="price"]'; + // @codingStandardsIgnoreEnd + /** * Returns the item price for the specified product. * @@ -53,4 +83,68 @@ class Items extends Block return $this->_rootElement->find($selector, Locator::SELECTOR_XPATH)->getText(); } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemPriceExclTax($productName) + { + $locator = sprintf($this->itemExclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price including tax + * + * @param string $productName + * @return string|null + */ + public function getItemPriceInclTax($productName) + { + $locator = sprintf($this->itemInclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemSubExclTax($productName) + { + $locator = sprintf($this->itemSubExclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemSubInclTax($productName) + { + $locator = sprintf($this->itemSubInclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Method that escapes currency symbols + * + * @param string $price + * @return string|null + */ + protected function escapeCurrency($price) + { + preg_match("/^\\D*\\s*([\\d,\\.]+)\\s*\\D*$/", $price, $matches); + return (isset($matches[1])) ? $matches[1] : null; + } } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/CreditMemos/Grid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/CreditMemos/Grid.php index ffe386848bd6fe0aedba5dc2cfb1d5026a9fca09..741eeaabdab3c3ffba0af6ea372d3900d462e81b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/CreditMemos/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/CreditMemos/Grid.php @@ -58,7 +58,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid public function getIds() { $result = []; - $creditMemoIds = $this->_rootElement->find($this->editLink)->getElements(); + $creditMemoIds = $this->_rootElement->getElements($this->editLink); foreach ($creditMemoIds as $creditMemoId) { $result[] = trim($creditMemoId->getText()); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Info.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Info.php index bbd19f9474c45116d71e5c9ddd0488983db9ddd6..aac809e587dc15dec3869fd4730c4313dedb74b0 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Info.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Info.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Adminhtml\Order\View\Tab; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Info diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Invoices/Grid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Invoices/Grid.php index e329aa3cef34f86c5546fadd7dbb6ffac8a45422..4e22f9ce2dfb8e53f486ee7df7e32627dc37745b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Invoices/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Invoices/Grid.php @@ -55,7 +55,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid public function getIds() { $result = []; - $invoiceIds = $this->_rootElement->find($this->invoiceId)->getElements(); + $invoiceIds = $this->_rootElement->getElements($this->invoiceId); foreach ($invoiceIds as $invoiceId) { $result[] = trim($invoiceId->getText()); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Shipments/Grid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Shipments/Grid.php index 20a5d98d797c341140ed59645b958c15af34c871..5fa33144c2fd055f995be9495100629b6e226f4b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Shipments/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Adminhtml/Order/View/Tab/Shipments/Grid.php @@ -51,7 +51,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid public function getIds() { $result = []; - $shipmentIds = $this->_rootElement->find($this->shipmentId)->getElements(); + $shipmentIds = $this->_rootElement->getElements($this->shipmentId); foreach ($shipmentIds as $shipmentId) { $result[] = trim($shipmentId->getText()); } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/History.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/History.php index 040609465d2e6804ee9636f1a39e2e0e9e320025..b93056743ecc3f1b1ab802b55b748400e98deeff 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/History.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/History.php @@ -6,9 +6,9 @@ namespace Magento\Sales\Test\Block\Order; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class History @@ -73,7 +73,7 @@ class History extends Block * Get item order block * * @param string $id - * @return Element + * @return SimpleElement */ protected function searchOrderById($id) { diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Info.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Info.php index 09736394f69de97f2cbfb238b5808b3688f8dd36..9b7fc95983636154ea053e249872e8662a001fcb 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Info.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Info.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Info block on order's view page. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Items.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Items.php index 25b0e963b1d3df4fc04380731afe18b9de35047c..d044f994ac56efe9453b22eec126a87067ef4bca 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Items.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/Items.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Items block on order's view page @@ -31,7 +31,7 @@ class Items extends Block /** * Check if item is visible in print order page. * - * @param \Mtf\Fixture\InjectableFixture $product + * @param \Magento\Mtf\Fixture\InjectableFixture $product * @return bool */ public function isItemVisible($product) diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View.php index 9829f417cff81ce12f09f21d52c79e23cc65eebe..c8cb4a49db99ea30bfb4df35c1188ab72cef5c2f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View.php @@ -6,12 +6,14 @@ namespace Magento\Sales\Test\Block\Order; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class View * View block on order's view page + * + * @SuppressWarnings(PHPMD.TooManyFields) */ class View extends Block { @@ -36,6 +38,99 @@ class View extends Block */ protected $link = '//*[contains(@class,"order-links")]//a[normalize-space(.)="%s"]'; + /** + * Grand total search mask + * + * @var string + */ + protected $grandTotal = '.grand_total span'; + + /** + * Grand total including tax search mask + * + * @var string + */ + protected $grandTotalInclTax = '.grand_total_incl span'; + + /** + * Subtotal search mask + * + * @var string + */ + protected $subtotal = '.subtotal .amount span'; + + /** + * Subtotal excluding tax search mask + * + * @var string + */ + protected $subtotalExclTax = '.subtotal_excl span'; + + /** + * Subtotal including tax search mask + * + * @var string + */ + protected $subtotalInclTax = '.subtotal_incl span'; + + /** + * Tax search mask + * + * @var string + */ + protected $tax = '.totals-tax span'; + + /** + * Discount search mask + * + * @var string + */ + protected $discount = '.discount span'; + + /** + * Shipping search mask + * + * @var string + */ + protected $shippingExclTax = '.shipping span'; + + /** + * Shipping search mask + * + * @var string + */ + protected $shippingInclTax = '.shipping_incl span'; + + /** + * Product price excluding tax search mask + * + * @var string + */ + protected $itemExclTax = '//tr[contains (.,"%s")]/td[@class="col price"]/span[@class="price-excluding-tax"]/span'; + + /** + * Product price including tax search mask + * + * @var string + */ + protected $itemInclTax = '//tr[contains (.,"%s")]/td[@class="col price"]/span[@class="price-including-tax"]/span'; + + // @codingStandardsIgnoreStart + /** + * Product price subtotal excluding tax search mask + * + * @var string + */ + protected $itemSubExclTax = '//tr[contains (.,"%s")]/td[@class="col subtotal"]/span[@class="price-excluding-tax"]/span'; + + /** + * Product price subtotal including tax search mask + * + * @var string + */ + protected $itemSubInclTax = '//tr[contains (.,"%s")]/td[@class="col subtotal"]/span[@class="price-including-tax"]/span'; + // @codingStandardsIgnoreEnd + /** * Get item block * @@ -61,4 +156,167 @@ class View extends Block { $this->_rootElement->find(sprintf($this->link, $name), Locator::SELECTOR_XPATH)->click(); } + + /** + * Get Grand Total Text + * + * @return string + */ + public function getGrandTotal() + { + $grandTotal = $this->_rootElement->find($this->grandTotal, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($grandTotal); + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemPriceExclTax($productName) + { + $locator = sprintf($this->itemExclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemPriceInclTax($productName) + { + $locator = sprintf($this->itemInclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemSubExclTax($productName) + { + $locator = sprintf($this->itemSubExclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Item price excluding tax + * + * @param string $productName + * @return string|null + */ + public function getItemSubInclTax($productName) + { + $locator = sprintf($this->itemSubInclTax, $productName); + $price = $this->_rootElement->find($locator, Locator::SELECTOR_XPATH); + return $price->isVisible() ? $this->escapeCurrency($price->getText()) : null; + } + + /** + * Get Grand Total Text + * + * @return string|null + */ + public function getGrandTotalInclTax() + { + $grandTotal = $this->_rootElement->find($this->grandTotalInclTax, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($grandTotal); + } + + /** + * Get Tax text from Order Totals + * + * @return string + */ + public function getTax() + { + $tax = $this->_rootElement->find($this->tax, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($tax); + } + + /** + * Get Tax text from Order Totals + * + * @return string|null + */ + public function getDiscount() + { + $discount = $this->_rootElement->find($this->discount, Locator::SELECTOR_CSS); + return $discount->isVisible() ? $this->escapeCurrency($discount->getText()) : null; + } + + /** + * Get Subtotal text + * + * @return string + */ + public function getSubtotal() + { + $subTotal = $this->_rootElement->find($this->subtotal, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Subtotal text + * + * @return string + */ + public function getSubtotalExclTax() + { + $subTotal = $this->_rootElement->find($this->subtotalExclTax, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Subtotal text + * + * @return string + */ + public function getSubtotalInclTax() + { + $subTotal = $this->_rootElement->find($this->subtotalInclTax, Locator::SELECTOR_CSS)->getText(); + return $this->escapeCurrency($subTotal); + } + + /** + * Get Shipping Excluding tax price text + * + * @return string|null + */ + public function getShippingInclTax() + { + $subTotal = $this->_rootElement->find($this->shippingInclTax, Locator::SELECTOR_CSS); + return $subTotal->isVisible() ? $this->escapeCurrency($subTotal->getText()) : null; + } + + /** + * Get Shipping Including tax price text + * + * @return string|null + */ + public function getShippingExclTax() + { + $subTotal = $this->_rootElement->find($this->shippingExclTax, Locator::SELECTOR_CSS); + return $subTotal->isVisible() ? $this->escapeCurrency($subTotal->getText()) : null; + } + + /** + * Method that escapes currency symbols + * + * @param string $price + * @return string|null + */ + protected function escapeCurrency($price) + { + preg_match("/^\\D*\\s*([\\d,\\.]+)\\s*\\D*$/", $price, $matches); + return (isset($matches[1])) ? $matches[1] : null; + } } diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View/ActionsToolbar.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View/ActionsToolbar.php index bd613531c7b68fa5717e1a38ed51e37efa55982e..4c5756fecffd692f2951fa4f406f36b5de2ce106 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View/ActionsToolbar.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Block/Order/View/ActionsToolbar.php @@ -6,8 +6,8 @@ namespace Magento\Sales\Test\Block\Order\View; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Order view block. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertItems.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertItems.php index e40173a7ed11e62ed4fd4a22df6b563d620a59dd..041e7d7d5865eb3d4d62a64d32a3eafa2b5cabce 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertItems.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertItems.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Sales\Test\Fixture\OrderInjectable; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AbstractAssertArchiveItems diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertOrderOnFrontend.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertOrderOnFrontend.php index cd09e9e27e1311297fc2262b719b516a67d1193b..3ebe97e8f48a83691c99350d88dae914e00409c3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertOrderOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AbstractAssertOrderOnFrontend.php @@ -9,8 +9,8 @@ namespace Magento\Sales\Test\Constraint; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; -use Mtf\Constraint\AbstractConstraint; -use Mtf\ObjectManager; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\ObjectManager; /** * Abstract Class AbstractAssertOrderOnFrontend diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertCreditMemoButton.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertCreditMemoButton.php index 73cd390792abe1108866d22ea5246f7d8c1b2363..16edae0465421bcf9ac4110b5854bf0401955d30 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertCreditMemoButton.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertCreditMemoButton.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertCreditMemoButton diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesGrid.php index 6232e4c36988f56df2ba501398929a29e696d426..8c5e6da90764aa78f63ff87c4fb319b71997b3b3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\InvoiceIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertInvoiceInInvoicesGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesTab.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesTab.php index 9aa105083f39b6d758b87c39e78ddee1a68bb8d1..bee911273739c4d59b28be62b2a19a26bb857328 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesTab.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceInInvoicesTab.php @@ -10,7 +10,7 @@ use Magento\Sales\Test\Block\Adminhtml\Order\View\Tab\Invoices\Grid; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertInvoiceInInvoicesTab diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceSuccessCreateMessage.php index ab9529606e3edef41da743760a64475338aeb98c..9faaaece512319d6b4dd5f33c014f917c47cfd43 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertInvoiceSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceWithShipmentSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceWithShipmentSuccessMessage.php index dee20ee6e3f931d9ec59cf129ab4048cabcc4824..15582ebab753641fa97d9e21fec6af17a38cc93d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceWithShipmentSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertInvoiceWithShipmentSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertInvoiceWithShipmentSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoCreditMemoButton.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoCreditMemoButton.php index 1830982dc35b5aa410a2f3f90c35c4af93631f04..27168972b067265f5064f06edd8674a5524eaf72 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoCreditMemoButton.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoCreditMemoButton.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNoCreditMemoButton diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoInvoiceButton.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoInvoiceButton.php index faf9c3848f7fba07399aba4f65a35a3836be8a42..448ec5ef79605fdb8801b869f6c849850727739a 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoInvoiceButton.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertNoInvoiceButton.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNoInvoiceButton diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsAvailable.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsAvailable.php index f4fea87c5ea42d3c94425856c40026eed6dd0ac3..4e28fce3ab6084a9628b9e1c0d572a76003b334d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsAvailable.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsAvailable.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\SalesOrder; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderButtonsAvailable diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsUnavailable.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsUnavailable.php index 2642586da0bb2af63ac85294fc30ec068de7af8b..1a2171ee10c930de1968fda06587dcc64d851bb5 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsUnavailable.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderButtonsUnavailable.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderButtonsUnavailable diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionFailMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionFailMessage.php index c466e7bb75c9ed5f8e63da3b75748ba52cd1802d..890c0724d7d3a8d80c7c94737c73ad65bc1b1c15 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionFailMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionFailMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderCancelMassActionFailMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionSuccessMessage.php index 3471a9bc34922c8e99b9a09e504aea246e1eec3d..2714f10fbb2081083b2226219039d20fcd59a2eb 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelMassActionSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderCancelMassActionSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelSuccessMessage.php index b8859fad542f39d0e47d648ba85e739d5fea6336..5c164d1aee7ca5f4d98158bd4fbabf50097e6bc6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderCancelSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderCancelSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderGrandTotal.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderGrandTotal.php index 002ae82bde4e83c30ec55165b3e857a269554587..317e93fbb00161b74eda8cff1e20681abab1559f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderGrandTotal.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderGrandTotal.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderGrandTotal diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGrid.php index a02eacd05f20fe2217d660ab0ea71c46a1870b4f..691173f3cc28d44be7af94ed9bf87f7cb9aaf726 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderInOrdersGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGridOnFrontend.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGridOnFrontend.php index be39a398072ec2b96e5f59175dd9f7a602569b19..8b4dd2454da918f594c65a8643636c53d2fe94b0 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGridOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderInOrdersGridOnFrontend.php @@ -10,8 +10,8 @@ use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\OrderHistory; -use Mtf\Constraint\AbstractConstraint; -use Mtf\ObjectManager; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\ObjectManager; /** * Class AssertOrderInOrdersGridOnFrontend diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderMassOnHoldSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderMassOnHoldSuccessMessage.php index 57cf7ce184fe299cfc15601dd2a2680fb546298c..1f1508c0c422ae9e061dfcc4cd6f005bbd1a914b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderMassOnHoldSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderMassOnHoldSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderMassOnHoldSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotInOrdersGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotInOrdersGrid.php index 7960d579a4f2d4c8e3cd055bd79dfd1500562ab5..c89d729ef6e6b5518028288119b1af33adf4f952 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotInOrdersGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotInOrdersGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderNotInOrdersGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotVisibleOnMyAccount.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotVisibleOnMyAccount.php index 3ea3556f69db105a36ef21b94a7c54b3c322d93f..595a9428edaf972135a32ff0e08d040a4b643a53 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotVisibleOnMyAccount.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderNotVisibleOnMyAccount.php @@ -10,8 +10,8 @@ use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\OrderHistory; -use Mtf\Constraint\AbstractConstraint; -use Mtf\ObjectManager; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\ObjectManager; /** * Class AssertOrderNotVisibleOnMyAccount diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldFailMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldFailMessage.php index 828155468a5a8355e3c705ea8c9a8e0bf995d0e8..2c7a6342539be30df9851e4af463a0b2877a46ed 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldFailMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldFailMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderOnHoldFailMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldSuccessMessage.php index 0ac614fd93545076c2d6f5de2fe51a57ba4f9945..38d9ff38c11a4c93434c20511d5361444194daca 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderOnHoldSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderOnHoldSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseFailMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseFailMessage.php index 425e708fea9d68ea1c47de7694f5f179f6167a99..a672710661db1d8f5fe9514c3d3c684af945aaea 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseFailMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseFailMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderReleaseFailMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseSuccessMessage.php index 6844fa76977758dbb6fa4bf0c04ac92073e83595..2fd559d9a3c2d325195b66246df1d40dfd8a5e55 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderReleaseSuccessMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderReleaseSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusDuplicateStatus.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusDuplicateStatus.php index 401787f33474e491137d02dcbda7b7ebccfd355c..4e6788febec0d855e43c6e12668f3e92a2b45b8f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusDuplicateStatus.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusDuplicateStatus.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderStatusNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusDuplicateStatus diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusInGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusInGrid.php index c9cab376d3b1603d1964d01d4f43eaad35a4e4f8..de3cd7e0311f96e6004204601aa782fdba97c83f 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderStatus; use Magento\Sales\Test\Page\Adminhtml\OrderStatusIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusInGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusIsCorrect.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusIsCorrect.php index 9c9179d99497d5890dae9f4ae250caca964b6200..dc5d15ca4eb5c6c98be66465bb34eb17252e69d4 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusIsCorrect.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusIsCorrect.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusIsCorrect diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusNotAssigned.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusNotAssigned.php index 494b6f7fa8a32b026acd422b7616daa06f9b13b5..5fa8631ae83b566d57b2bedd44c578b9e7a5e8ea 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusNotAssigned.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusNotAssigned.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderStatus; use Magento\Sales\Test\Page\Adminhtml\OrderStatusIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusNotAssigned diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessAssignMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessAssignMessage.php index a68f4baa55859435925cbb10b75054e0c084e5c7..e75979c48235c5c7dc8ff8b3b2f9f8a169c9feef 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessAssignMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessAssignMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderStatusIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusSuccessAssignMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessCreateMessage.php index 760d8e0bae3b71b22b7a19457091dd3584739af0..486b801dbed5c02e07b08753d1b2f256003a523e 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderStatusIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessUnassignMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessUnassignMessage.php index 1f6465ab0ae160bdd62438da9c4a59357080bb12..bc30beb1c1e3a3749329a3463bee4a31262f547a 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessUnassignMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderStatusSuccessUnassignMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderStatusIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderStatusSuccessUnassignMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderSuccessCreateMessage.php index d5a501662a8326200157f9f0a5e91bb7822210bd..11582827fd8b014d63729cf89c91f9c1ef8b7dee 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrderSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrderSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrdersInOrdersGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrdersInOrdersGrid.php index 36067368dd885bbda02462f9f0907c75835a3e6e..5f6e0e6dc22586b80229a082ad93c50d68c689c3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrdersInOrdersGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertOrdersInOrdersGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertOrdersInOrdersGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertProductInItemsOrderedGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertProductInItemsOrderedGrid.php index 078aaaac15334f302788557d05f240e4260d328c..ac10f70210745182a3233081c3b773b797a26aed 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertProductInItemsOrderedGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertProductInItemsOrderedGrid.php @@ -8,8 +8,8 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Block\Adminhtml\Order\Create\Items; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureInterface; /** * Assert product was added to Items Ordered grid in customer account on Order creation page backend. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInCreditMemoTab.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInCreditMemoTab.php index a821193e2b1e22ee1d90dd79869b4cbff92aa86c..21e33cea1ef6b1080165d62c4112b1db2f67c75b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInCreditMemoTab.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInCreditMemoTab.php @@ -10,7 +10,7 @@ use Magento\Sales\Test\Block\Adminhtml\Order\View\Tab\CreditMemos\Grid; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRefundInCreditMemoTab diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInRefundsGrid.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInRefundsGrid.php index ffdaf05743f28f18a0b53e6d59bbdf973490aac5..9583a712adee58939be76ca8113397c8b465bfce 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInRefundsGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundInRefundsGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\CreditMemoIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRefundInRefundsGrid diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundSuccessCreateMessage.php index fd74aa59a15e4cda88c9726173ec90569297a139..d619f949f4e83331471b0847c3b6d7095ee833e4 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertRefundSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRefundSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertReorderStatusIsCorrect.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertReorderStatusIsCorrect.php index 0d3aad30ad1a1f219b2d002e2153ae88e0de44f2..46e188fe74d2015442300d98382dfff20cd3f3a3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertReorderStatusIsCorrect.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertReorderStatusIsCorrect.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertReorderStatusIsCorrect diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderBillingAddress.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderBillingAddress.php index 01e8c1ca9084aea131900ded0082b65baf15f345..8c6c78230ea1781b1d80f91512359e6c28e3f812 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderBillingAddress.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderBillingAddress.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Sales\Test\Page\SalesGuestPrint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that BillingAddress printed correctly on sales guest print page. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderGrandTotal.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderGrandTotal.php index 362a43cd644723dc6c22ce4d9f3685c62ac00c48..586d9925e8ac9e9b74cd01fe6e69dddedc396c7d 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderGrandTotal.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderGrandTotal.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\SalesGuestPrint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that Grand Total price was printed correctly on sales guest print page. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderPaymentMethod.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderPaymentMethod.php index f50ada3b1719e5215ba65bde5204e4e22c1b9e05..dab302d4283218b50693ed2794d51c14496e4966 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderPaymentMethod.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderPaymentMethod.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\SalesGuestPrint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that payment method was printed correctly on sales guest print page. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderProducts.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderProducts.php index bc359b7f343b92fad52beeda1f4fa92aa9b1e430..05940cb7bc5ce5975adf34f151ca7a8cc0eea4b1 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderProducts.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertSalesPrintOrderProducts.php @@ -7,8 +7,8 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Page\SalesGuestPrint; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Assert that products printed correctly on sales guest print page. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertUnholdButton.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertUnholdButton.php index fa07944b9ed11747d414a43d26b3487d800cda85..dc9aab4a6a6da420a44788c3734c1c0ef5633405 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertUnholdButton.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Constraint/AssertUnholdButton.php @@ -9,7 +9,7 @@ namespace Magento\Sales\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUnholdButton diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Page/Adminhtml/OrderCreditMemoNew.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/Page/Adminhtml/OrderCreditMemoNew.xml index f7c762432c4d70b557badfc7bd57c5047ea75f76..08bab6e84bf9809b1b24344753cebad4db51af8b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Page/Adminhtml/OrderCreditMemoNew.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Page/Adminhtml/OrderCreditMemoNew.xml @@ -17,5 +17,10 @@ <locator>#edit_form</locator> <strategy>css selector</strategy> </formBlock> + <totalsBlock> + <class>Magento\Sales\Test\Block\Adminhtml\Order\Creditmemo\Totals</class> + <locator>.creditmemo-totals</locator> + <strategy>css selector</strategy> + </totalsBlock> </blocks> </page> diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/Page/SalesOrderShipmentNew.php b/dev/tests/functional/tests/app/Magento/Sales/Test/Page/SalesOrderShipmentNew.php index 70fd8a828474ad11e9e24c368a556d22a5bfd059..352f752784045a12c0f3549332fbf48832a82844 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/Page/SalesOrderShipmentNew.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/Page/SalesOrderShipmentNew.php @@ -6,9 +6,9 @@ namespace Magento\Sales\Test\Page; -use Mtf\Client\Element\Locator; -use Mtf\Factory\Factory; -use Mtf\Page\Page; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Page\Page; /** * Class SalesOrder diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddProductsStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddProductsStep.php index 7106416ff98e5b53ce36a69edc5d9f2266e5d656..ed71060eb94032aae9d31f875bac42634fd6efdf 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddProductsStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddProductsStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class AddProductsStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddRecentlyViewedProductsToCartStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddRecentlyViewedProductsToCartStep.php index 3955d13be0037958089135b297068403451ead57..d995a2c78298b4d2932cf9836377407933f321eb 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddRecentlyViewedProductsToCartStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/AddRecentlyViewedProductsToCartStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Add Recently Viewed Products to cart. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ConfigureProductsStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ConfigureProductsStep.php index 887a578b2167de6fcfaf24f70d3d881ed189dde7..af0c71dbfcdfe76e2fc6e85a8cb68dc126a4c5c4 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ConfigureProductsStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ConfigureProductsStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Configure products options on backend order. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/CreateNewOrderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/CreateNewOrderStep.php index c0c320d6257c47553dbd176762080dd1908c939b..72b6789e700658faded052aaa929ff870dc8e32b 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/CreateNewOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/CreateNewOrderStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class CreateNewOrderStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/FillBillingAddressStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/FillBillingAddressStep.php index 21519711065fef9d75ff044126b2c215efe7c7af..a5931b05e83d8b5418f6c128ccbb4f25ce307ff2 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/FillBillingAddressStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/FillBillingAddressStep.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Fill Sales Data. diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/OpenSalesOrdersStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/OpenSalesOrdersStep.php index 6deab5e8fe9b93d95c3f3727d0df1ec107c31794..1be4db9517179c5e3815217234e2c296534ed5b6 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/OpenSalesOrdersStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/OpenSalesOrdersStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class OpenSalesOrdersStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/PrintOrderOnFrontendStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/PrintOrderOnFrontendStep.php index af8be31ec7c7e49fddbb9f6eaf656e9ab1e62470..a810a3ca608a2cd7927e12316d731b3b4ce47d4a 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/PrintOrderOnFrontendStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/PrintOrderOnFrontendStep.php @@ -7,8 +7,8 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\SalesGuestView; -use Mtf\Client\Browser; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Click on "Print Order" button. @@ -25,16 +25,16 @@ class PrintOrderOnFrontendStep implements TestStepInterface /** * Browser. * - * @var Browser + * @var BrowserInterface */ protected $browser; /** * @constructor * @param SalesGuestView $salesGuestView - * @param Browser $browser + * @param BrowserInterface $browser */ - public function __construct(SalesGuestView $salesGuestView, Browser $browser) + public function __construct(SalesGuestView $salesGuestView, BrowserInterface $browser) { $this->salesGuestView = $salesGuestView; $this->browser = $browser; diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ReorderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ReorderStep.php index b3f7eaa7a0d3dbe9baef052159e003d61d60cf59..8485a0831ba0aaef8bfb49b81e610d30ea09d45c 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ReorderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/ReorderStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class ReorderStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectCustomerOrderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectCustomerOrderStep.php index a88e41d3bfb99b4a53b787a4264ef65c1b431c67..8c1d84dd8ea81053acd4a03ae53d691ae4b593a3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectCustomerOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectCustomerOrderStep.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectCustomerOrderStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectPaymentMethodForOrderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectPaymentMethodForOrderStep.php index 9c523d6db89c6c84349004bf717183280dd40ad9..73b774cb7c3d761780cd58e6e82c74f19f872252 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectPaymentMethodForOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectPaymentMethodForOrderStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectPaymentMethodForOrderStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectShippingMethodForOrderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectShippingMethodForOrderStep.php index 96dffd305c8c278bafaa78797f5ddbf23807a786..8b9a8d370cf501eefd82252cb275dc5e52863fcd 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectShippingMethodForOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectShippingMethodForOrderStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectShippingMethodForOrderStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectStoreStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectStoreStep.php index d3945c15ad7e03e90da1e9065ca243e54c7d7468..d8e82f4e2bc7177c97bb14d0f8f33959679d3a61 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectStoreStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SelectStoreStep.php @@ -8,7 +8,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class SelectStoreStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SubmitOrderStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SubmitOrderStep.php index 0623946e4c2e3e7ddbe5e6c973a491eb0d255b72..f9195c378758104fbc27cdc72e155dc59e21d6e3 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SubmitOrderStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/SubmitOrderStep.php @@ -10,8 +10,8 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestStep\TestStepInterface; /** * Submit Order step. @@ -46,7 +46,7 @@ class SubmitOrderStep implements TestStepInterface * @param FixtureFactory $fixtureFactory * @param CustomerInjectable $customer * @param AddressInjectable $billingAddress - * @param \Mtf\Fixture\FixtureInterface[] $products + * @param \Magento\Mtf\Fixture\FixtureInterface[] $products */ public function __construct( OrderCreateIndex $orderCreateIndex, diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/UpdateProductsDataStep.php b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/UpdateProductsDataStep.php index 8302240bdd7441a8c7f7b6cdfea76b59b9ad1b5e..525b5b430edf93d2f0c9894676edd0d6f9276069 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/UpdateProductsDataStep.php +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/TestStep/UpdateProductsDataStep.php @@ -7,7 +7,7 @@ namespace Magento\Sales\Test\TestStep; use Magento\Sales\Test\Page\Adminhtml\OrderCreateIndex; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class UpdateProductsDataStep diff --git a/dev/tests/functional/tests/app/Magento/Sales/Test/etc/scenario.xml b/dev/tests/functional/tests/app/Magento/Sales/Test/etc/scenario.xml index a6d5580a48132d15f6fa6d6f4e6d5e63fb8d8782..fb2d6e3eb72468d481f27e77883cc4d8190584c2 100644 --- a/dev/tests/functional/tests/app/Magento/Sales/Test/etc/scenario.xml +++ b/dev/tests/functional/tests/app/Magento/Sales/Test/etc/scenario.xml @@ -5,7 +5,7 @@ * See COPYING.txt for license details. */ --> -<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Mtf/Config/etc/scenario.xsd"> +<scenarios xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/mtf/Magento/Mtf/Config/etc/scenario.xsd"> <scenario name="ReorderOrderEntityTest" module="Magento_Sales"> <methods> <method name="test"> diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking.php index b55425200e73c09adcb8d047ea03405d5bdc81cb..9b4b3aa98aca839fa3ab0aa60bf89db68e41a21a 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking.php @@ -7,8 +7,8 @@ namespace Magento\Shipping\Test\Block\Adminhtml\Order; use Magento\Shipping\Test\Block\Adminhtml\Order\Tracking\Item; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Tracking diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking/Item.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking/Item.php index dd3d4c017035b77a09cdf5b46d5ab284ba9906dc..df2c3cc1a8eb1a6377bf83531aa344f142ce153a 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking/Item.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Adminhtml/Order/Tracking/Item.php @@ -6,7 +6,7 @@ namespace Magento\Shipping\Test\Block\Adminhtml\Order\Tracking; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Item diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Info.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Info.php index 79414714d808b9eb3abfcd08ea1d6df747220165..b5ca395ff72ed92a89231aba8714b6484d53ed00 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Info.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Info.php @@ -6,7 +6,7 @@ namespace Magento\Shipping\Test\Block\Order; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Info block on order's view page. diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment.php index a27dfcb6c3c6e786c4ec50298e62daed01e39e7b..496229684077ae0d0ea0a8afd378cd4cde195559 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment.php @@ -7,8 +7,8 @@ namespace Magento\Shipping\Test\Block\Order; use Magento\Shipping\Test\Block\Order\Shipment\Items; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Shipment diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment/Items.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment/Items.php index 69b2eb4e618578ce25c4d0a31d1ce67d471b006e..463f84b7f87437413255d0027f6231810ee7d129 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment/Items.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Block/Order/Shipment/Items.php @@ -6,7 +6,7 @@ namespace Magento\Shipping\Test\Block\Order\Shipment; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Items diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertNoShipButton.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertNoShipButton.php index 8a0b406fee8c0f69837d7db06772de313915617b..ae61d24ecd11359c52df316824c27d0d19a03fcc 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertNoShipButton.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertNoShipButton.php @@ -9,7 +9,7 @@ namespace Magento\Shipping\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertNoShipButton diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsGrid.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsGrid.php index ee51687746f49b540099c10a00cf9784418fda13..144fab6e4b9d4780bd550c8e0193250d36aa985a 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsGrid.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsGrid.php @@ -8,7 +8,7 @@ namespace Magento\Shipping\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Shipping\Test\Page\Adminhtml\ShipmentIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertShipmentInShipmentsGrid diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsTab.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsTab.php index abb101e24fa1fe9d7c87d1381c46c3874efc194b..76997e744f74c9b07317f87f40df400a56857b39 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsTab.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentInShipmentsTab.php @@ -9,7 +9,7 @@ namespace Magento\Shipping\Test\Constraint; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Sales\Test\Page\Adminhtml\OrderIndex; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertShipmentInShipmentsTab diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentItems.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentItems.php index 68a79182af9f399d37297d4733e88a81c60fcd69..84d5d5ff797e3835c48f1277ed1e41a887cda428 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentItems.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentItems.php @@ -10,7 +10,7 @@ use Magento\Sales\Test\Constraint\AbstractAssertItems; use Magento\Sales\Test\Fixture\OrderInjectable; use Magento\Shipping\Test\Page\Adminhtml\SalesShipmentView; use Magento\Shipping\Test\Page\Adminhtml\ShipmentIndex; -use Mtf\ObjectManager; +use Magento\Mtf\ObjectManager; /** * Class AssertShipmentItems diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentSuccessCreateMessage.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentSuccessCreateMessage.php index adffababcc307c81f825f513a6e05f37a8d21949..ce32f38f424c4b3433c2186ddcc989d3548f1f2f 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentSuccessCreateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShipmentSuccessCreateMessage.php @@ -7,7 +7,7 @@ namespace Magento\Shipping\Test\Constraint; use Magento\Sales\Test\Page\Adminhtml\OrderView; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertShipmentSuccessCreateMessage diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShippingMethodOnPrintOrder.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShippingMethodOnPrintOrder.php index ca2bce698bb7036ad24c53a39863324717300f3b..2caba99cd140e11be67618957f371b8090b4eb62 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShippingMethodOnPrintOrder.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Constraint/AssertShippingMethodOnPrintOrder.php @@ -7,7 +7,7 @@ namespace Magento\Shipping\Test\Constraint; use Magento\Sales\Test\Page\SalesGuestPrint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Assert that shipping method was printed correctly on sales guest print page. diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Fixture/Method.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Fixture/Method.php index 00d76e6901332fcc689d83115d8e1110edb823ee..9c4d03783129221cee78452ef37d551b41448b86 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Fixture/Method.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Fixture/Method.php @@ -6,8 +6,8 @@ namespace Magento\Shipping\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class Method diff --git a/dev/tests/functional/tests/app/Magento/Shipping/Test/Repository/Method.php b/dev/tests/functional/tests/app/Magento/Shipping/Test/Repository/Method.php index 7bb948e124ed12683ad14cc83a9dc9da48237813..6f13fc81e55b5b61db5ba169d6f32f203162c7ec 100644 --- a/dev/tests/functional/tests/app/Magento/Shipping/Test/Repository/Method.php +++ b/dev/tests/functional/tests/app/Magento/Shipping/Test/Repository/Method.php @@ -6,7 +6,7 @@ namespace Magento\Shipping\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Method Repository diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Block/Adminhtml/SitemapGrid.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Block/Adminhtml/SitemapGrid.php index 31b9f7ab48759e7470cb25c62b8fb43ac83c9691..2781dec51ad6bdea3d7dd1f3aa2cfd8f279e85a3 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Block/Adminhtml/SitemapGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Block/Adminhtml/SitemapGrid.php @@ -7,7 +7,7 @@ namespace Magento\Sitemap\Test\Block\Adminhtml; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; /** * Class SitemapGrid diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapContent.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapContent.php index a193569f961026dc814c454586f344e1bff65128..d476d23c66ca418fef38814ce6121377c042aa29 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapContent.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapContent.php @@ -11,7 +11,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\Cms\Test\Fixture\CmsPage; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapContent diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailFolderSaveMessage.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailFolderSaveMessage.php index 96efcf67f95d6eac0313227755074b3bc7650fe0..3dbdc67069c21762708a9993ad5ba15bf11173dd 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailFolderSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailFolderSaveMessage.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapFailFolderSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailPathSaveMessage.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailPathSaveMessage.php index 75aadae7fedbb54b86d13fd2824bd60895479905..62beed7801a351d75444924ae31427bd3d3c0220 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailPathSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapFailPathSaveMessage.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapFailPathSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapInGrid.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapInGrid.php index c39dfeb0baaa7e87cb07b777140e0f7446f3a62b..4e0ed7081b8057e1bb962f42da8ca958199d8783 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapInGrid diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapNotInGrid.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapNotInGrid.php index 8aa3253d7695e90adf2163a7670ad737877c7532..3b9c67aba378594a4b5b947126e290ba99758b3b 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessDeleteMessage.php index d3665d2124bb871ff4d42eecd8d38cd0cbe20874..ea5001caa1f668c7b7fff3b708e23c01289ca166 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessGenerateMessage.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessGenerateMessage.php index c9939c74e8dff6cd2196f7f4e47c97f87d003c71..77e58ce48e148638de09e08d987d87efd097bc31 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessGenerateMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessGenerateMessage.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapSuccessGenerateMessage diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveAndGenerateMessages.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveAndGenerateMessages.php index cd540c0045e28aa071ac5c14aa98e34e37b6183f..4cd76f6839c316cb1fb479366769c9699aeda828 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveAndGenerateMessages.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveAndGenerateMessages.php @@ -8,7 +8,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapSuccessSaveAndGenerateMessages diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveMessage.php index 0d78b7b7b58dfb3cdb5ee8a2737af1a2669f11a0..d2c8eec17934df79d407fca570c30e00cbd1923b 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Constraint/AssertSitemapSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Sitemap\Test\Constraint; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSitemapSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Fixture/Sitemap.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Fixture/Sitemap.php index 2984eaf84361ce08bcbeda0085c89ce125123fa8..d2d40bd3713e8d00dfc5991b7334ecd6559192eb 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Fixture/Sitemap.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Fixture/Sitemap.php @@ -6,7 +6,7 @@ namespace Magento\Sitemap\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Sitemap diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/Curl.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/Curl.php index 839745e0da0cd241cee6bea9b19fe9681b3cf4cc..103986e35d013561db85c4097663eeceb90f4fd7 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/Curl.php @@ -8,12 +8,12 @@ namespace Magento\Sitemap\Test\Handler\Sitemap; use Magento\Backend\Test\Handler\Extractor; use Magento\Sitemap\Test\Handler\Sitemap; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/SitemapInterface.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/SitemapInterface.php index 87c9938c46f66bdcd10f1f29c0040d5895355652..97246710c6ee357ced2f91b3dd19f74f2b3c9443 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/SitemapInterface.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Handler/Sitemap/SitemapInterface.php @@ -6,7 +6,7 @@ namespace Magento\Sitemap\Test\Handler\Sitemap; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface SitemapInterface diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Repository/Sitemap.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Repository/Sitemap.php index 80077b4fead7f813ee2064d55e4dc015d1a72ecf..a2f28611e98efef01be6be312eacd5ea029ce699 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/Repository/Sitemap.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/Repository/Sitemap.php @@ -6,7 +6,7 @@ namespace Magento\Sitemap\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Sitemap diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/CreateSitemapEntityTest.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/CreateSitemapEntityTest.php index 0f0ffb725bfa08fb5a1c9d745a45bcc74852f3b4..9a6cec214f08147a37c1932359b65e8ec1a7f7d4 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/CreateSitemapEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/CreateSitemapEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Sitemap\Test\TestCase; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; use Magento\Sitemap\Test\Page\Adminhtml\SitemapNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Cover creating SitemapEntity diff --git a/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/DeleteSitemapEntityTest.php b/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/DeleteSitemapEntityTest.php index b2532e34c27e289af1ef23dfab7e96af808ba4f3..56371fb69ad3d0420eaade513e0efd1594a34b0a 100644 --- a/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/DeleteSitemapEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Sitemap/Test/TestCase/DeleteSitemapEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Sitemap\Test\TestCase; use Magento\Sitemap\Test\Fixture\Sitemap; use Magento\Sitemap\Test\Page\Adminhtml\SitemapEdit; use Magento\Sitemap\Test\Page\Adminhtml\SitemapIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Cover deleting Sitemap Entity diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Block/Switcher.php b/dev/tests/functional/tests/app/Magento/Store/Test/Block/Switcher.php index ae64c8dbf0a3f24f765413671748a11a54ad8334..5883250551f492346b34c53a1ed856809f5570f2 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Block/Switcher.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Block/Switcher.php @@ -8,8 +8,8 @@ namespace Magento\Store\Test\Block; use Magento\Store\Test\Fixture\Store; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Switcher diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreBackend.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreBackend.php index b23de9b65c68d7e22d90eea4b110f11f36e6b06e..feb77c84296540d05cadad89066a7c5186f20e93 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreBackend.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreBackend.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\SystemConfig; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreBackend diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreForm.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreForm.php index 07ab89295c4282e80d90685f92491fad472fcd6a..be32892ca3d349564ded7e385818b0a8ae8d57b9 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreForm.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreForm.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backend\Test\Page\Adminhtml\StoreNew; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertStoreForm diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreFrontend.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreFrontend.php index 1c3fba6f7b4bbb2bfaa2713bc6d6f10d8f8b7b9d..3691c6d21e194664cfbb101b6faba9e7f67354ed 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreFrontend.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreFrontend diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupForm.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupForm.php index 969adc59fa1de2a9aa6bef6403472e1599e6c950..59c77b4e2beff68d95c9a2f91fe5ad6b335b6988 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupForm.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupForm.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\EditGroup; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertStoreGroupForm diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupInGrid.php index d402b84f8a7fdce5235b933e04ce880885eb9c02..51e0cd19cf59e0297792a23414873f6beb5c7a2b 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupNotInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupNotInGrid.php index 1e7a5cbc7d066a2a59950aab4f4f47aeb32944eb..c17267d296e1d9f42d2697a178938fd34ccb2fb0 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupOnStoreViewForm.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupOnStoreViewForm.php index d82b5c9636ec77d8b82e20bbb448ff7db3740505..e36072fade0cb7de8ad7ff6152c5c015612324c8 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupOnStoreViewForm.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupOnStoreViewForm.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backend\Test\Page\Adminhtml\StoreNew; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupOnStoreViewForm diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteAndBackupMessages.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteAndBackupMessages.php index 2dd989863208ad310f1f874930e80b1576483fb6..b68b514a232c47cc2f2cda3412e3be2277fb7b61 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteAndBackupMessages.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteAndBackupMessages.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupSuccessDeleteAndBackupMessages diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteMessage.php index 899edb2064a14c4c9e64cddb7ba22e474f9e2f7d..b69285e49ba7cc0dfa9204001a4c99d4db2ce366 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessSaveMessage.php index 73cf65fd967efa2bfa5d114c5c281a14a66bca53..1f78d946c067ecffe2800bdf5e2f51a926ca7a9e 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreGroupSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreGroupSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreInGrid.php index f1532c19a5d1787d879faac40c468340b99a6b6b..b5078cc68bb9597d55575ba29435ee050c95ba40 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotInGrid.php index 8868f0e5a2f66628121b6a23d79452c194b2d95b..a83a6a1954c6dc00e6c723e2d5a10e0b0c603e6d 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotOnFrontend.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotOnFrontend.php index df68a3e6765d6ac23766d7203aca7c2dd5bbeafb..ab89a1a07bfca3f420014d9cbb0ed58627a8e59c 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotOnFrontend.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreNotOnFrontend.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreNotOnFrontend diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteAndBackupMessages.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteAndBackupMessages.php index 4301b9f84ad757d75c2599a64be9f28a9c297939..c91f10875d00783314fd0a46c43791893c867ba9 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteAndBackupMessages.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteAndBackupMessages.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreSuccessDeleteAndBackupMessages diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteMessage.php index 69f628c67bac3ce0a40cacfb597287b2bf056cbc..4f5f9edf2136fe1969c253dead321a5ca28d612b 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessSaveMessage.php index 5ab2242d983675198874ca598d626260c63a3c7b..9d12f21870842d6a467dfc9a3f462f8d54b6e48b 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertStoreSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertStoreSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteForm.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteForm.php index c3f541646f3d2ac9de957d38594fa198e23b882d..757658db8bfe6bc29ccfaf2e75a5d84abe706151 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteForm.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteForm.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\EditWebsite; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Constraint\AbstractAssertForm; /** * Class AssertWebsiteForm diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteInGrid.php index 157d0630bc07527cbc8c69f7dcc4bca85d905d2a..0656425f75ed92b3becb16e68b3782a935d21fb7 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteNotInGrid.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteNotInGrid.php index 721b12c5b91560ee0f9d08d0e8b561374c7b77be..9c5dd627e30f893c335cfd9e2a1208f80126365d 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteOnStoreForm.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteOnStoreForm.php index 8db25588f26482254c9f51fcaa3a89daaee35682..c7d76580c265beef4ca796aea466ab0a2f89e7c9 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteOnStoreForm.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteOnStoreForm.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\NewGroupIndex; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteOnStoreForm diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteAndBackupMessages.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteAndBackupMessages.php index 5e925097b06bfc4a0289694e32d703eef707b1af..eee0dd61344acd072e19ea60d1672f941e1775ed 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteAndBackupMessages.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteAndBackupMessages.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteSuccessDeleteAndBackupMessages diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteMessage.php index 8f8dd74ea799c946d20ba02a548c31a793a6c9e0..c0e0f791c683db52889dbf626a6928988ab2f9e4 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessSaveMessage.php index eb1f08c36405515d4e53010708632cfc9cfad6af..11bc68e2fc241c23232167ae341b7eefe938c3af 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Constraint/AssertWebsiteSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Store\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWebsiteSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store.php index 081711218f0b41dd88f02076e6345529a578cb79..5762f119fe32eebea29cd55972b7a43231965782 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Store diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store/GroupId.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store/GroupId.php index da70439f612af89b907c0f9845cd9bf9561ec72b..9ec18c42b26f24c545930874d1c8bee6f100469c 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store/GroupId.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Store/GroupId.php @@ -7,8 +7,8 @@ namespace Magento\Store\Test\Fixture\Store; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class GroupId diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup.php index b19288b37e0ccb4317187f80e8a1a8dcb2ea4575..04dd14411c319574f10750eda3864102cf71de4e 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class StoreGroup diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/CategoryId.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/CategoryId.php index 7b3c07070f1630b8de7fbf9b0c6708763cfa7220..ca4f11663f342c31e17e4a34188a980fd3c6cb59 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/CategoryId.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/CategoryId.php @@ -7,8 +7,8 @@ namespace Magento\Store\Test\Fixture\StoreGroup; use Magento\Catalog\Test\Fixture\Category; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class CategoryId diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/WebsiteId.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/WebsiteId.php index 47d8dabac75852500abcf3c2c94dbb7e060a67bf..36e20106ce00ee2eec6ab81e5d5150a5df11d2ae 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/WebsiteId.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/StoreGroup/WebsiteId.php @@ -7,8 +7,8 @@ namespace Magento\Store\Test\Fixture\StoreGroup; use Magento\Store\Test\Fixture\Website; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class WebsiteId diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Website.php b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Website.php index 0dc41b477a6a5789e34381b5a01deae62a758b9c..c680e52135caffa8deac2f3776a66da2d44a7b96 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Website.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Fixture/Website.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class Website diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/Curl.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/Curl.php index 421b937acd41bb6ba6af6f8a1873ea1f0faec858..7e21102b92fa77317a00c6675f4f5dd9cf5505d8 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Store\Test\Handler\Store; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/StoreInterface.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/StoreInterface.php index 034b22d0ba952209e79d3aeddb2b06ae392f2c1d..87670c64cc8e0f98999594770c83d6a0090405f7 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/StoreInterface.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Store/StoreInterface.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Handler\Store; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface StoreInterface diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/Curl.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/Curl.php index 3aa9a6ce92009119dd1498895fa7848110f6c13a..2b0c1abbdde4f47a3eabc7ead74ba06cf2d6bfcd 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Store\Test\Handler\StoreGroup; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/StoreGroupInterface.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/StoreGroupInterface.php index 6b57419e518bf3ce727daf2b8e2e45a1959f7268..9af46f18ae9988ffd6168e13ee75bf13a7cc8b78 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/StoreGroupInterface.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/StoreGroup/StoreGroupInterface.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Handler\StoreGroup; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface StoreGroupInterface diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/Curl.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/Curl.php index 671d46f4a8d5d7448bd100b5fa1c90cdfa79b51f..9eb58a1be2668ea40c9b458edb3224316baa5c12 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Store\Test\Handler\Website; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/WebsiteInterface.php b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/WebsiteInterface.php index c3f167b26d4e3f1642d488cda004147e1712186b..2f808d7607779aebffa6e31c2acbe9fc8e2cc4cb 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/WebsiteInterface.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Handler/Website/WebsiteInterface.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Handler\Website; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface WebsiteInterface diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Store.php b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Store.php index b839bb08082e958aaf00ef0e9cd51b8ca6725624..472aa3028cb23a8dd1a3c00195cf5f29796060ab 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Store.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Store.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Store diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/StoreGroup.php b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/StoreGroup.php index a51aaba9dafee4277fd4fbe748cf95e37edd9d1f..fa01d8b222c6137d215e6cb9f1f8b054a2b0d947 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/StoreGroup.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/StoreGroup.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class StoreGroup diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Website.php b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Website.php index 97cef07a17e393072f3125f4044ba108cf2b9a48..7e0fce6fd06b01fee591cd7396c87a53e61c7618 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Website.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/Repository/Website.php @@ -6,7 +6,7 @@ namespace Magento\Store\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Website diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreEntityTest.php index 599af73acabf8162df97892d90bbe2d1c9286580..3e796d62655d43403e8ed8ecf069def881c6b1a2 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backend\Test\Page\Adminhtml\StoreNew; use Magento\Store\Test\Fixture\Store; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateStoreEntity (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreGroupEntityTest.php index 1e6bd58ef9e73794fa2c85b2d53ce9bf3e3f0bb1..6edc800dfeabbb9e096f7da9ea24772aa78bdec3 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateStoreGroupEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\NewGroupIndex; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Create New StoreGroup (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateWebsiteEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateWebsiteEntityTest.php index 3a38433e0894e81cd2b90677316e930b4d9a3234..59b40358b13031b2d20ddbdd5b4ee0115136ed17 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateWebsiteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/CreateWebsiteEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\NewWebsiteIndex; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Create Website (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.php index 27a058334a5dd8e03c26c39f92aae1b59816fa10..debf3cb6b6ea0e48cfd7c35629d4daee1b899eec 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreEntityTest.php @@ -11,7 +11,7 @@ use Magento\Backend\Test\Page\Adminhtml\StoreDelete; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backup\Test\Page\Adminhtml\BackupIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteStoreEntity diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.php index b6eab430a1f81773f6e09fd32b8f93819ceb1f00..94f044c26e0c3ab00ed1a7298e0cce5acafc2d2b 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteStoreGroupEntityTest.php @@ -11,7 +11,7 @@ use Magento\Backend\Test\Page\Adminhtml\EditGroup; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backup\Test\Page\Adminhtml\BackupIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Delete StoreGroup (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php index 0fc93a94ef473d3013831c12e8d86b154f2c4eb5..b540e04277f11e19a2e9e57b227994572384ff85 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/DeleteWebsiteEntityTest.php @@ -11,7 +11,7 @@ use Magento\Backend\Test\Page\Adminhtml\EditWebsite; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Backup\Test\Page\Adminhtml\BackupIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Delete Website (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/StoreTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/StoreTest.php index 5f316bdd79356ce86185d09f672e19e91a6b58f3..ab189ce353019e5e821f66713b8491f63bb87aaf 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/StoreTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/StoreTest.php @@ -8,8 +8,8 @@ namespace Magento\Store\Test\TestCase; -use Mtf\Factory\Factory; -use Mtf\TestCase\Functional; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\TestCase\Functional; class StoreTest extends Functional { diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreEntityTest.php index 9ac015f936d6beaf8ed2f6eb31c014a5d254f97c..9ead46a3f63cd8d26551fe3e7e851d3af779bcc8 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\EditStore; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Store; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateStoreEntity (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreGroupEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreGroupEntityTest.php index 555e6a7a054bf63144f59f2bc40f9434b5bb0409..5ec7ac7473b68fdb031ac71f273bdf63b2a98ae6 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreGroupEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateStoreGroupEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\EditGroup; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\StoreGroup; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Update StoreGroup (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateWebsiteEntityTest.php b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateWebsiteEntityTest.php index 7feb6fa8811c789e85e37bf4a08d41a29554c113..d1760123b0aef7c6bac03e8c20158b1a635f50ae 100644 --- a/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateWebsiteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Store/Test/TestCase/UpdateWebsiteEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\Store\Test\TestCase; use Magento\Backend\Test\Page\Adminhtml\EditWebsite; use Magento\Backend\Test\Page\Adminhtml\StoreIndex; use Magento\Store\Test\Fixture\Website; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Update Website (Store Management) diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rate/Edit/Form.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rate/Edit/Form.php index 8dfbf12c72c0fe3154359565c897033002102266..e488aa8dc201dfca4378e2c6cba362f4296f05ac 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rate/Edit/Form.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rate/Edit/Form.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Block\Adminhtml\Rate\Edit; -use Mtf\Block\Form as ParentForm; +use Magento\Mtf\Block\Form as ParentForm; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/Form.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/Form.php index 380fb956a24e63200a4bca27877d5d125e90d24d..41e9135fcad075d3f78cca15ece858e284c6e160 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/Form.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/Form.php @@ -6,11 +6,11 @@ namespace Magento\Tax\Test\Block\Adminhtml\Rule\Edit; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; use Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Block\Form as FormInterface; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Block\Form as FormInterface; /** * Form for tax rule creation. @@ -112,12 +112,12 @@ class Form extends FormInterface * Fill the root form. * * @param FixtureInterface $fixture - * @param Element $element + * @param SimpleElement $element * @return $this|void * * @SuppressWarnings(PHPMD.UnusedFormalParameter) */ - public function fill(FixtureInterface $fixture, Element $element = null) + public function fill(FixtureInterface $fixture, SimpleElement $element = null) { $this->openAdditionalSettings(); $this->_rootElement->click(); @@ -162,14 +162,12 @@ class Form extends FormInterface $taxRateDefaultMultiSelect = $this->taxRateDefaultMultiSelect; $this->browser->waitUntil( function () use ($rootForm, $taxRateDefaultMultiSelect) { - $rootForm->reinitRootElement(); $element = $rootForm->browser->find($taxRateDefaultMultiSelect); return $element->isVisible() ? null : true; } ); $this->browser->waitUntil( function () use ($rootForm, $taxRateMultiSelectList) { - $rootForm->reinitRootElement(); $element = $rootForm->browser->find($taxRateMultiSelectList); return $element->isVisible() ? true : null; } @@ -206,10 +204,10 @@ class Form extends FormInterface * Method to add new tax classes. * * @param array $taxClasses - * @param Element $element + * @param SimpleElement $element * @return void */ - protected function addNewTaxClass(array $taxClasses, Element $element) + protected function addNewTaxClass(array $taxClasses, SimpleElement $element) { foreach ($taxClasses as $taxClass) { $option = $element->find(sprintf($this->optionMaskElement, $taxClass), Locator::SELECTOR_XPATH); @@ -232,7 +230,7 @@ class Form extends FormInterface /** * Waiting until option in list is visible. * - * @param Element $element + * @param SimpleElement $element * @param string $value * @return void */ @@ -278,18 +276,19 @@ class Form extends FormInterface return $element->isVisible() ? true : null; } ); - /** @var \Mtf\Client\Driver\Selenium\Element\MultiselectlistElement $taxRates */ + /** @var \Magento\Mtf\Client\Element\MultiselectlistElement $taxRates */ $taxRates = $this->_rootElement->find($this->taxRateBlock, Locator::SELECTOR_CSS, 'multiselectlist'); + return $taxRates->getAllValues(); } /** * Click 'Add New' button. * - * @param Element $element + * @param SimpleElement $element * @return void */ - protected function clickAddNewButton(Element $element) + protected function clickAddNewButton(SimpleElement $element) { $addNewButton = $this->addNewButton; $element->waitUntil( diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/TaxRate.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/TaxRate.php index ea3b07e2e79f334116d04353c3a11294a5c0bf4f..30ee53017146c24b9afebd9546848862a80fa03b 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/TaxRate.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Edit/TaxRate.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Block\Adminhtml\Rule\Edit; -use Mtf\Block\Form as FormInterface; +use Magento\Mtf\Block\Form as FormInterface; /** * Class TaxRate diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Grid.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Grid.php index db8dcd100c2b468e87e3ba07945c09d175e5bfe7..8923aa8d311fb4bcc3d01eff43c783aeab449bcc 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Block/Adminhtml/Rule/Grid.php @@ -7,7 +7,6 @@ namespace Magento\Tax\Test\Block\Adminhtml\Rule; use Magento\Backend\Test\Block\Widget\Grid as GridInterface; -use Mtf\Client\Element\Locator; /** * Class Grid diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertOrderTaxOnBackend.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertOrderTaxOnBackend.php new file mode 100644 index 0000000000000000000000000000000000000000..aa63949e9de9dc7777e015e4cb5b76a6febe3305 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertOrderTaxOnBackend.php @@ -0,0 +1,231 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +use Mtf\Constraint\AbstractConstraint; +use Magento\Sales\Test\Page\Adminhtml\OrderView; +use Magento\Sales\Test\Page\Adminhtml\OrderIndex; +use Magento\Sales\Test\Page\Adminhtml\OrderInvoiceNew; +use Magento\Sales\Test\Page\Adminhtml\OrderCreditMemoNew; +use Mtf\Fixture\InjectableFixture; + +/** + * Checks that prices displayed excluding tax in order are correct on backend. + */ +abstract class AbstractAssertOrderTaxOnBackend extends AbstractConstraint +{ + /** + * Order View Page. + * + * @var OrderView + */ + protected $orderView; + + /** + * Order View Page. + * + * @var OrderInvoiceNew + */ + protected $orderInvoiceNew; + + /** + * Order View Page. + * + * @var OrderCreditMemoNew + */ + protected $orderCreditMemoNew; + + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Implementation for get order total prices function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getOrderTotals($actualPrices); + + /** + * Implementation for get invoice creation page total prices function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getInvoiceNewTotals($actualPrices); + + /** + * Implementation for get credit memo creation page total prices function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getCreditMemoNewTotals($actualPrices); + + /** + * Assert that specified prices are actual on order, invoice and refund pages. + * + * @param array $prices + * @param InjectableFixture $product + * @param OrderIndex $orderIndex + * @param OrderView $orderView + * @param OrderInvoiceNew $orderInvoiceNew + * @param OrderCreditMemoNew $orderCreditMemoNew + * @return void + */ + public function processAssert( + array $prices, + InjectableFixture $product, + OrderIndex $orderIndex, + OrderView $orderView, + OrderInvoiceNew $orderInvoiceNew, + OrderCreditMemoNew $orderCreditMemoNew + ) { + $this->orderView = $orderView; + $this->orderInvoiceNew = $orderInvoiceNew; + $this->orderCreditMemoNew = $orderCreditMemoNew; + $orderIndex->open(); + $orderIndex->getSalesOrderGrid()->openFirstRow(); + //Check prices on order page + $actualPrices = []; + $actualPrices = $this->getOrderPrices($actualPrices, $product); + $actualPrices = $this->getOrderTotals($actualPrices); + $prices = $this->preparePrices($prices); + $message = 'Prices on order view page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + $orderView->getPageActions()->invoice(); + //Check prices on invoice creation page + $actualPrices = []; + $actualPrices = $this->getInvoiceNewPrices($actualPrices, $product); + $actualPrices = $this->getInvoiceNewTotals($actualPrices); + $message = 'Prices on invoice new page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + $orderInvoiceNew->getTotalsBlock()->submit(); + //Check prices after invoice on order page + $actualPrices = []; + $actualPrices = $this->getOrderPrices($actualPrices, $product); + $actualPrices = $this->getOrderTotals($actualPrices); + $message = 'Prices on invoice page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + $orderView->getPageActions()->orderCreditMemo(); + //Check prices on credit memo creation page + $pricesCreditMemo = $this->preparePricesCreditMemo($prices); + $actualPrices = []; + $actualPrices = $this->getCreditMemoNewPrices($actualPrices, $product); + $actualPrices = $this->getCreditMemoNewTotals($actualPrices); + $message = 'Prices on credit memo new page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($pricesCreditMemo, $actualPrices, $message); + $orderCreditMemoNew->getFormBlock()->submit(); + //Check prices after refund on order page + $actualPrices = []; + $actualPrices = $this->getOrderPrices($actualPrices, $product); + $actualPrices = $this->getOrderTotals($actualPrices); + $message = 'Prices on credit memo page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + } + + /** + * Unset category and product page expected prices. + * + * @param array $prices + * @return array + */ + protected function preparePrices($prices) + { + $deletePrices = [ + 'category_price_excl_tax', + 'category_price_incl_tax', + 'product_view_price_excl_tax', + 'product_view_price_incl_tax' + ]; + foreach ($deletePrices as $key) { + if (array_key_exists($key, $prices)) { + unset($prices[$key]); + } + } + + return $prices; + } + + /** + * Unset category and product page expected prices. + * + * @param array $prices + * @return array + */ + protected function preparePricesCreditMemo($prices) + { + $prices['shipping_excl_tax'] = null; + $prices['shipping_incl_tax'] = null; + return $prices; + } + + /** + * Get order product prices. + * + * @param InjectableFixture $product + * @param array $actualPrices + * @return array + */ + public function getOrderPrices($actualPrices, InjectableFixture $product) + { + $viewBlock = $this->orderView->getItemsOrderedBlock(); + $actualPrices['cart_item_price_excl_tax'] = $viewBlock->getItemPriceExclTax($product->getName()); + $actualPrices['cart_item_price_incl_tax'] = $viewBlock->getItemPriceInclTax($product->getName()); + $actualPrices['cart_item_subtotal_excl_tax'] = $viewBlock->getItemSubExclTax($product->getName()); + $actualPrices['cart_item_subtotal_incl_tax'] = $viewBlock->getItemSubInclTax($product->getName()); + return $actualPrices; + } + + /** + * Get invoice new product prices. + * + * @param InjectableFixture $product + * @param array $actualPrices + * @return array + */ + public function getInvoiceNewPrices($actualPrices, InjectableFixture $product) + { + $productBlock = $this->orderInvoiceNew->getFormBlock()->getItemsBlock()->getItemProductBlock($product); + $actualPrices['cart_item_price_excl_tax'] = $productBlock->getItemPriceExclTax(); + $actualPrices['cart_item_price_incl_tax'] = $productBlock->getItemPriceInclTax(); + $actualPrices['cart_item_subtotal_excl_tax'] = $productBlock->getItemSubExclTax(); + $actualPrices['cart_item_subtotal_incl_tax'] = $productBlock->getItemSubInclTax(); + return $actualPrices; + } + + /** + * Get Credit Memo new product prices. + * + * @param InjectableFixture $product + * @param array $actualPrices + * @return array + */ + public function getCreditMemoNewPrices($actualPrices, InjectableFixture $product) + { + $productBlock = $this->orderCreditMemoNew->getFormBlock()->getItemsBlock()->getItemProductBlock($product); + $actualPrices['cart_item_price_excl_tax'] = $productBlock->getItemPriceExclTax(); + $actualPrices['cart_item_price_incl_tax'] = $productBlock->getItemPriceInclTax(); + $actualPrices['cart_item_subtotal_excl_tax'] = $productBlock->getItemSubExclTax(); + $actualPrices['cart_item_subtotal_incl_tax'] = $productBlock->getItemSubInclTax(); + return $actualPrices; + } + + /** + * Text of price verification after order creation. + * + * @return string + */ + public function toString() + { + return 'Prices on backend after order creation is correct.'; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxCalculationAfterCheckout.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxCalculationAfterCheckout.php new file mode 100644 index 0000000000000000000000000000000000000000..debc24c79bb650f9b08ff699c02f4c47d7880835 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxCalculationAfterCheckout.php @@ -0,0 +1,174 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +use Mtf\Constraint\AbstractConstraint; +use Magento\Checkout\Test\Page\CheckoutCart; +use Magento\Checkout\Test\Page\CheckoutOnepage; +use Magento\Checkout\Test\Page\CheckoutOnepageSuccess; +use Magento\Customer\Test\Fixture\CustomerInjectable; +use Magento\Sales\Test\Page\OrderView; +use Mtf\Fixture\InjectableFixture; + +/** + * Checks that prices excluding tax on order review and customer order pages are equal to specified in dataset. + */ +abstract class AbstractAssertTaxCalculationAfterCheckout extends AbstractConstraint +{ + /** + * Checkout page. + * + * @var CheckoutOnepage + */ + protected $checkoutOnepage; + + /** + * Order view page. + * + * @var OrderView + */ + protected $orderView; + + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Implementation for get order review total prices function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getReviewTotals($actualPrices); + + /** + * Implementation for get order total prices from customer account function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getOrderTotals($actualPrices); + + /** + * Assert that prices on order review and customer order pages are equal to specified in dataset. + * + * @param array $prices + * @param InjectableFixture $product + * @param CheckoutCart $checkoutCart + * @param CheckoutOnepage $checkoutOnepage + * @param CheckoutOnepageSuccess $checkoutOnepageSuccess + * @param OrderView $orderView + * @return void + */ + public function processAssert( + array $prices, + InjectableFixture $product, + CheckoutCart $checkoutCart, + CheckoutOnepage $checkoutOnepage, + CheckoutOnepageSuccess $checkoutOnepageSuccess, + OrderView $orderView + ) { + $this->checkoutOnepage = $checkoutOnepage; + $this->orderView = $orderView; + + $checkoutCart->getProceedToCheckoutBlock()->proceedToCheckout(); + $checkoutOnepage->getBillingBlock()->clickContinue(); + $shippingMethod = ['shipping_service' => 'Flat Rate', 'shipping_method' => 'Fixed']; + $checkoutOnepage->getShippingMethodBlock()->selectShippingMethod($shippingMethod); + $checkoutOnepage->getShippingMethodBlock()->clickContinue(); + $checkoutOnepage->getPaymentMethodsBlock()->selectPaymentMethod(['method' => 'check_money_order']); + $checkoutOnepage->getPaymentMethodsBlock()->clickContinue(); + $actualPrices = []; + $actualPrices = $this->getReviewPrices($actualPrices, $product); + $actualPrices = $this->getReviewTotals($actualPrices); + $prices = $this->preparePrices($prices); + //Order review prices verification + $message = 'Prices on order review should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + + $checkoutOnepage->getReviewBlock()->placeOrder(); + $checkoutOnepageSuccess->getSuccessBlock()->getGuestOrderId(); + $checkoutOnepageSuccess->getSuccessBlock()->openOrder(); + $actualPrices = []; + $actualPrices = $this->getOrderPrices($actualPrices, $product); + $actualPrices = $this->getOrderTotals($actualPrices); + + //Frontend order prices verification + $message = 'Prices on order view page should be equal to defined in dataset.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); + } + + /** + * Prepare expected prices prices. + * + * @param array $prices + * @return array $prices + */ + protected function preparePrices($prices) + { + if (isset($prices['category_price_excl_tax'])) { + unset($prices['category_price_excl_tax']); + } + if (isset($prices['category_price_incl_tax'])) { + unset($prices['category_price_incl_tax']); + } + if (isset($prices['product_view_price_excl_tax'])) { + unset($prices['product_view_price_excl_tax']); + } + if (isset($prices['product_view_price_incl_tax'])) { + unset($prices['product_view_price_incl_tax']); + } + return $prices; + } + + /** + * Get review product prices. + * + * @param InjectableFixture $product + * @param $actualPrices + * @return array + */ + public function getReviewPrices($actualPrices, InjectableFixture $product) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['cart_item_price_excl_tax'] = $reviewBlock->getItemPriceExclTax($product->getName()); + $actualPrices['cart_item_price_incl_tax'] = $reviewBlock->getItemPriceInclTax($product->getName()); + $actualPrices['cart_item_subtotal_excl_tax'] = $reviewBlock->getItemSubExclTax($product->getName()); + $actualPrices['cart_item_subtotal_incl_tax'] = $reviewBlock->getItemSubInclTax($product->getName()); + return $actualPrices; + } + + /** + * Get order product prices. + * + * @param InjectableFixture $product + * @param $actualPrices + * @return array + */ + public function getOrderPrices($actualPrices, InjectableFixture $product) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['cart_item_price_excl_tax'] = $viewBlock->getItemPriceExclTax($product->getName()); + $actualPrices['cart_item_price_incl_tax'] = $viewBlock->getItemPriceInclTax($product->getName()); + $actualPrices['cart_item_subtotal_excl_tax'] = $viewBlock->getItemSubExclTax($product->getName()); + $actualPrices['cart_item_subtotal_incl_tax'] = $viewBlock->getItemSubInclTax($product->getName()); + return $actualPrices; + } + + /** + * Text of price verification after order creation + * + * @return string + */ + public function toString() + { + return 'Prices on front after order creation is correct.'; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPrices.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPrices.php similarity index 55% rename from dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPrices.php rename to dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPrices.php index 55704a8de1ebecef5fd4906594e8b4b3b28ed0d1..558a37ed5ba7efae9c850e288e110957f4b7558a 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPrices.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxRuleIsAppliedToAllPrices.php @@ -6,58 +6,86 @@ namespace Magento\Tax\Test\Constraint; -use Magento\Catalog\Test\Fixture\CatalogProductSimple; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Cms\Test\Page\CmsIndex; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; -use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\AddressInjectable; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; /** - * Class AssertTaxRuleIsAppliedToAllPrice - * Checks that prices on category, product and cart pages are equal to specified in dataset + * Checks that prices excl tax on category, product and cart pages are equal to specified in dataset. */ -class AssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint +abstract class AbstractAssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint { - /* tags */ - const SEVERITY = 'high'; - /* end tags */ - /** - * Cms index page + * Cms index page. * * @var CmsIndex */ protected $cmsIndex; /** - * Catalog product page + * Catalog product page. * * @var catalogCategoryView */ protected $catalogCategoryView; /** - * Catalog product page + * Catalog product page. * * @var CatalogProductView */ protected $catalogProductView; /** - * Catalog product page + * Catalog product page. * * @var CheckoutCart */ protected $checkoutCart; /** - * Assert that specified prices are actual on category, product and cart pages + * Constraint severeness. * - * @param CatalogProductSimple $product + * @var string + */ + protected $severeness = 'high'; + + /** + * Implementation for get category prices function + * + * @param string $productName + * @param array $actualPrices + * @return array + */ + abstract protected function getCategoryPrices($productName, $actualPrices); + + /** + * Implementation for get product page prices function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getProductPagePrices($actualPrices); + + /** + * Implementation for get totals in cart function + * + * @param array $actualPrices + * @return array + */ + abstract protected function getTotals($actualPrices); + + /** + * Assert that specified prices are actual on category, product and cart pages. + * + * @param InjectableFixture $product * @param array $prices + * @param int $qty * @param CmsIndex $cmsIndex * @param CatalogCategoryView $catalogCategoryView * @param CatalogProductView $catalogProductView @@ -66,8 +94,9 @@ class AssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint * @return void */ public function processAssert( - CatalogProductSimple $product, + InjectableFixture $product, array $prices, + $qty, CmsIndex $cmsIndex, CatalogCategoryView $catalogCategoryView, CatalogProductView $catalogProductView, @@ -81,98 +110,60 @@ class AssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint //Preconditions $address = $fixtureFactory->createByCode('addressInjectable', ['dataSet' => 'US_address_NY']); $shipping = ['carrier' => 'Flat Rate', 'method' => 'Fixed']; - + $actualPrices = []; //Assertion steps $productName = $product->getName(); - $this->openCategory($product); - $actualPrices = []; + $productCategory = $product->getCategoryIds()[0]; + $this->openCategory($productCategory); $actualPrices = $this->getCategoryPrices($productName, $actualPrices); $catalogCategoryView->getListProductBlock()->openProductViewPage($productName); + $catalogProductView->getViewBlock()->fillOptions($product); $actualPrices = $this->getProductPagePrices($actualPrices); - $catalogProductView->getViewBlock()->setQtyAndClickAddToCart(3); - $actualPrices = $this->getCartPrices($product, $actualPrices); + $catalogProductView->getViewBlock()->setQtyAndClickAddToCart($qty); $this->fillEstimateBlock($address, $shipping); + $actualPrices = $this->getCartPrices($product, $actualPrices); $actualPrices = $this->getTotals($actualPrices); - //Prices verification - \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, 'Arrays should be equal'); + $message = 'Prices from dataset should be equal to prices on frontend.'; + \PHPUnit_Framework_Assert::assertEquals($prices, $actualPrices, $message); } /** - * Open product category + * Open product category. * - * @param CatalogProductSimple $product + * @param string $productCategory * @return void */ - public function openCategory(CatalogProductSimple $product) + public function openCategory($productCategory) { $this->cmsIndex->open(); - $this->cmsIndex->getTopmenu()->selectCategoryByName($product->getCategoryIds()[0]); - } - - /** - * Get prices on category page - * - * @param $productName - * @param array $actualPrices - * @return array - */ - public function getCategoryPrices($productName, $actualPrices) - { - $actualPrices['category_price_excl_tax'] = - $this->catalogCategoryView - ->getListProductBlock() - ->getProductPriceBlock($productName) - ->getPriceExcludingTax(); - $actualPrices['category_price_incl_tax'] = - $this->catalogCategoryView - ->getListProductBlock() - ->getProductPriceBlock($productName) - ->getPriceIncludingTax(); - return $actualPrices; + $this->cmsIndex->getTopmenu()->selectCategoryByName($productCategory); } - /** - * Get product view prices - * - * @param $actualPrices - * @return array - */ - public function getProductPagePrices($actualPrices) - { - $actualPrices['product_view_price_excl_tax'] = - $this->catalogProductView - ->getViewBlock() - ->getProductPriceExcludingTax(); - $actualPrices['product_view_price_incl_tax'] = - $this->catalogProductView - ->getViewBlock() - ->getProductPriceIncludingTax(); - return $actualPrices; - } /** - * Get cart prices + * Get cart prices. * - * @param CatalogProductSimple $product + * @param InjectableFixture $product * @param $actualPrices * @return array */ - public function getCartPrices(CatalogProductSimple $product, $actualPrices) + public function getCartPrices(InjectableFixture $product, $actualPrices) { - $actualPrices['cart_item_subtotal_excl_tax'] = - $this->checkoutCart->getCartBlock()->getCartItem($product)->getSubtotalPrice(); - $actualPrices['cart_item_subtotal_incl_tax'] = - $this->checkoutCart->getCartBlock()->getCartItem($product)->getSubtotalPriceInclTax(); $actualPrices['cart_item_price_excl_tax'] = $this->checkoutCart->getCartBlock()->getCartItem($product)->getPrice(); $actualPrices['cart_item_price_incl_tax'] = $this->checkoutCart->getCartBlock()->getCartItem($product)->getPriceInclTax(); + $actualPrices['cart_item_subtotal_excl_tax'] = + $this->checkoutCart->getCartBlock()->getCartItem($product)->getSubtotalPrice(); + $actualPrices['cart_item_subtotal_incl_tax'] = + $this->checkoutCart->getCartBlock()->getCartItem($product)->getSubtotalPriceInclTax(); + return $actualPrices; } /** - * Fill estimate block + * Fill estimate block. * * @param AddressInjectable $address * @param array $shipping @@ -184,27 +175,6 @@ class AssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint $this->checkoutCart->getShippingBlock()->selectShippingMethod($shipping); } - /** - * Get totals - * - * @param $actualPrices - * @return array - */ - public function getTotals($actualPrices) - { - $actualPrices['subtotal_excl_tax'] = $this->checkoutCart->getTotalsBlock()->getSubtotalExcludingTax(); - $actualPrices['subtotal_incl_tax'] = $this->checkoutCart->getTotalsBlock()->getSubtotalIncludingTax(); - $actualPrices['discount'] = $this->checkoutCart->getTotalsBlock()->getDiscount(); - $actualPrices['shipping_excl_tax'] = $this->checkoutCart->getTotalsBlock()->getShippingPrice(); - $actualPrices['shipping_incl_tax'] = $this->checkoutCart->getTotalsBlock()->getShippingPriceInclTax(); - $actualPrices['tax'] = $this->checkoutCart->getTotalsBlock()->getTax(); - $actualPrices['grand_total_excl_tax'] = - $this->checkoutCart->getTotalsBlock()->getGrandTotalExcludingTax(); - $actualPrices['grand_total_incl_tax'] = - $this->checkoutCart->getTotalsBlock()->getGrandTotalIncludingTax(); - return $actualPrices; - } - /** * Text of Tax Rule is applied * @@ -212,6 +182,6 @@ class AssertTaxRuleIsAppliedToAllPrices extends AbstractConstraint */ public function toString() { - return 'Prices on front is correct'; + return 'Prices on front is correct.'; } } diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxWithCrossBorderApplying.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxWithCrossBorderApplying.php index 03aeedefc594d176eba9a4a767dfb3326dfd1b70..b249079cbac7799d5bf815a874eccd53691cbd1e 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxWithCrossBorderApplying.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AbstractAssertTaxWithCrossBorderApplying.php @@ -11,7 +11,7 @@ use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Checkout\Test\Page\CheckoutCart; use Magento\Cms\Test\Page\CmsIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AbstractAssertTaxWithCrossBorderApplying @@ -167,7 +167,7 @@ abstract class AbstractAssertTaxWithCrossBorderApplying extends AbstractConstrai $actualPrices['cart_item_subtotal_incl_tax'] = $this->checkoutCart->getCartBlock()->getCartItem($product)->getSubtotalPriceInclTax(); $actualPrices['grand_total'] = - $this->checkoutCart->getTotalsBlock()->getGrandTotal(); + $this->checkoutCart->getTotalsBlock()->getGrandTotalIncludingTax(); return $actualPrices; } diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..1851caffdb0c7b1138beacc2731ac48463e8f4e3 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingIncludingTax.php @@ -0,0 +1,90 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices displayed excluding and including tax in order are correct on backend. + */ +class AssertOrderTaxOnBackendExcludingIncludingTax extends AbstractAssertOrderTaxOnBackend +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get order totals. + * + * @param array $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotalInclTax(); + + $actualPrices['discount'] = $viewBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get invoice new totals. + * + * @param array $actualPrices + * @return array + */ + public function getInvoiceNewTotals($actualPrices) + { + $totalsBlock = $this->orderInvoiceNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotalInclTax(); + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get Credit Memo new totals. + * + * @param array $actualPrices + * @return array + */ + public function getCreditMemoNewTotals($actualPrices) + { + $totalsBlock = $this->orderCreditMemoNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotalInclTax(); + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..9b0c4846f271151fd7fbee879f6ad00f7041341a --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendExcludingTax.php @@ -0,0 +1,92 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices including tax in order are correct on backend. + */ +class AssertOrderTaxOnBackendExcludingTax extends AbstractAssertOrderTaxOnBackend +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + + $actualPrices['discount'] = $viewBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + return $actualPrices; + } + + /** + * Get invoice new totals. + * + * @param $actualPrices + * @return array + */ + public function getInvoiceNewTotals($actualPrices) + { + $totalsBlock = $this->orderInvoiceNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get Credit Memo new totals. + * + * @param $actualPrices + * @return array + */ + public function getCreditMemoNewTotals($actualPrices) + { + $totalsBlock = $this->orderCreditMemoNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..8843f04669a884132ff8e07a6c6ca98913ef57cd --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertOrderTaxOnBackendIncludingTax.php @@ -0,0 +1,90 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices including tax in order are correct on backend. + */ +class AssertOrderTaxOnBackendIncludingTax extends AbstractAssertOrderTaxOnBackend +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotal(); + + $actualPrices['discount'] = $viewBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get invoice new totals. + * + * @param $actualPrices + * @return array + */ + public function getInvoiceNewTotals($actualPrices) + { + $totalsBlock = $this->orderInvoiceNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotal(); + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get Credit Memo new totals. + * + * @param $actualPrices + * @return array + */ + public function getCreditMemoNewTotals($actualPrices) + { + $totalsBlock = $this->orderCreditMemoNew->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotal(); + + $actualPrices['discount'] = $totalsBlock->getDiscount(); + + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..7d65c80e0aee4df44aab43c081850d101835e957 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingIncludingTax.php @@ -0,0 +1,63 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices excl and incl tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutExcludingIncludingTax extends + AbstractAssertTaxCalculationAfterCheckout +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = $reviewBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $reviewBlock->getSubtotalInclTax(); + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $reviewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotalExclTax(); + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotalInclTax(); + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..eecf9cc8c87400dbda9a83ab463e462a920ba97f --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutExcludingTax.php @@ -0,0 +1,62 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices including tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutExcludingTax extends AbstractAssertTaxCalculationAfterCheckout +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = $reviewBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = $viewBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..59869e99eaa92097d16a93000285df72072d4010 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxCalculationAfterCheckoutIncludingTax.php @@ -0,0 +1,62 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +/** + * Checks that prices including tax on order review and customer order pages are equal to specified in dataset. + */ +class AssertTaxCalculationAfterCheckoutIncludingTax extends AbstractAssertTaxCalculationAfterCheckout +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get review totals. + * + * @param $actualPrices + * @return array + */ + public function getReviewTotals($actualPrices) + { + $reviewBlock = $this->checkoutOnepage->getReviewBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $reviewBlock->getSubtotal(); + $actualPrices['discount'] = $reviewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $reviewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $reviewBlock->getShippingInclTax(); + $actualPrices['tax'] = $reviewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $reviewBlock->getGrandTotalExclTax(); + $actualPrices['grand_total_incl_tax'] = $reviewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } + + /** + * Get order totals. + * + * @param $actualPrices + * @return array + */ + public function getOrderTotals($actualPrices) + { + $viewBlock = $this->orderView->getOrderViewBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $viewBlock->getSubtotal(); + $actualPrices['discount'] = $viewBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $viewBlock->getShippingExclTax(); + $actualPrices['shipping_incl_tax'] = $viewBlock->getShippingInclTax(); + $actualPrices['tax'] = $viewBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $viewBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = $viewBlock->getGrandTotalInclTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateForm.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateForm.php index b2cc6ea218b1438aefce9170af80434964f44f6b..9be4aa155fab35d0ddd6a6c8dcb7e75a22358547 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateForm.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateForm.php @@ -9,7 +9,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRateNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateForm diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInGrid.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInGrid.php index ab8fb7c249a9f0f78da2daefb2eac4b2a53eba47..b29f483f1ed231e9de98e9e452d0bfff0a5383eb 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateInGrid diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInTaxRule.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInTaxRule.php index 68698ac0e0ef9a532ff6c0a8ed11d5c918c6a8ac..c7e8b1e65fbededdd60870c5ee14e7c518cf15d9 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInTaxRule.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateInTaxRule.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateInTaxRule diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateIsInCorrectRange.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateIsInCorrectRange.php index 1dee8e8332681b94b2f7df971a2f080e6fba66af..e8b8e96f9c19dc762a8c0db8fcbedf06fcd735d0 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateIsInCorrectRange.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateIsInCorrectRange.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Constraint; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateIsInCorrectRange diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInGrid.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInGrid.php index 6e2b75e92dbfb33ae3322a28f17cd16d5e9611b1..27269fc071aaaafb465e2b344c4e9beab5d03cde 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInTaxRule.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInTaxRule.php index cec93f5e32d9e4a4096f8bad14507027b4f22c47..40a294d79d3b56334fd4451a5629900e4d7ea311 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInTaxRule.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateNotInTaxRule.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateNotInTaxRule diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessDeleteMessage.php index e986b9afc8ad05af30077033c69c38f9059585e2..5a2eeb5608e584a46bf72de31a52ef324e27cd22 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessSaveMessage.php index c463dd61c071cc90b43368cd6755d05bf24562e7..daa156986bba7643d156b9cbfc9bf4fe63a2c330 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRateSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRateSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleApplying.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleApplying.php index 489029400eb8a379b97eeb42ce89974c25b94694..d8000e08d4a2b56392b8efa868b7289dc02ed230 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleApplying.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleApplying.php @@ -14,9 +14,9 @@ use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureFactory; /** * Class AssertTaxRuleApplying @@ -89,7 +89,7 @@ abstract class AssertTaxRuleApplying extends AbstractConstraint * @param CheckoutCart $checkoutCart * @param AddressInjectable $address * @param array $shipping - * @param Browser $browser + * @param BrowserInterface $browser * @param TaxRule $initialTaxRule * @return void * @@ -105,7 +105,7 @@ abstract class AssertTaxRuleApplying extends AbstractConstraint CheckoutCart $checkoutCart, AddressInjectable $address, array $shipping, - Browser $browser, + BrowserInterface $browser, TaxRule $initialTaxRule = null ) { $this->initialTaxRule = $initialTaxRule; diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleForm.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleForm.php index 06364e1cad8d9bd02174de21b7fb5db6dd2973ad..2ec54cbe497a1655d6552569a941c1a1426720ed 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleForm.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleForm.php @@ -9,7 +9,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRuleForm diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleInGrid.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleInGrid.php index 257db7b916a41f314899fa099b7dadd4a10c61e8..fea8557379275bbd4be59814a6f99abbf4b7a2f7 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRuleInGrid diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..b685b18e9608d4e40c42ed24f802d3cb4380892f --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingIncludingTax.php @@ -0,0 +1,75 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +use Magento\Catalog\Test\Fixture\CatalogProductSimple; + +/** + * Checks that prices excl and incl tax on category, product and cart pages are equal to specified in dataset + */ +class AssertTaxRuleIsAppliedToAllPricesExcludingIncludingTax extends + AbstractAssertTaxRuleIsAppliedToAllPrices +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get prices on category page. + * + * @param $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = $priceBlock->getPriceExcludingTax(); + $actualPrices['category_price_incl_tax'] = $priceBlock->getPriceIncludingTax(); + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = $viewBlock->getProductPriceExcludingTax(); + $actualPrices['product_view_price_incl_tax'] = $viewBlock->getProductPriceIncludingTax(); + + return $actualPrices; + } + + /** + * Get totals. + * + * @param $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotalExcludingTax(); + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotalIncludingTax(); + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotalExcludingTax(); + $actualPrices['grand_total_incl_tax'] = $totalsBlock->getGrandTotalIncludingTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..8088fe6e3da3a3154c6ed54a015258b5682e0c29 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesExcludingTax.php @@ -0,0 +1,74 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +use Magento\Catalog\Test\Fixture\CatalogProductSimple; + +/** + * Checks that prices incl tax on category, product and cart pages are equal to specified in dataset. + */ +class AssertTaxRuleIsAppliedToAllPricesExcludingTax extends AbstractAssertTaxRuleIsAppliedToAllPrices +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get prices on category page. + * + * @param $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = $priceBlock->getEffectivePrice(); + $actualPrices['category_price_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = $viewBlock->getPriceBlock()->getEffectivePrice(); + $actualPrices['product_view_price_incl_tax'] = null; + + return $actualPrices; + } + + /** + * Get totals. + * + * @param $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['subtotal_incl_tax'] = null; + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['grand_total_excl_tax'] = $totalsBlock->getGrandTotal(); + $actualPrices['grand_total_incl_tax'] = null; + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesIncludingTax.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesIncludingTax.php new file mode 100644 index 0000000000000000000000000000000000000000..9e7fbe7ef376fa91c137f71c50632362fee00993 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleIsAppliedToAllPricesIncludingTax.php @@ -0,0 +1,74 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\Constraint; + +use Magento\Catalog\Test\Fixture\CatalogProductSimple; + +/** + * Checks that prices incl tax on category, product and cart pages are equal to specified in dataset. + */ +class AssertTaxRuleIsAppliedToAllPricesIncludingTax extends AbstractAssertTaxRuleIsAppliedToAllPrices +{ + /** + * Constraint severeness. + * + * @var string + */ + protected $severeness = 'high'; + + /** + * Get prices on category page. + * + * @param $productName + * @param array $actualPrices + * @return array + */ + public function getCategoryPrices($productName, $actualPrices) + { + $priceBlock = $this->catalogCategoryView->getListProductBlock()->getProductPriceBlock($productName); + $actualPrices['category_price_excl_tax'] = null; + $actualPrices['category_price_incl_tax'] = $priceBlock->getEffectivePrice(); + + return $actualPrices; + } + + /** + * Get product view prices. + * + * @param array $actualPrices + * @return array + */ + public function getProductPagePrices($actualPrices) + { + $viewBlock = $this->catalogProductView->getViewBlock(); + $actualPrices['product_view_price_excl_tax'] = null; + $actualPrices['product_view_price_incl_tax'] = $viewBlock->getPriceBlock()->getEffectivePrice(); + + return $actualPrices; + } + + /** + * Get totals. + * + * @param $actualPrices + * @return array + */ + public function getTotals($actualPrices) + { + $totalsBlock = $this->checkoutCart->getTotalsBlock(); + $actualPrices['subtotal_excl_tax'] = null; + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotal(); + $actualPrices['discount'] = $totalsBlock->getDiscount(); + $actualPrices['shipping_excl_tax'] = $totalsBlock->getShippingPrice(); + $actualPrices['shipping_incl_tax'] = $totalsBlock->getShippingPriceInclTax(); + $actualPrices['tax'] = $totalsBlock->getTax(); + $actualPrices['subtotal_excl_tax'] = $totalsBlock->getSubtotalExcludingTax(); + $actualPrices['subtotal_incl_tax'] = $totalsBlock->getSubtotalIncludingTax(); + + return $actualPrices; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleNotInGrid.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleNotInGrid.php index b7cb74fc33b2a26c9c69658dc54fcbf8618e9a0b..0d5d85d1bcc7656178bc26fbeb66e5b3ce39c742 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRuleNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessDeleteMessage.php index 590f9a435e074517af2c931c0a9fb213c4be693d..6649a25316ed9a7ae5e2f4e2c315a66a1fa5059d 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertTaxRuleSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessSaveMessage.php index 9dec5c65b37ca3a3a03821ac2bff3c4e1bf84933..1507e373dc21f00f56ebf5db4dbbc5b923237fc0 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Constraint/AssertTaxRuleSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\Tax\Test\Constraint; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertSuccessSavedMessageTaxRule diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxClass.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxClass.php index 8f161b790ab2538ddbcc5bb261e1ca5921c2a0ac..1c81488b1fccac907d551f996604d5ea03065bb0 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxClass.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxClass.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class TaxClass diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRate.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRate.php index e61fc1352cfdf314869fc27a0096f9be089038bc..daea91ae3039607aa3668ad3ccf965c97bee7277 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRate.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRate.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class TaxRate diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule.php index e14f3fb7b548e3312ab3f551d092da3b125a05d9..9655754d1fa5b0f36de0970e6bd871fb4df003e0 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class TaxRule diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxClass.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxClass.php index a6c807c364a162821860eb0717421c9f39704c03..997d0600cc759907a4e86346d420b53e61bb3a3c 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxClass.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxClass.php @@ -6,8 +6,8 @@ namespace Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class TaxClass diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxRate.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxRate.php index 0bda05d9e923739c3896175630253d59b2850c15..aacc3a65e7ab91f8292fc0461f9ed0de4b4e826d 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxRate.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Fixture/TaxRule/TaxRate.php @@ -6,8 +6,8 @@ namespace Magento\Tax\Test\Fixture\TaxRule; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class TaxRate diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/Curl/RemoveTaxRule.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/Curl/RemoveTaxRule.php index f55a0fe687dc6ca36e6a7b6fcf23de296f7fe2bb..4493f800006d0809f1601e9b1b2048c459e1e531 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/Curl/RemoveTaxRule.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/Curl/RemoveTaxRule.php @@ -6,12 +6,12 @@ namespace Magento\Tax\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Curl handler remove all tax rules diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/Curl.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/Curl.php index e9cb9e4883d39f2b95db188d39fd0b9ab7ba520d..636a0e8a686ce0c7def5080225913ece8e1bb9de 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Tax\Test\Handler\TaxClass; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/TaxClassInterface.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/TaxClassInterface.php index 21f7342dd3a7bfa32099f449622f9e69b5217df0..499654912d749a8567c08279a9ef38ce06cacddb 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/TaxClassInterface.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxClass/TaxClassInterface.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Handler\TaxClass; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface TaxClassInterface diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/Curl.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/Curl.php index 2c820b1c6df2afc7d63265a4eddbdfc20faa5f21..99287a4979567cd69b66eaf2410902bf8ad02808 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Tax\Test\Handler\TaxRate; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/TaxRateInterface.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/TaxRateInterface.php index 3c39b84398b461a9a7825002db57c3c7be007cb4..470de7e57faf6448e6abb8ecb09870a64e823459 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/TaxRateInterface.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRate/TaxRateInterface.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Handler\TaxRate; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface TaxRateInterface diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/Curl.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/Curl.php index 97f9abc6dbc07bbb892e207d7aed2a62b9219ef9..e14120345ebbc2ead5d4830b2238a8063464dc9c 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/Curl.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/Curl.php @@ -6,12 +6,12 @@ namespace Magento\Tax\Test\Handler\TaxRule; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/TaxRuleInterface.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/TaxRuleInterface.php index b48837992af54c199512457116d047ab15ce6dda..417b74b1cf7478a35e39a362d61df3adb3a2fa5d 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/TaxRuleInterface.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Handler/TaxRule/TaxRuleInterface.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Handler\TaxRule; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface TaxRuleInterface diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxClass.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxClass.php index 6c09d879535fd89c6bbdd277d9d0d891bfb542b6..071b74555d17bf1af67339de8572e3a6b3f4f69b 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxClass.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxClass.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class TaxClass Repository diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRate.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRate.php index 4303c1aaa7da79ce4797e4b9a3d3945c13b52b83..e5a571dc1d582048586c00fa42fe8564418ab4c4 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRate.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRate.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class TaxRate Repository diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRule.php b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRule.php index 7da39b35c7df00e7b755c077900b80a62ea5cb0d..782ec7e2406b96a14ef33dfd30853c671eb69fa2 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRule.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/Repository/TaxRule.php @@ -6,7 +6,7 @@ namespace Magento\Tax\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class TaxRule Repository diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRateEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRateEntityTest.php index 733572d4fe3f4c74ff89eeb25c5c2a7331a250e9..ae00c783d685bb61330e4b1eba2708d3400627ff 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRateEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Tax\Test\TestCase; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRateNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php index 5749a77717345c974ba0c3bc149a06125fb40922..b4faef417a77acaff74c450dc864f3d348cf2d5f 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/CreateTaxRuleEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\Tax\Test\TestCase; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRateEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRateEntityTest.php index fb4cc703df236f9aeb9603a73030371a05966a16..4bbdfbe520493e9ce5e1eafb98f0598a2edf5f06 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRateEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Tax\Test\TestCase; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRateNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRuleEntityTest.php index 1cb87a55275753c1c86fd7b3e05975ff7079c611..aa0fac22b2b436a3036a1879d76fa827df2651ae 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/DeleteTaxRuleEntityTest.php @@ -10,8 +10,8 @@ use Magento\Customer\Test\Fixture\AddressInjectable; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete TaxRuleEntity diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRateEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRateEntityTest.php index bed89060ce1b7443c948dc45ac04a838cbeec04f..c11e2e5ae853f217cd1b8c3c601d7e847db24923 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRateEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRateEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\Tax\Test\TestCase; use Magento\Tax\Test\Fixture\TaxRate; use Magento\Tax\Test\Page\Adminhtml\TaxRateIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRateNew; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.php index 053dd03da67808b04f800f09d43b1b564d36ff2c..8cd7b7abe08bf60ad0dcfb08219bbe612a1e1049 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestCase/UpdateTaxRuleEntityTest.php @@ -9,9 +9,9 @@ namespace Magento\Tax\Test\TestCase; use Magento\Tax\Test\Fixture\TaxRule; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\Fixture\FixtureFactory; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Test Flow: diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/CreateTaxRuleStep.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/CreateTaxRuleStep.php new file mode 100644 index 0000000000000000000000000000000000000000..e90c0be6bc439383e4c016b3b49b611e6e1fac26 --- /dev/null +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/CreateTaxRuleStep.php @@ -0,0 +1,63 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ + +namespace Magento\Tax\Test\TestStep; + +use Mtf\Fixture\FixtureFactory; +use Mtf\TestStep\TestStepInterface; + +/** + * Creating tax rule + */ +class CreateTaxRuleStep implements TestStepInterface +{ + /** + * Tax Rule + * + * @var string + */ + protected $taxRule; + + /** + * Factory for Fixture + * + * @var FixtureFactory + */ + protected $fixtureFactory; + + /** + * Preparing step properties + * + * @constructor + * @param FixtureFactory $fixtureFactory + * @param string $taxRule + */ + public function __construct(FixtureFactory $fixtureFactory, $taxRule) + { + $this->fixtureFactory = $fixtureFactory; + $this->taxRule = $taxRule; + } + + /** + * Create tax rule + * + * @return array + */ + public function run() + { + $result['taxRule'] = null; + if ($this->taxRule != '-') { + $taxRule = $this->fixtureFactory->createByCode( + 'taxRule', + ['dataSet' => $this->taxRule] + ); + $taxRule->persist(); + $result['taxRule'] = $taxRule; + } + + return $result; + } +} diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/DeleteAllTaxRulesStep.php b/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/DeleteAllTaxRulesStep.php index 1fe46431402cfe0b7267d90662d37fe662b12c85..69b0cb8e48754397a8a3d56873fcc721f7e6269a 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/DeleteAllTaxRulesStep.php +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/TestStep/DeleteAllTaxRulesStep.php @@ -8,7 +8,7 @@ namespace Magento\Tax\Test\TestStep; use Magento\Tax\Test\Page\Adminhtml\TaxRuleIndex; use Magento\Tax\Test\Page\Adminhtml\TaxRuleNew; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class DeleteAllTaxRulesStep diff --git a/dev/tests/functional/tests/app/Magento/Tax/Test/etc/constraint.xml b/dev/tests/functional/tests/app/Magento/Tax/Test/etc/constraint.xml index cdc24d17ed0778c62d79ec44e5ab1962c8ea323d..6776506ada7ba3b03d55a9a6a0c7296b2e2568c3 100644 --- a/dev/tests/functional/tests/app/Magento/Tax/Test/etc/constraint.xml +++ b/dev/tests/functional/tests/app/Magento/Tax/Test/etc/constraint.xml @@ -57,6 +57,33 @@ <assertTaxRuleIsApplied module="Magento_Tax"> <severity>high</severity> </assertTaxRuleIsApplied> + <assertTaxRuleIsAppliedToAllPricesExcludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesExcludingTax> + <assertTaxRuleIsAppliedToAllPricesIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesIncludingTax> + <assertTaxRuleIsAppliedToAllPricesExcludingIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxRuleIsAppliedToAllPricesExcludingIncludingTax> + <assertTaxCalculationAfterCheckoutExcludingIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutExcludingIncludingTax> + <assertTaxCalculationAfterCheckoutExcludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutExcludingTax> + <assertTaxCalculationAfterCheckoutIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertTaxCalculationAfterCheckoutIncludingTax> + <assertOrderTaxOnBackendExcludingIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertOrderTaxOnBackendExcludingIncludingTax> + <assertOrderTaxOnBackendIncludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertOrderTaxOnBackendIncludingTax> + <assertOrderTaxOnBackendExcludingTax module="Magento_Tax"> + <severeness>high</severeness> + </assertOrderTaxOnBackendExcludingTax> <assertTaxRuleIsAppliedToAllPrices module="Magento_Tax"> <severity>high</severity> </assertTaxRuleIsAppliedToAllPrices> diff --git a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Footer.php b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Footer.php index 391b1fed24904f74add81180e2f316e1175355a8..f670da230ee3d91d2077f69f5a9f63fdd4198aba 100644 --- a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Footer.php +++ b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Footer.php @@ -7,9 +7,9 @@ namespace Magento\Theme\Test\Block\Html; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; use Magento\Store\Test\Fixture\Store; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; /** * Footer block @@ -56,7 +56,7 @@ class Footer extends Block * Click on link by name * * @param string $linkName - * @return \Mtf\Client\Element + * @return void * @throws \Exception */ public function clickLink($linkName) diff --git a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Title.php b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Title.php index 0bf70a50cb0bc730bcb75cc7ce732db1e6911b6a..2217609ad80bcc7ab161067d31a340235c1ab1c4 100644 --- a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Title.php +++ b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Title.php @@ -7,7 +7,7 @@ namespace Magento\Theme\Test\Block\Html; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Page title block diff --git a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Topmenu.php b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Topmenu.php index 1983b20e3e16ea6617f9729910180ef09e08d33c..0326a8150a647a0a576ab959e10ed4951f85a988 100644 --- a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Topmenu.php +++ b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Html/Topmenu.php @@ -7,8 +7,8 @@ namespace Magento\Theme\Test\Block\Html; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Topmenu diff --git a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Links.php b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Links.php index 54a22cb06c5831b9e056952f5123c73e7abd6128..0fd091a16ce67261109b9868daea06a474f78943 100644 --- a/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Links.php +++ b/dev/tests/functional/tests/app/Magento/Theme/Test/Block/Links.php @@ -7,8 +7,8 @@ namespace Magento\Theme\Test\Block; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Page Top Links block. @@ -79,7 +79,10 @@ class Links extends Block */ public function getLinkUrl($linkTitle) { - return trim($this->_rootElement->find(sprintf($this->link, $linkTitle), Locator::SELECTOR_XPATH)->getUrl()); + $link = $this->_rootElement->find(sprintf($this->link, $linkTitle), Locator::SELECTOR_XPATH) + ->getAttribute('href'); + + return trim($link); } /** diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Category/Tree.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Category/Tree.php index 6afb69641cedca5c947b479f72aa8e4a587d5760..b5e8f775ea0b1b1d54f85b60f23e1e1533769af8 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Category/Tree.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Category/Tree.php @@ -6,8 +6,9 @@ namespace Magento\UrlRewrite\Test\Block\Adminhtml\Catalog\Category; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; + +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; use Magento\Catalog\Test\Fixture\Category; /** diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Edit/UrlRewriteForm.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Edit/UrlRewriteForm.php index 5b6a5c51f9b22f850aeac82dcd81776bda7b91e2..dcae5848887be99e10b707cbebb4c9bb35788b5b 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Edit/UrlRewriteForm.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Catalog/Edit/UrlRewriteForm.php @@ -7,8 +7,9 @@ namespace Magento\UrlRewrite\Test\Block\Adminhtml\Catalog\Edit; use Magento\Backend\Test\Block\Widget\Form; -use Mtf\Client\Element; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Client\Element\SimpleElement; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class UrlRewriteForm @@ -20,13 +21,13 @@ class UrlRewriteForm extends Form * Fill the root form * * @param FixtureInterface $fixture - * @param Element|null $element + * @param SimpleElement|null $element * @param array $replace [optional] * @return $this */ public function fill( FixtureInterface $fixture, - Element $element = null, + SimpleElement $element = null, array $replace = [] ) { $data = $fixture->getData(); diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Selector.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Selector.php index e763fc709d8265ace7428a040a4d4c772aa796be..f46e09fdf49dd903911b37cc04b3bea081d287d6 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Selector.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Block/Adminhtml/Selector.php @@ -7,8 +7,8 @@ namespace Magento\UrlRewrite\Test\Block\Adminhtml; -use Mtf\Block\Block; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; /** * Class Selector diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertPageByUrlRewriteIsNotFound.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertPageByUrlRewriteIsNotFound.php index 5f9a5ff1286045c88e9e300850abb0f1165e7310..389f511e37955ebf024c5dcae6ac9606b54c6fbf 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertPageByUrlRewriteIsNotFound.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertPageByUrlRewriteIsNotFound.php @@ -8,8 +8,8 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertPageByUrlRewriteIsNotFound @@ -29,13 +29,13 @@ class AssertPageByUrlRewriteIsNotFound extends AbstractConstraint /** * Checking the server response 404 page on frontend * - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogProductView $catalogProductView * @param UrlRewrite $productRedirect * @return void */ public function processAssert( - Browser $browser, + BrowserInterface $browser, CatalogProductView $catalogProductView, UrlRewrite $productRedirect ) { diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryInGrid.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryInGrid.php index 1bfbe4ee65e771b93143a694157c358a8108be2c..c1ce42c3f3f7de60b90c26e0dd8058ee44e37d39 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryInGrid.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryInGrid.php @@ -8,7 +8,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteCategoryInGrid diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryNotInGrid.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryNotInGrid.php index 0eb7cfed02dabe6d07d60804932eaa9b51b4bb4d..18184d03e7c76d9154d1f18a7326649e8925a66c 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteCategoryNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryRedirect.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryRedirect.php index ca4aaa0b533d5ad8884f6e3e8f4157e0b10792b2..ea1f0370eef8aeaeca19f4753be11d512e2bbf58 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryRedirect.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCategoryRedirect.php @@ -8,8 +8,8 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Fixture\Category; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteCategoryRedirect @@ -26,13 +26,13 @@ class AssertUrlRewriteCategoryRedirect extends AbstractConstraint * * @param UrlRewrite $urlRewrite * @param Category $category - * @param Browser $browser + * @param BrowserInterface $browser * @return void */ public function processAssert( UrlRewrite $urlRewrite, Category $category, - Browser $browser + BrowserInterface $browser ) { $browser->open($_ENV['app_frontend_url'] . $urlRewrite->getRequestPath()); $url = $urlRewrite->getRedirectType() == 'No' diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomRedirect.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomRedirect.php index 6fd56fcf941150f65dc182b23b8685eec0aa5007..2241c4fe128a81dab71023e57ec0de8bd194a56c 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomRedirect.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomRedirect.php @@ -8,8 +8,8 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteCustomRedirect @@ -25,11 +25,11 @@ class AssertUrlRewriteCustomRedirect extends AbstractConstraint * Assert check URL rewrite custom redirect * * @param UrlRewrite $urlRewrite - * @param Browser $browser + * @param BrowserInterface $browser * @param CmsIndex $cmsIndex * @return void */ - public function processAssert(UrlRewrite $urlRewrite, Browser $browser, CmsIndex $cmsIndex) + public function processAssert(UrlRewrite $urlRewrite, BrowserInterface $browser, CmsIndex $cmsIndex) { $browser->open($_ENV['app_frontend_url'] . $urlRewrite->getRequestPath()); $entity = $urlRewrite->getDataFieldConfig('target_path')['source']->getEntity(); diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomSearchRedirect.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomSearchRedirect.php index d4eb1c137d877d160c4a48fd8c13f466becd75c2..c00e367145d2c3a0a36ea8a0cb0e898b46a4aa13 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomSearchRedirect.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteCustomSearchRedirect.php @@ -8,8 +8,8 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Page\Category\CatalogCategoryView; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteCustomSearchRedirect @@ -26,14 +26,14 @@ class AssertUrlRewriteCustomSearchRedirect extends AbstractConstraint * * @param UrlRewrite $initialRewrite * @param UrlRewrite $urlRewrite - * @param Browser $browser + * @param BrowserInterface $browser * @param CatalogCategoryView $categoryView * @return void */ public function processAssert( UrlRewrite $initialRewrite, UrlRewrite $urlRewrite, - Browser $browser, + BrowserInterface $browser, CatalogCategoryView $categoryView ) { $urlRequestPath = $urlRewrite->hasData('request_path') diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteDeletedMessage.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteDeletedMessage.php index b10cb73dff2eaf9198a9bb33fb9badfc4635f616..6b0d9e838dd021e4ebbded56b24ff7f41120fa81 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteDeletedMessage.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteDeletedMessage.php @@ -7,7 +7,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteDeletedMessage diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteInGrid.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteInGrid.php index 4b346f2be4f40a4ba496feddefe80e212756eed8..8235b95575105435d7a85eeb685b11a1866d0b7c 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteInGrid.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteInGrid.php @@ -8,7 +8,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteInGrid diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteNotInGrid.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteNotInGrid.php index c8b3fbce3185d80200de45661a63022bb7af0940..7f2431c04621a77899cf7564b7981fb92675f06e 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteProductRedirect.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteProductRedirect.php index 0c7e40ba98311cb80b8fe8e9a2e131d1a2e4cf62..720dc2915b97449437e1f1418b0293a57669d6cb 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteProductRedirect.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteProductRedirect.php @@ -8,9 +8,9 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertUrlRewriteProductRedirect @@ -27,14 +27,14 @@ class AssertUrlRewriteProductRedirect extends AbstractConstraint * * @param UrlRewrite $urlRewrite * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param InjectableFixture $product * @return void */ public function processAssert( UrlRewrite $urlRewrite, CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, InjectableFixture $product = null ) { $browser->open($_ENV['app_frontend_url'] . $urlRewrite->getRequestPath()); diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSaveMessage.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSaveMessage.php index ee74a710c227ddd9d092e9fc9d2df189e971c4e3..6507dd11cdf04cc8e45c3511d2c557407bbfa5f9 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSuccessOutsideRedirect.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSuccessOutsideRedirect.php index 62006f617930ae4c110a44ea3e839bde35c7500e..60d1fdfc8fa188e92aae03a48fe8fa1e685c970e 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSuccessOutsideRedirect.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteSuccessOutsideRedirect.php @@ -7,8 +7,8 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Client\Browser; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteSuccessOutsideRedirect @@ -24,11 +24,11 @@ class AssertUrlRewriteSuccessOutsideRedirect extends AbstractConstraint * Assert that outside redirect was success * * @param UrlRewrite $urlRewrite - * @param Browser $browser + * @param BrowserInterface $browser * @param UrlRewrite|null $initialRewrite [optional] * @return void */ - public function processAssert(UrlRewrite $urlRewrite, Browser $browser, UrlRewrite $initialRewrite = null) + public function processAssert(UrlRewrite $urlRewrite, BrowserInterface $browser, UrlRewrite $initialRewrite = null) { $urlRequestPath = $urlRewrite->hasData('request_path') ? $urlRewrite->getRequestPath() diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteUpdatedProductInGrid.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteUpdatedProductInGrid.php index 2f7fec91332131002bce522a782d058a922be4d2..a54513d48cf5e9e0f11b0f23f49c87ebf0ae307b 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteUpdatedProductInGrid.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Constraint/AssertUrlRewriteUpdatedProductInGrid.php @@ -8,7 +8,7 @@ namespace Magento\UrlRewrite\Test\Constraint; use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUrlRewriteUpdatedProductInGrid diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite.php index 8d8459e15baad0f5d35218ffb62d27ed37280d3c..ace141782b55077996b11965fe80423eade146a4 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite.php @@ -6,7 +6,7 @@ namespace Magento\UrlRewrite\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class UrlRewrite diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/StoreId.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/StoreId.php index 8d4cfb7965d72a84e45b3648e1a9becbf39b9cbd..5d234bfab7156b4bc26890eebd0f2c1202b75493 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/StoreId.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/StoreId.php @@ -7,8 +7,8 @@ namespace Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\Store\Test\Fixture\Store; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class StoreId diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/TargetPath.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/TargetPath.php index af5e022660cbfc8aca8e71b0ff9a4d716020b8dc..44614ad58326163a61320b149af2b5510566ad53 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/TargetPath.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Fixture/UrlRewrite/TargetPath.php @@ -6,8 +6,8 @@ namespace Magento\UrlRewrite\Test\Fixture\UrlRewrite; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class TargetPath diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/Curl.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/Curl.php index b556d3cf36a7be10594d2302c60513dac51d78cb..d99f658b73cc2850ed2e88d6d99272f43fdf2d3a 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/Curl.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/Curl.php @@ -6,12 +6,12 @@ namespace Magento\UrlRewrite\Test\Handler\UrlRewrite; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/UrlRewriteInterface.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/UrlRewriteInterface.php index a566d766b43d7b090b907dfc23315f92bd520d4d..0651b1c0430f65be62d9bdd62682f69244f7c9ec 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/UrlRewriteInterface.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Handler/UrlRewrite/UrlRewriteInterface.php @@ -6,7 +6,7 @@ namespace Magento\UrlRewrite\Test\Handler\UrlRewrite; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface UrlRewriteInterface diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Repository/UrlRewrite.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Repository/UrlRewrite.php index 4c830610af11fc611dc2a19ac4dabd89b06d727b..0e1b7a3421d54ab75349ac7e25e349bde385300a 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Repository/UrlRewrite.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/Repository/UrlRewrite.php @@ -6,7 +6,7 @@ namespace Magento\UrlRewrite\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class UrlRewrite diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateCategoryRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateCategoryRewriteEntityTest.php index 6041d62ee5838b5210ad93b3ca7be2a3fc3322ec..636a64f31e559b3586a72f06737c8a3e131cdd03 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateCategoryRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateCategoryRewriteEntityTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Create Category Rewrites Entity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateProductUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateProductUrlRewriteEntityTest.php index 093391036ecee562a963b6c3d2430ac125dc3912..f4e8d5d46f848a73405e94dffff40288884e720f 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateProductUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/CreateProductUrlRewriteEntityTest.php @@ -10,7 +10,7 @@ use Magento\Catalog\Test\Fixture\CatalogProductSimple; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Product URL Rewrites Entity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCategoryUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCategoryUrlRewriteEntityTest.php index 7462cf0db538aea46d428eba71b2ed36ad83b537..75365689598a48d2b2d548a4cc9d9c6451b2eab1 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCategoryUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCategoryUrlRewriteEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\UrlRewrite\Test\TestCase; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Delete Category URL Rewrites Entity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCustomUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCustomUrlRewriteEntityTest.php index 34b68473758aaab724f6e48faf8cb8d08d91c7ac..f5592e87abef014f261c7d6bcaef3f4a6557972c 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCustomUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteCustomUrlRewriteEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\UrlRewrite\Test\TestCase; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteCustomUrlRewriteEntity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteProductUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteProductUrlRewriteEntityTest.php index 2fbcc64c07ec5c7b3e36ff7ff70bcc34abbceb92..c668f0512eabda5375eef8fb30e59bc2f203bc1c 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteProductUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/DeleteProductUrlRewriteEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\UrlRewrite\Test\TestCase; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteProductUrlRewritesEntity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCategoryUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCategoryUrlRewriteEntityTest.php index f5825167cbba0890ce13e92bc392929fc7309714..25a5f58638c939f967563deab905f2777bf5c47b 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCategoryUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCategoryUrlRewriteEntityTest.php @@ -10,8 +10,8 @@ use Magento\Catalog\Test\Fixture\Category; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateCategoryUrlRewritesEntity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCustomUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCustomUrlRewriteEntityTest.php index 909577d62f65a98a3b91b6bba81d5c5568021a44..c5652832a328a4d77964282a5ff6306d70d07362 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCustomUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateCustomUrlRewriteEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\UrlRewrite\Test\TestCase; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateCustomUrlRewritesEntity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateProductUrlRewriteEntityTest.php b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateProductUrlRewriteEntityTest.php index a6988a459b4aa05193866efc86eed0347d3f2fb7..3b7562540e692afc45f9053932eae6730d0aa8f8 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateProductUrlRewriteEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/TestCase/UpdateProductUrlRewriteEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\UrlRewrite\Test\TestCase; use Magento\UrlRewrite\Test\Fixture\UrlRewrite; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteEdit; use Magento\UrlRewrite\Test\Page\Adminhtml\UrlRewriteIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for Update Product URL Rewrites Entity diff --git a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/etc/constraint.xml b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/etc/constraint.xml index df293a41289e30370da9f98fe290c08cfd2c7efe..9578f490e7f642f242e7fe065e59708bbe9ffd28 100644 --- a/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/etc/constraint.xml +++ b/dev/tests/functional/tests/app/Magento/UrlRewrite/Test/etc/constraint.xml @@ -24,8 +24,8 @@ <require> <urlRewrite class="Magento\UrlRewrite\Test\Fixture\UrlRewrite"/> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView"/> - <product class="Mtf\Fixture\FixtureInterface"/> - <browser class="Mtf\Client\Browser"/> + <product class="Magento\Mtf\Fixture\FixtureInterface"/> + <browser class="Magento\Mtf\Client\Browser"/> </require> </assertUrlRewriteProductRedirect> <assertUrlRewriteDeletedMessage module="Magento_UrlRewrite"> @@ -46,7 +46,7 @@ <require> <catalogProductView class="Magento\Catalog\Test\Page\Product\CatalogProductView"/> <productRedirect class="Magento\UrlRewrite\Test\Fixture\UrlRewrite"/> - <browser class="Mtf\Client\Browser"/> + <browser class="Magento\Mtf\Client\Browser"/> </require> </assertPageByUrlRewriteIsNotFound> <assertUrlRewriteCustomRedirect module="Magento_UrlRewrite"> @@ -56,14 +56,14 @@ <severity>low</severity> <require> <urlRewrite class="Magento\UrlRewrite\Test\Fixture\UrlRewrite"/> - <browser class="Mtf\Client\Browser"/> + <browser class="Magento\Mtf\Client\Browser"/> </require> </assertUrlRewriteSuccessOutsideRedirect> <assertUrlRewriteCustomSearchRedirect module="Magento_UrlRewrite"> <severity>low</severity> <require> <urlRewrite class="Magento\UrlRewrite\Test\Fixture\UrlRewrite"/> - <browser class="Mtf\Client\Browser"/> + <browser class="Magento\Mtf\Client\Browser"/> <categoryView class="Magento\Catalog\Test\Page\Category\CatalogCategoryView"/> </require> </assertUrlRewriteCustomSearchRedirect> diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/Role/Tab/Role.php b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/Role/Tab/Role.php index 8720daea217441fda21f2357b321ef53ff165d4c..dd79a2b7b3c9c815c6e2f7ec8d75935cbcb4c66b 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/Role/Tab/Role.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/Role/Tab/Role.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Block\Adminhtml\Role\Tab; use Magento\Backend\Test\Block\Widget\Tab; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Role @@ -19,10 +19,10 @@ class Role extends Tab * Fills username in user grid * * @param array $fields - * @param Element $element + * @param SimpleElement $element * @return void */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $users = (is_array($fields['in_role_users']['value'])) ? $fields['in_role_users']['value'] diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Form.php b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Form.php index cc4e2577686563238bae994ae6417271961adc41..6f55faf944b174eca4a330ed686dc16042efd27b 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Form.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Form.php @@ -8,8 +8,8 @@ namespace Magento\User\Test\Block\Adminhtml\User\Edit; use Magento\Backend\Test\Block\Widget\FormTabs; use Magento\User\Test\Block\Adminhtml\User\Edit\Tab\Roles; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Element; +use Magento\Mtf\Client\Locator; /** * Class Form diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/PageActions.php b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/PageActions.php index f184a963d6f53ea333dc3fd4e3da8e0d49bce2ad..c2cf7eaf643955c850940a7b7c78254aa710d881 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/PageActions.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/PageActions.php @@ -29,6 +29,6 @@ class PageActions extends FormPageActions public function forceSignIn() { $this->_rootElement->find($this->forceSignIn)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } } diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Tab/Roles.php b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Tab/Roles.php index 8ab5d10db8f3d45b95e3741254b223001a624066..bcf2bebf558713998dd9bcf6f904835d111a4ab6 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Tab/Roles.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Edit/Tab/Roles.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Block\Adminhtml\User\Edit\Tab; use Magento\Backend\Test\Block\Widget\Grid; -use Mtf\Client\Element; +use Magento\Mtf\Client\Element; /** * Class Roles diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Tab/Role.php b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Tab/Role.php index 263be3d74aae9b63be1dfc853b96e715793caed9..4b05852ef8d751434cdbd554e0e1e58f00bdab6d 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Tab/Role.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Block/Adminhtml/User/Tab/Role.php @@ -6,9 +6,8 @@ namespace Magento\User\Test\Block\Adminhtml\User\Tab; +use Magento\Mtf\Client\Element\SimpleElement; use Magento\Backend\Test\Block\Widget\Tab; -use Magento\User\Test\Block\Adminhtml\User\Tab\Role\Grid; -use Mtf\Client\Element; /** * Class Role @@ -20,10 +19,10 @@ class Role extends Tab * Fill user options * * @param array $fields - * @param Element|null $element + * @param SimpleElement|null $element * @return void */ - public function fillFormTab(array $fields, Element $element = null) + public function fillFormTab(array $fields, SimpleElement $element = null) { $this->getRoleGrid()->searchAndSelect(['rolename' => $fields['role_id']['value']]); } diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensErrorRevokeMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensErrorRevokeMessage.php index 81b5df0b0dc20a1cf103e24df62e9c77740d4dd2..787b7e390d674747f3d270a01ec5b1fd7ab20adf 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensErrorRevokeMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertAccessTokensErrorRevokeMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertAccessTokensErrorRevokeMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnAccount.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnAccount.php index a9797795c84a9566dbc757d53b50d064353158cd..8f6d0505517bd2c2a09aea41c52dc40894640a0c 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnAccount.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnAccount.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertImpossibleDeleteYourOwnAccount diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnRole.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnRole.php index fd69fc3cee73f171d9ae614b6349d70e08dabebf..d44d53f21ca75701a2756aafe06aeb1186dbfbee 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnRole.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertImpossibleDeleteYourOwnRole.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserRoleEditRole; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRoleSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleInGrid.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleInGrid.php index 7e8a3a35e0c7076c560261bd19bf477e4985d609..49e9f3fb36f40a1a519946eaa642b15b5fc8d44b 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleInGrid.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleInGrid.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRoleInGrid diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleNotInGrid.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleNotInGrid.php index ec7b5ba0e72285aa227d83127931f0edddd77c90..cb67bc0a80e732511b3d482c9dcd1cf8004f134c 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRoleNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessDeleteMessage.php index 2033e0c303a9d3d9c8812cc0164eaeefd612082c..38f74ad1ead1db38eb6e7b012fc81f3623fb474b 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRoleSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessSaveMessage.php index dc4d32653ab69b08a36e006aa742367e1d51a07b..0436e6c60cfd39b6b845636f0e7773ed19b0a9af 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertRoleSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertRoleSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserDuplicateMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserDuplicateMessage.php index 568cbd551d0f301b1925accd2b24fc7354de644b..c0a9c0c71554a9d38e3a512a8f33ec0ee3fd565a 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserDuplicateMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserDuplicateMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserDuplicateMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInGrid.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInGrid.php index 6f2bf4e896f1c2b98398a502487e7d3bc93f923d..1369fa1591dd32d7101bd65164d19dce7f16f3b8 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInGrid.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInGrid.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserInGrid diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInvalidEmailMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInvalidEmailMessage.php index aa8877c54bd65c4caabb99c36bbfa73706d478d4..431b9f13c71cc8838efebd393e61f2b311276733 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInvalidEmailMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserInvalidEmailMessage.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserEdit; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserInvalidEmailMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserNotInGrid.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserNotInGrid.php index 08832e25f67f90c9760b66ce9da37f55ce201251..909f581f7675923c0aa4aa70ccba604e3bdd636e 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserNotInGrid.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserNotInGrid.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserNotInGrid diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserRoleSalesRestrictedAccess.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserRoleSalesRestrictedAccess.php index ebd351e0454c49aaab6af8ccb86863cc4000a926..04f22b59e617eae8f5a0ee0df03b0952c12ad4f0 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserRoleSalesRestrictedAccess.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserRoleSalesRestrictedAccess.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserRoleSalesRestrictedAccess diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessDeleteMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessDeleteMessage.php index 72ed5cb755a1fb270c5196bdccd879fa433b46f8..c6f7e9e69495c0d3530e7db93cd670b00490a279 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessDeleteMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessDeleteMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserSuccessDeleteMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogOut.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogOut.php index 5b46a44f3fb1dd62f7821cdf8f5e0deab4b0c845..9ec6841c6f9885fe772ea9e9f8c2cbcb32196f79 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogOut.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogOut.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\Backend\Test\Page\AdminAuthLogin; use Magento\Backend\Test\Page\Adminhtml\Dashboard; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserSuccessLogOut diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogin.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogin.php index aa4862434fdb847fbf560f646faf9bed2eb634e7..4544f7b69dae5feed6804d97dafe170e2921d7db 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogin.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessLogin.php @@ -9,7 +9,7 @@ namespace Magento\User\Test\Constraint; use Magento\Backend\Test\Page\AdminAuthLogin; use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\User\Test\Fixture\User; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserSuccessLogin diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessSaveMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessSaveMessage.php index 9804e38b77bcc40af427563c1cff278c365c38db..d401448522ebf4338de4bcc7108f6f3837989552 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessSaveMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserSuccessSaveMessage.php @@ -7,7 +7,7 @@ namespace Magento\User\Test\Constraint; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserSuccessSaveMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserWrongCredentialsMessage.php b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserWrongCredentialsMessage.php index 156672a632950198cac67b280d585fe3d80d1d53..7c2be591562841d405f82aeba0b0f56c4aff6036 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserWrongCredentialsMessage.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Constraint/AssertUserWrongCredentialsMessage.php @@ -8,7 +8,7 @@ namespace Magento\User\Test\Constraint; use Magento\Backend\Test\Page\AdminAuthLogin; use Magento\User\Test\Fixture\User; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertUserWrongCredentialsMessage diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUser.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUser.php index bd67f84b2def072e1652d20463e72c8ec0537156..a0ee8cf951c0f3146f1f5469fe1fc9edfc2dba17 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUser.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUser.php @@ -6,10 +6,10 @@ namespace Magento\User\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; -use Mtf\ObjectManager; -use Mtf\System\Config; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\System\Config; /** * Fixture with all necessary data for user creation on backend @@ -47,8 +47,8 @@ class AdminUser extends DataFixture */ protected function _initData() { - /** @var \Mtf\System\Config $systemConfig */ - $systemConfig = ObjectManager::getInstance()->create('Mtf\System\Config'); + /** @var \Magento\Mtf\System\Config $systemConfig */ + $systemConfig = ObjectManager::getInstance()->create('Magento\Mtf\System\Config'); $superAdminPassword = $systemConfig->getConfigParam('application/backend_user_credentials/password'); $this->_data = [ 'fields' => [ diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole.php index f88d9fa29c0992811361b885db0c77fbc2f69bcc..88180cf31cb0ad6e3f634d6fab2adf887898f010 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole.php @@ -6,7 +6,7 @@ namespace Magento\User\Test\Fixture; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AdminUserRole diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole/InRoleUsers.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole/InRoleUsers.php index 80908c4f372c72153e803fb245760d8a8d1122a9..eb1f27ccdc821d844c57b3607abcf09b43b429a0 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole/InRoleUsers.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/AdminUserRole/InRoleUsers.php @@ -7,8 +7,8 @@ namespace Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Fixture\User; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class InRoleUsers diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Resource.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Resource.php index d4cb9f015398fa773295ec0bfff69d38fffa1ee8..d9e1c4638eea02eb4a9bf6458a91e912ca5a71bc 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Resource.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Resource.php @@ -5,7 +5,7 @@ */ namespace Magento\User\Test\Fixture; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Fixture\DataFixture; /** * ACL resources fixture diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Role.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Role.php index ab50e9843b5fbd15028d7023b6f47dec8d490c61..acb266f5d6c6978f4a7b9ffee53445115d0d2f33 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Role.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/Role.php @@ -6,8 +6,8 @@ namespace Magento\User\Test\Fixture; -use Mtf\Factory\Factory; -use Mtf\Fixture\DataFixture; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Fixture\DataFixture; /** * Class Role diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User.php index 298cac0e65901cdb5f089011817e752eae702ea5..78053ea189cb6a4eb0feec26275b3bfccdf81eac 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User.php @@ -6,12 +6,12 @@ namespace Magento\User\Test\Fixture; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; -use Mtf\Handler\HandlerFactory; -use Mtf\Repository\RepositoryFactory; -use Mtf\System\Config; -use Mtf\System\Event\EventManagerInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Handler\HandlerFactory; +use Magento\Mtf\Repository\RepositoryFactory; +use Magento\Mtf\System\Config; +use Magento\Mtf\System\Event\EventManagerInterface; /** * Class User diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User/RoleId.php b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User/RoleId.php index 641f36f34b545775600fa67e93367e60d84f851d..6ee9c5eb5ed81f2379f24ba2c4f3ef69cc3d96d3 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User/RoleId.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Fixture/User/RoleId.php @@ -7,8 +7,8 @@ namespace Magento\User\Test\Fixture\User; use Magento\User\Test\Fixture\AdminUserRole; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class RoleId diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/AdminUserRoleInterface.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/AdminUserRoleInterface.php index 7e2b3c353efce7a1cf2d7fa575799d942cc44a9d..a7d0408abdba75e672a9131b4d2b45b0ff4cdba9 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/AdminUserRoleInterface.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/AdminUserRoleInterface.php @@ -6,7 +6,7 @@ namespace Magento\User\Test\Handler\AdminUserRole; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface AdminUserRoleInterface diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/Curl.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/Curl.php index cbad1e0fbbfd392d44075e31c865ba0c6be8daa0..1162d727958f3d04ebe85872fc2bfec934bd7009 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/Curl.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/AdminUserRole/Curl.php @@ -7,12 +7,12 @@ namespace Magento\User\Test\Handler\AdminUserRole; use Magento\Backend\Test\Handler\Extractor; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateRole.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateRole.php index a5d600af5298643b4b2c429a4df4cbfc47438ed3..df5f11c9a29f313670df7bc214995db295741628 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateRole.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateRole.php @@ -7,12 +7,12 @@ namespace Magento\User\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class CreateCategory. diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateUser.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateUser.php index cfbd54c09a362330dc52eae2916cba606c6b8077..e3598d51730601640e449db524790058689e8226 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateUser.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/Curl/CreateUser.php @@ -6,12 +6,12 @@ namespace Magento\User\Test\Handler\Curl; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Curl handler for persisting Magento user diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/Curl.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/Curl.php index 703441ca08b3a2a3d128278d07b75f96b5df2436..23e8ae322300f6778065d5e91855df3c411ef203 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/Curl.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/Curl.php @@ -7,12 +7,12 @@ namespace Magento\User\Test\Handler\User; use Magento\Backend\Test\Handler\Extractor; -use Mtf\Fixture\FixtureInterface; -use Mtf\Handler\Curl as AbstractCurl; -use Mtf\System\Config; -use Mtf\Util\Protocol\CurlInterface; -use Mtf\Util\Protocol\CurlTransport; -use Mtf\Util\Protocol\CurlTransport\BackendDecorator; +use Magento\Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Handler\Curl as AbstractCurl; +use Magento\Mtf\System\Config; +use Magento\Mtf\Util\Protocol\CurlInterface; +use Magento\Mtf\Util\Protocol\CurlTransport; +use Magento\Mtf\Util\Protocol\CurlTransport\BackendDecorator; /** * Class Curl diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/UserInterface.php b/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/UserInterface.php index 887313ad2b925bb20d10c206100942c89edd8a01..b18cd5603c8b6bb5c570e093b1e89390b4267127 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/UserInterface.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Handler/User/UserInterface.php @@ -6,7 +6,7 @@ namespace Magento\User\Test\Handler\User; -use Mtf\Handler\HandlerInterface; +use Magento\Mtf\Handler\HandlerInterface; /** * Interface UserInterface diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUser.php b/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUser.php index cdb7260a8371be8d62ceee6f47dc6ece10db364b..9046699e1a452f9bb5b7987654c28a62594219e3 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUser.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUser.php @@ -6,7 +6,7 @@ namespace Magento\User\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Admin User Repository diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUserRole.php b/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUserRole.php index 334fda5055bdcb757ab803d78a4ab190580351f8..5a94b249e7255e477a38ca9f359bd702b6fec562 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUserRole.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Repository/AdminUserRole.php @@ -6,7 +6,7 @@ namespace Magento\User\Test\Repository; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Repository\AbstractRepository; /** * Class AdminUserRole diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Repository/Role.php b/dev/tests/functional/tests/app/Magento/User/Test/Repository/Role.php index 8c53310032984b006360837991a2d8ee1f5517c2..08eb926a06a3e94c0a16ab168b2e50b31a41eb59 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Repository/Role.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Repository/Role.php @@ -6,8 +6,8 @@ namespace Magento\User\Test\Repository; -use Mtf\Factory\Factory; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\Factory\Factory; +use Magento\Mtf\Repository\AbstractRepository; /** * Class Abstract Repository diff --git a/dev/tests/functional/tests/app/Magento/User/Test/Repository/User.php b/dev/tests/functional/tests/app/Magento/User/Test/Repository/User.php index 16ef63904a209d3667f06136498f5991253f5f94..a8098084f2be48edf2b59489af69c85f967a2700 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/Repository/User.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/Repository/User.php @@ -6,8 +6,8 @@ namespace Magento\User\Test\Repository; -use Mtf\ObjectManager; -use Mtf\Repository\AbstractRepository; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\Repository\AbstractRepository; /** * Class User @@ -24,8 +24,8 @@ class User extends AbstractRepository */ public function __construct(array $defaultConfig = [], array $defaultData = []) { - /** @var \Mtf\System\Config $systemConfig */ - $systemConfig = ObjectManager::getInstance()->create('Mtf\System\Config'); + /** @var \Magento\Mtf\System\Config $systemConfig */ + $systemConfig = ObjectManager::getInstance()->create('Magento\Mtf\System\Config'); $superAdminPassword = $systemConfig->getConfigParam('application/backend_user_credentials/password'); $this->_data['default'] = [ 'username' => 'admin', diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php index b5ea8fd027ae6748b7cbfef6a17019d0405fb9a6..c77bc0c762a3da7f394ff6d16abdb468114350d5 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserEntityTest.php @@ -9,8 +9,8 @@ namespace Magento\User\Test\TestCase; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserEdit; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateAdminUserEntityTest diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserRoleEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserRoleEntityTest.php index 30918f5c1ca7c2450a853c06dd5036b48be2f142..57ae388e1a34cd35a209afbacee0758a62c99b6b 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserRoleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/CreateAdminUserRoleEntityTest.php @@ -9,7 +9,7 @@ namespace Magento\User\Test\TestCase; use Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Page\Adminhtml\UserRoleEditRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for CreateAdminUserRolesEntity diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteAdminUserEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteAdminUserEntityTest.php index 1d29e314eeedf57f4f9d2887b032d9f1cca67b81..d6d4c9f9debbcf682bb730836658839d0126416f 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteAdminUserEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteAdminUserEntityTest.php @@ -11,8 +11,8 @@ use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserEdit; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteAdminUserEntity diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteUserRoleEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteUserRoleEntityTest.php index 3e52e0369e7730237debe8bd25145234dbfa36fc..161917c3b546196c4ac0619af2aa9d94a2170da8 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteUserRoleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/DeleteUserRoleEntityTest.php @@ -12,8 +12,8 @@ use Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserRoleEditRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for DeleteUserRoleEntity diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/RevokeAllAccessTokensForAdminWithoutTokensTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/RevokeAllAccessTokensForAdminWithoutTokensTest.php index 7de13a4d5027e6b8a32250491d592f0ec5859667..bdac1186edc8c541535c562ee183035336bd4e80 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/RevokeAllAccessTokensForAdminWithoutTokensTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/RevokeAllAccessTokensForAdminWithoutTokensTest.php @@ -9,7 +9,7 @@ namespace Magento\User\Test\TestCase; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserEdit; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Revoke all access tokens for admin without tokens. diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserEntityTest.php index 1bbe6addc155efe85bd21134084cd3d3d1a8e467..cad7c857bfb4794f0d5abb76d72e42045a7e8937 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserEntityTest.php @@ -11,8 +11,8 @@ use Magento\Backend\Test\Page\Adminhtml\Dashboard; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserEdit; use Magento\User\Test\Page\Adminhtml\UserIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateAdminUserEntity diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserRoleEntityTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserRoleEntityTest.php index 108bafa3026a100837c2ffe00349449cb8156bda..06a396c982cbac2ccd316f69d478f20d0a6b9b00 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserRoleEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UpdateAdminUserRoleEntityTest.php @@ -12,7 +12,7 @@ use Magento\User\Test\Fixture\AdminUserRole; use Magento\User\Test\Fixture\User; use Magento\User\Test\Page\Adminhtml\UserRoleEditRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\TestCase\Injectable; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for UpdateAdminUserRoleEntity diff --git a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UserLoginAfterChangingPermissionsTest.php b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UserLoginAfterChangingPermissionsTest.php index cf96f02228fe7cf58e7c9ef01d39ba84d782dbb0..003e6640bdfe763919f694d9115d8a78e3d77ea4 100644 --- a/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UserLoginAfterChangingPermissionsTest.php +++ b/dev/tests/functional/tests/app/Magento/User/Test/TestCase/UserLoginAfterChangingPermissionsTest.php @@ -13,8 +13,8 @@ use Magento\User\Test\Page\Adminhtml\UserEdit; use Magento\User\Test\Page\Adminhtml\UserIndex; use Magento\User\Test\Page\Adminhtml\UserRoleEditRole; use Magento\User\Test\Page\Adminhtml\UserRoleIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\TestCase\Injectable; /** * Test that user can login from the first attempt just after his permissions were changed. diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist.php index 4c2bc63d30ead144ad8aa9ebd9d0e633805b7191..e147152e204622e2a7fd90d339ef5f183930bd4a 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist.php @@ -6,9 +6,9 @@ namespace Magento\Wishlist\Test\Block\Adminhtml\Customer\Edit\Tab; +use Magento\Mtf\Client\Element; use Magento\Backend\Test\Block\Widget\Tab; use Magento\Wishlist\Test\Block\Adminhtml\Customer\Edit\Tab\Wishlist\Grid; -use Mtf\Client\Element; /** * Class Wishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist/Grid.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist/Grid.php index 42e9203756977dba602c8485114237bc0bbda2fa..fd2a372a444733ab4e232d2314208b5f3a0e4940 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist/Grid.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Adminhtml/Customer/Edit/Tab/Wishlist/Grid.php @@ -6,8 +6,8 @@ namespace Magento\Wishlist\Test\Block\Adminhtml\Customer\Edit\Tab\Wishlist; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Client\Element\SimpleElement; /** * Class Grid @@ -58,7 +58,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid protected function delete() { $this->_rootElement->find($this->rowItem . ' ' . $this->deleteLink)->click(); - $this->_rootElement->acceptAlert(); + $this->browser->acceptAlert(); } /** @@ -91,7 +91,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid * @param array $filter * @param bool $isSearchable [optional] * @param bool $isStrict [optional] - * @return Element + * @return SimpleElement */ protected function getRow(array $filter, $isSearchable = true, $isStrict = true) { @@ -119,7 +119,7 @@ class Grid extends \Magento\Backend\Test\Block\Widget\Grid ); } } - $location = $location . implode(' and ', $rows) . ']'; - return $this->_rootElement->find($location, Locator::SELECTOR_XPATH); + + return $this->_rootElement->find($location . implode(' and ', $rows) . ']', Locator::SELECTOR_XPATH); } } diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Sharing.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Sharing.php index baae27511671a97028086b9c7d7293bbc0578932..a85bd45da9299c3c4f4f4d93c8743bdf4184448f 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Sharing.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Sharing.php @@ -6,7 +6,7 @@ namespace Magento\Wishlist\Test\Block\Customer; -use Mtf\Block\Form; +use Magento\Mtf\Block\Form; /** * Class Sharing diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist.php index f3f8ac49c79c2c3f6d4cbafb257d7466b21b4a11..30e6dcd8dcca85ba922df43b610b552503fe2854 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist.php @@ -6,7 +6,7 @@ namespace Magento\Wishlist\Test\Block\Customer; -use Mtf\Block\Block; +use Magento\Mtf\Block\Block; /** * Class Wishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items.php index 719133ed60643819cf769f9322e7f0fb56ec6a29..153f40522c7601c316545fb72e8a62f3ca361612 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items.php @@ -7,10 +7,9 @@ namespace Magento\Wishlist\Test\Block\Customer\Wishlist; use Magento\Wishlist\Test\Block\Customer\Wishlist\Items\Product; -use Mtf\Block\Block; -use Mtf\Client\Element; -use Mtf\Client\Element\Locator; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Block\Block; +use Magento\Mtf\Client\Locator; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class Items @@ -56,7 +55,6 @@ class Items extends Block { while ($this->_rootElement->find($this->remove)->isVisible()) { $this->_rootElement->find($this->remove)->click(); - $this->reinitRootElement(); } } } diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php index bb241e9c6cf0e88debf149794196abdfca130a0e..5f427ca5531f3dabfa6297513defebd191875959 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Block/Customer/Wishlist/Items/Product.php @@ -6,8 +6,8 @@ namespace Magento\Wishlist\Test\Block\Customer\Wishlist\Items; -use Mtf\Block\Form; -use Mtf\Client\Element\Locator; +use Magento\Mtf\Block\Form; +use Magento\Mtf\Client\Locator; /** * Class Product @@ -114,8 +114,8 @@ class Product extends Form if ($viewDetails->isVisible()) { $this->_rootElement->find($this->footer, Locator::SELECTOR_XPATH)->click(); $viewDetails->click(); - $labels = $this->_rootElement->find($this->optionLabel)->getElements(); - $values = $this->_rootElement->find($this->optionValue)->getElements(); + $labels = $this->_rootElement->getElements($this->optionLabel); + $values = $this->_rootElement->getElements($this->optionValue); $data = []; foreach ($labels as $key => $label) { if (!$label->isVisible()) { diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertAddProductToWishlistSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertAddProductToWishlistSuccessMessage.php index 05eada0d084a89a402b59a5b10e2c90e022d66e4..0e616a4d881dd06a42562fefb1601286b0ff56be 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertAddProductToWishlistSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertAddProductToWishlistSuccessMessage.php @@ -7,8 +7,8 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertAddProductToWishlistSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertMoveProductToWishlistSuccessMessage.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertMoveProductToWishlistSuccessMessage.php index 371cce58db295d532473d01d34bc6157aa8ef35c..3bfdd344eb6e4296a1604136bf22d2b9391974c1 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertMoveProductToWishlistSuccessMessage.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertMoveProductToWishlistSuccessMessage.php @@ -7,8 +7,8 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertAddProductToWishlistSuccessMessage diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductDetailsInWishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductDetailsInWishlist.php index accea31efaf7abe037c81b9155b5279756dae0cb..791b72d28a99fba25af93d690d6f4e7015fe2eb1 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductDetailsInWishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductDetailsInWishlist.php @@ -8,9 +8,9 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractAssertForm; -use Mtf\Fixture\FixtureFactory; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractAssertForm; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertBundleProductDetailsInWishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductInCustomerWishlistOnBackendGrid.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductInCustomerWishlistOnBackendGrid.php index d8ed443bf8013861f7a6383fe8f31346b12c8bfa..afa3f5eb3db895b4497e47a60c52350780232bc4 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductInCustomerWishlistOnBackendGrid.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductInCustomerWishlistOnBackendGrid.php @@ -8,8 +8,8 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; use Magento\Wishlist\Test\Block\Adminhtml\Customer\Edit\Tab\Wishlist\Grid; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\FixtureInterface; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\FixtureInterface; /** * Class AssertProductInCustomerWishlistOnBackendGrid diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInCustomerBackendWishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInCustomerBackendWishlist.php index 6f59d50f1d1d852188916d6b2c229fc6a9d97faf..8370fbd4a307c07f85d2e91ea6d0bdd9a095116d 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInCustomerBackendWishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInCustomerBackendWishlist.php @@ -9,8 +9,8 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Customer\Test\Page\Adminhtml\CustomerIndex; use Magento\Customer\Test\Page\Adminhtml\CustomerIndexEdit; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertProductIsPresentInCustomerBackendWishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInWishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInWishlist.php index f0fee57f93b6aa1516ecc4fe1e9321cacb22d11a..88f0192ade221c13a8cff1dca8cc50ca34f539ff 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInWishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductIsPresentInWishlist.php @@ -9,8 +9,8 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertProductIsPresentInWishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductsIsAbsentInWishlist.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductsIsAbsentInWishlist.php index dbd869d0a09931a2fcf6437f982e81de77b5c4a3..661cfac7c9b8da9d1bfc1975e60f0a33169de316 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductsIsAbsentInWishlist.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertProductsIsAbsentInWishlist.php @@ -12,8 +12,8 @@ use Magento\Customer\Test\Page\CustomerAccountIndex; use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; -use Mtf\Fixture\InjectableFixture; +use Magento\Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Fixture\InjectableFixture; /** * Class AssertProductsIsAbsentInWishlist diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistIsEmpty.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistIsEmpty.php index 502839a77155d254e6a562962a7f835d7305c6b1..794e8b46076741827fe00005f15ca37850197a97 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistIsEmpty.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistIsEmpty.php @@ -8,7 +8,7 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Cms\Test\Page\CmsIndex; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWishlistIsEmpty diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistShareMessage.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistShareMessage.php index cd96a7d611791fad5a53f66893f9629d4a842388..302e994568ddd2ab57a7f2a8c0eb7505cd4c19b3 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistShareMessage.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/Constraint/AssertWishlistShareMessage.php @@ -7,7 +7,7 @@ namespace Magento\Wishlist\Test\Constraint; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Constraint\AbstractConstraint; +use Magento\Mtf\Constraint\AbstractConstraint; /** * Class AssertWishlistShareMessage diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AbstractWishlistTest.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AbstractWishlistTest.php index 643858b155e9ab07211e9d2856444dadc5e5d7a1..b69fa2218ad10b758cfb53333ff8130514d52ca6 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AbstractWishlistTest.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/AbstractWishlistTest.php @@ -10,9 +10,9 @@ use Magento\Catalog\Test\Page\Product\CatalogProductView; use Magento\Cms\Test\Page\CmsIndex; use Magento\Customer\Test\Fixture\CustomerInjectable; use Magento\Wishlist\Test\Page\WishlistIndex; -use Mtf\Fixture\FixtureFactory; -use Mtf\ObjectManager; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Fixture\FixtureFactory; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\TestCase\Injectable; /** * Class AbstractWishlistTest diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ShareWishlistEntityTest.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ShareWishlistEntityTest.php index e50fb08c76c17d0cb71bf5a8f4d4446fa1ce8209..342066c81cdc0256516f55b60a2eeef650f78ebc 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ShareWishlistEntityTest.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestCase/ShareWishlistEntityTest.php @@ -15,8 +15,8 @@ use Magento\Customer\Test\Page\CustomerAccountLogin; use Magento\Customer\Test\Page\CustomerAccountLogout; use Magento\Wishlist\Test\Page\WishlistIndex; use Magento\Wishlist\Test\Page\WishlistShare; -use Mtf\Client\Browser; -use Mtf\TestCase\Injectable; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestCase\Injectable; /** * Test Creation for ShareWishlistEntity @@ -149,14 +149,14 @@ class ShareWishlistEntityTest extends Injectable /** * Share wish list * - * @param Browser $browser + * @param BrowserInterface $browser * @param CustomerInjectable $customer * @param CatalogProductSimple $product * @param array $sharingInfo * @return void */ public function test( - Browser $browser, + BrowserInterface $browser, CustomerInjectable $customer, CatalogProductSimple $product, array $sharingInfo diff --git a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestStep/AddProductsToWishlistStep.php b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestStep/AddProductsToWishlistStep.php index 78e4ec4ed494656868ca8c81bffa10d568b4e2eb..615da8212ef2846f1dc30ceb8945e31b612845ed 100644 --- a/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestStep/AddProductsToWishlistStep.php +++ b/dev/tests/functional/tests/app/Magento/Wishlist/Test/TestStep/AddProductsToWishlistStep.php @@ -7,8 +7,8 @@ namespace Magento\Wishlist\Test\TestStep; use Magento\Catalog\Test\Page\Product\CatalogProductView; -use Mtf\Client\Browser; -use Mtf\TestStep\TestStepInterface; +use Magento\Mtf\Client\BrowserInterface; +use Magento\Mtf\TestStep\TestStepInterface; /** * Class AddProductsToWishlistStep @@ -33,7 +33,7 @@ class AddProductsToWishlistStep implements TestStepInterface /** * Interface Browser * - * @var Browser + * @var BrowserInterface */ protected $browser; @@ -47,13 +47,13 @@ class AddProductsToWishlistStep implements TestStepInterface /** * @constructor * @param CatalogProductView $catalogProductView - * @param Browser $browser + * @param BrowserInterface $browser * @param array $products * @param bool $configure [optional] */ public function __construct( CatalogProductView $catalogProductView, - Browser $browser, + BrowserInterface $browser, array $products, $configure = false ) { diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/GithubPublicationTests.php b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/GithubPublicationTests.php similarity index 98% rename from dev/tests/functional/testsuites/Mtf/TestSuite/GithubPublicationTests.php rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/GithubPublicationTests.php index 415b2955215140f8299216e7e5cea6e35639586a..69eea437e7eaa09f9471214311a28e7d935b9134 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/GithubPublicationTests.php +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/GithubPublicationTests.php @@ -4,7 +4,7 @@ * See COPYING.txt for license details. */ -namespace Mtf\TestSuite; +namespace Magento\Mtf\TestSuite; /** * Test suite prepared for Github Publication diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests.php b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests.php similarity index 81% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests.php rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests.php index 30d57ac5a5ff45c74c46f124e94bb19e1520b058..1cc1259d981bdd3c1026079080987996ed57a5b8 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests.php +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests.php @@ -4,11 +4,11 @@ * See COPYING.txt for license details. */ -namespace Mtf\TestSuite; +namespace Magento\Mtf\TestSuite; -use Mtf\ObjectManager; -use Mtf\ObjectManagerFactory; -use Mtf\TestRunner\Configuration; +use Magento\Mtf\ObjectManager; +use Magento\Mtf\ObjectManagerFactory; +use Magento\Mtf\TestRunner\Configuration; /** * Class InjectableTests @@ -70,12 +70,12 @@ class InjectableTests extends \PHPUnit_Framework_TestSuite /** * Prepare test suite and apply application state * - * @return \Mtf\TestSuite\AppState + * @return \Magento\Mtf\TestSuite\AppState */ public function prepareSuite() { $this->init(); - return $this->objectManager->create('Mtf\TestSuite\AppState'); + return $this->objectManager->create('Magento\Mtf\TestSuite\AppState'); } /** @@ -99,12 +99,13 @@ class InjectableTests extends \PHPUnit_Framework_TestSuite $confFilePath = realpath( MTF_BP . '/testsuites/' . $_ENV['testsuite_rule_path'] . '/' . $configurationFileName . '.xml' ); - /** @var \Mtf\TestRunner\Configuration $testRunnerConfiguration */ - $testRunnerConfiguration = $objectManagerFactory->getObjectManager()->get('\Mtf\TestRunner\Configuration'); + /** @var \Magento\Mtf\TestRunner\Configuration $testRunnerConfiguration */ + $testRunnerConfiguration = $objectManagerFactory->getObjectManager() + ->get('\Magento\Mtf\TestRunner\Configuration'); $testRunnerConfiguration->load($confFilePath); $testRunnerConfiguration->loadEnvConfig(); - $shared = ['Mtf\TestRunner\Configuration' => $testRunnerConfiguration]; + $shared = ['Magento\Mtf\TestRunner\Configuration' => $testRunnerConfiguration]; $this->objectManager = $objectManagerFactory->create($shared); } } diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/acceptance.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/acceptance.xml similarity index 82% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/acceptance.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/acceptance.xml index 7fc208a5ffe96fb1d757b715ee9bf7205bf77109..1f74e74f5eee2b605c7d3bd120459f829828c21b 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/acceptance.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/acceptance.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testcase"> <allow> <tag group="test_type" value="acceptance_test" /> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/basic.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic.xml similarity index 75% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/basic.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic.xml index 60f1dab551315da92075c6a49aa3dbed86113e1f..a63d9da454d4d4df30b0996dbe425c2aec99b536 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/basic.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/basic.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testsuite"> <allow> <namespace value="Magento" /> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/bat_ce.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/bat_ce.xml similarity index 91% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/bat_ce.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/bat_ce.xml index 913566809024a2790efc57976a54d39da7c72657..e875401e6e82d7f5237231537d5380f493ffc79d 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/bat_ce.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/bat_ce.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testsuite"> <allow> <!--Products--> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_cs.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_cs.xml similarity index 73% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_cs.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_cs.xml index eb0fd76bdba8aaba9a4e1f8b0cc691c4a07f0fb1..621c5d1e068d6973cc789079741265a1d1e734d0 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_cs.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_cs.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testcase"> <allow> <tag group="domain" value="CS" /> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_mx.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_mx.xml similarity index 73% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_mx.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_mx.xml index c6d1305ff3d7e9ae2cdae76557c21447116599ea..12891acd39b81676cd6585614ba57dd8d1241364 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_mx.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_mx.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testcase"> <allow> <tag group="domain" value="MX" /> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_ps.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_ps.xml similarity index 73% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_ps.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_ps.xml index 2790fcf7ce3fc8fdb8ce3501c8c78479e68c7a4b..fbbe25a921692250aa5df18ad2866ed1527115af 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/domain_ps.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/domain_ps.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testcase"> <allow> <tag group="domain" value="PS" /> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml similarity index 95% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml index a4b021b33173f4121db4e328221b77253df2844b..9c14458282a1dd939155541dbbe6de8dcc5fcc6b 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/end_to_end_ce.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testsuite"> <allow> <!--Product search--> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/installation.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/installation.xml similarity index 73% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/installation.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/installation.xml index e90f7639de25cc68291fb5feb211819d650916a1..262d254fe4c8c436d56c9f215572b72361b168b2 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/installation.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/installation.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testsuite"> <allow> <module value="Magento_Install"/> diff --git a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/mvp.xml b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/mvp.xml similarity index 73% rename from dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/mvp.xml rename to dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/mvp.xml index c3efd1454f1528182c613161d654bd6b38df00c6..220478d47ef3447ad74a43957fe76201863881c8 100644 --- a/dev/tests/functional/testsuites/Mtf/TestSuite/InjectableTests/mvp.xml +++ b/dev/tests/functional/testsuites/Magento/Mtf/TestSuite/InjectableTests/mvp.xml @@ -6,7 +6,7 @@ */ --> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" - xsi:noNamespaceSchemaLocation="../../../../vendor/magento/mtf/Mtf/TestRunner/etc/testRunner.xsd"> + xsi:noNamespaceSchemaLocation="../../../../../vendor/magento/mtf/Magento/Mtf/TestRunner/etc/testRunner.xsd"> <rule scope="testcase"> <allow> <tag group="mvp" value="yes" /> diff --git a/dev/tests/functional/utils/bootstrap.php b/dev/tests/functional/utils/bootstrap.php index 2910140e5dabf55153080ece4e8aea618af84c20..b2a8e0792a011d57cbf2873ad65c63e32f3a8144 100644 --- a/dev/tests/functional/utils/bootstrap.php +++ b/dev/tests/functional/utils/bootstrap.php @@ -14,6 +14,5 @@ $appRoot = dirname(dirname(dirname(dirname(__DIR__)))); require $appRoot . '/app/bootstrap.php'; require __DIR__ . '/../vendor/autoload.php'; -$objectManagerFactory = \Magento\Framework\App\Bootstrap::createObjectManagerFactory(BP, $_SERVER); -$objectManager = $objectManagerFactory->create($_SERVER); -\Mtf\ObjectManagerFactory::configure($objectManager); +$objectManager = \Magento\Mtf\ObjectManagerFactory::getObjectManager(); +\Magento\Mtf\ObjectManagerFactory::configure($objectManager); diff --git a/dev/tests/functional/utils/generate.php b/dev/tests/functional/utils/generate.php index 2e63dcb82aad8c2a041aeb60073b34c56637a936..7aa9b91f0f93971fde2dad50802e15c9c45248f3 100644 --- a/dev/tests/functional/utils/generate.php +++ b/dev/tests/functional/utils/generate.php @@ -5,13 +5,13 @@ */ require_once dirname(__FILE__) . '/' . 'bootstrap.php'; -$objectManager->create('Mtf\Util\Generate\TestCase')->launch(); -$objectManager->create('Mtf\Util\Generate\Page')->launch(); -$objectManager->create('Mtf\Util\Generate\Fixture')->launch(); -$objectManager->create('Mtf\Util\Generate\Constraint')->launch(); -$objectManager->create('Mtf\Util\Generate\Handler')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\TestCase')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\Page')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\Fixture')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\Constraint')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\Handler')->launch(); $objectManager->get('Magento\Framework\App\State')->setAreaCode('frontend'); -$objectManager->create('Mtf\Util\Generate\Repository')->launch(); +$objectManager->create('Magento\Mtf\Util\Generate\Repository')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/constraint.php b/dev/tests/functional/utils/generate/constraint.php index 70b6d73d413e0c3959b0aca031c82926dc9f7ca6..5dfd019f6c17046591a153cb136e0245dac581a3 100644 --- a/dev/tests/functional/utils/generate/constraint.php +++ b/dev/tests/functional/utils/generate/constraint.php @@ -5,5 +5,5 @@ */ require_once dirname(__DIR__) . '/' . 'bootstrap.php'; -$objectManager->create('Mtf\Util\Generate\Constraint')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +$objectManager->create('Magento\Mtf\Util\Generate\Constraint')->launch(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/factory.php b/dev/tests/functional/utils/generate/factory.php index e2bfb6ce2df5c209d3c3ae8022558eb26362233f..05c38495a2d7b9f4cac396ffab2f68bfa1ee7e2b 100644 --- a/dev/tests/functional/utils/generate/factory.php +++ b/dev/tests/functional/utils/generate/factory.php @@ -15,7 +15,7 @@ require MTF_BP . '/vendor/autoload.php'; $bootstrap = \Magento\Framework\App\Bootstrap::create(BP, $_SERVER); $om = $bootstrap->getObjectManager(); -/** @var \Mtf\Util\Generate\Factory $generator */ -$generator = $om->create('Mtf\Util\Generate\Factory'); +/** @var \Magento\Mtf\Util\Generate\Factory $generator */ +$generator = $om->create('Magento\Mtf\Util\Generate\Factory'); $generator->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/fixture.php b/dev/tests/functional/utils/generate/fixture.php index 9d1581309cde7409233aa66c73b7b17e55468199..d2e13c07ba65505ed067bba4faf0e8b3516703dc 100644 --- a/dev/tests/functional/utils/generate/fixture.php +++ b/dev/tests/functional/utils/generate/fixture.php @@ -5,5 +5,5 @@ */ require_once dirname(__DIR__) . '/' . 'bootstrap.php'; -$objectManager->create('Mtf\Util\Generate\Fixture')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +$objectManager->create('Magento\Mtf\Util\Generate\Fixture')->launch(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/handler.php b/dev/tests/functional/utils/generate/handler.php index 147aae10f99b04d0c0033f7844bffa48f1655d9c..2e1b1bc7ef104abc9f6c02a2f6d3e5ead97bd487 100644 --- a/dev/tests/functional/utils/generate/handler.php +++ b/dev/tests/functional/utils/generate/handler.php @@ -5,5 +5,5 @@ */ require_once dirname(__DIR__) . '/' . 'bootstrap.php'; -$objectManager->create('Mtf\Util\Generate\Handler')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +$objectManager->create('Magento\Mtf\Util\Generate\Handler')->launch(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/page.php b/dev/tests/functional/utils/generate/page.php index c4cc602d289fe793d1dd11d82776b1e6a5010ee1..f15e030c24c4336ca032772a599839efcf234068 100644 --- a/dev/tests/functional/utils/generate/page.php +++ b/dev/tests/functional/utils/generate/page.php @@ -4,5 +4,5 @@ * See COPYING.txt for license details. */ require_once dirname(__DIR__) . '/' . 'bootstrap.php'; -$objectManager->create('Mtf\Util\Generate\Page')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +$objectManager->create('Magento\Mtf\Util\Generate\Page')->launch(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/functional/utils/generate/repository.php b/dev/tests/functional/utils/generate/repository.php index 0179cab18c43ec616849e5114656e87cb00c3c01..5355cf45e759663ee3667e38182336f62c9bc524 100644 --- a/dev/tests/functional/utils/generate/repository.php +++ b/dev/tests/functional/utils/generate/repository.php @@ -6,5 +6,5 @@ require_once dirname(__DIR__) . '/' . 'bootstrap.php'; $objectManager->get('Magento\Framework\App\State')->setAreaCode('frontend'); -$objectManager->create('Mtf\Util\Generate\Repository')->launch(); -\Mtf\Util\Generate\GenerateResult::displayResults(); +$objectManager->create('Magento\Mtf\Util\Generate\Repository')->launch(); +\Magento\Mtf\Util\Generate\GenerateResult::displayResults(); diff --git a/dev/tests/integration/testsuite/Magento/Email/Model/TemplateTest.php b/dev/tests/integration/testsuite/Magento/Email/Model/TemplateTest.php index 3344852fa45c5412ff7245095c2a19395a99048e..a1f054261ad1d8963c4614e426c90e3874ceefe0 100644 --- a/dev/tests/integration/testsuite/Magento/Email/Model/TemplateTest.php +++ b/dev/tests/integration/testsuite/Magento/Email/Model/TemplateTest.php @@ -34,7 +34,7 @@ class TemplateTest extends \PHPUnit_Framework_TestCase $objectManager->get('Magento\Framework\Model\Context'), $objectManager->get('Magento\Framework\View\DesignInterface'), $objectManager->get('Magento\Framework\Registry'), - $objectManager->get('Magento\Core\Model\App\Emulation'), + $objectManager->get('Magento\Store\Model\App\Emulation'), $objectManager->get('Magento\Store\Model\StoreManager'), $objectManager->create('Magento\Framework\Filesystem'), $objectManager->create('Magento\Framework\View\Asset\Repository'), diff --git a/dev/tests/integration/testsuite/Magento/Core/Model/Validator/FactoryTest.php b/dev/tests/integration/testsuite/Magento/Framework/Validator/FactoryTest.php similarity index 81% rename from dev/tests/integration/testsuite/Magento/Core/Model/Validator/FactoryTest.php rename to dev/tests/integration/testsuite/Magento/Framework/Validator/FactoryTest.php index eeaaba1172a8bf836b52d8e4dd4bead5f5645de3..2a25d44f2b656b0d6a08d07b1404b11b1557c224 100644 --- a/dev/tests/integration/testsuite/Magento/Core/Model/Validator/FactoryTest.php +++ b/dev/tests/integration/testsuite/Magento/Framework/Validator/FactoryTest.php @@ -1,11 +1,11 @@ <?php /** - * Integration test for \Magento\Core\Model\Validator\Factory + * Integration test for \Magento\Framework\Validator\Factory * * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Magento\Core\Model\Validator; +namespace Magento\Framework\Validator; class FactoryTest extends \PHPUnit_Framework_TestCase { @@ -17,8 +17,8 @@ class FactoryTest extends \PHPUnit_Framework_TestCase public function testGetValidatorConfig() { $objectManager = \Magento\TestFramework\Helper\Bootstrap::getObjectManager(); - /** @var \Magento\Core\Model\Validator\Factory $factory */ - $factory = $objectManager->get('Magento\Core\Model\Validator\Factory'); + /** @var \Magento\Framework\Validator\Factory $factory */ + $factory = $objectManager->get('Magento\Framework\Validator\Factory'); $this->assertInstanceOf('Magento\Framework\Validator\Config', $factory->getValidatorConfig()); // Check that default translator was set $translator = \Magento\Framework\Validator\AbstractValidator::getDefaultTranslator(); diff --git a/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/BlockTest.php b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/BlockTest.php new file mode 100644 index 0000000000000000000000000000000000000000..3bd3e7f3024f1ea9039dd58305c6e1026ce448ca --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/BlockTest.php @@ -0,0 +1,100 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\View\Layout\Reader; + +class BlockTest extends \PHPUnit_Framework_TestCase +{ + const IDX_TYPE = 0; + const IDX_PARENT = 2; + + /** + * @var Block + */ + private $block; + + /** + * @var Context + */ + private $readerContext; + + /** + * @var string + */ + private $blockName = 'test.block'; + + /** + * @var string + */ + private $childBlockName = 'test.child.block'; + + public function setUp() + { + $this->block = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create( + 'Magento\Framework\View\Layout\Reader\Block' + ); + $this->readerContext = \Magento\TestFramework\Helper\Bootstrap::getObjectManager()->create( + 'Magento\Framework\View\Layout\Reader\Context' + ); + } + + public function testInterpretBlockDirective() + { + $pageXml = new \Magento\Framework\View\Layout\Element( + __DIR__ . '/_files/_layout_update_block.xml', 0, true + ); + $parentElement = new \Magento\Framework\View\Layout\Element('<page></page>'); + + foreach ($pageXml->xpath('body/block') as $blockElement) { + $this->assertTrue(in_array($blockElement->getName(), $this->block->getSupportedNodes())); + $this->block->interpret($this->readerContext, $blockElement, $parentElement); + } + + $structure = $this->readerContext->getScheduledStructure(); + $this->assertArrayHasKey($this->blockName, $structure->getStructure()); + $this->assertEquals('block', $structure->getStructure()[$this->blockName][self::IDX_TYPE]); + + $resultElementData = $structure->getStructureElementData($this->blockName); + + $this->assertEquals( + ['group' => 'test.group', 'class' => 'Dummy\Class', 'template' => 'test.phtml', 'ttl' => 3], + $resultElementData['attributes'] + ); + $this->assertEquals( + ['test_arg' => ['name' => 'test_arg', 'xsi:type' => 'string', 'value' => 'test-argument-value']], + $resultElementData['arguments'] + ); + + $this->assertEquals('block', $structure->getStructure()[$this->childBlockName][self::IDX_TYPE]); + $this->assertEquals($this->blockName, $structure->getStructure()[$this->childBlockName][self::IDX_PARENT]); + } + + /** + * @depends testInterpretBlockDirective + */ + public function testInterpretReferenceBlockDirective() + { + $pageXml = new \Magento\Framework\View\Layout\Element( + __DIR__ . '/_files/_layout_update_reference.xml', 0, true + ); + $parentElement = new \Magento\Framework\View\Layout\Element('<page></page>'); + + foreach ($pageXml->xpath('body/*') as $element) { + $this->assertTrue(in_array($element->getName(), $this->block->getSupportedNodes())); + $this->block->interpret($this->readerContext, $element, $parentElement); + } + + $structure = $this->readerContext->getScheduledStructure(); + $this->assertArrayHasKey($this->blockName, $structure->getStructure()); + $this->assertEquals('block', $structure->getStructure()[$this->blockName][self::IDX_TYPE]); + + $resultElementData = $structure->getStructureElementData($this->blockName); + + $this->assertEquals( + ['test_arg' => ['name' => 'test_arg', 'xsi:type' => 'string', 'value' => 'test-argument-value']], + $resultElementData['arguments'] + ); + } +} diff --git a/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_block.xml b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_block.xml new file mode 100644 index 0000000000000000000000000000000000000000..01cf6bf5dd2b399be978afe15cbcf1888e7d1581 --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_block.xml @@ -0,0 +1,17 @@ +<?xml version="1.0"?> +<!-- +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +--> +<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd"> + <body> + <block class="Dummy\Class" name="test.block" group="test.group" template="test.phtml" ttl="3"> + <arguments> + <argument name="test_arg" xsi:type="string">test-argument-value</argument> + </arguments> + <block class="Dummy\Class" name="test.child.block"/> + </block> + </body> +</page> diff --git a/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_reference.xml b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_reference.xml new file mode 100644 index 0000000000000000000000000000000000000000..f25d5cecda8a3d9a3a57f3876eda8dc28c77c686 --- /dev/null +++ b/dev/tests/integration/testsuite/Magento/Framework/View/Layout/Reader/_files/_layout_update_reference.xml @@ -0,0 +1,17 @@ +<?xml version="1.0"?> +<!-- +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +--> +<page xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../../../../../../../../lib/internal/Magento/Framework/View/Layout/etc/page_configuration.xsd"> + <body> + <block class="Dummy\Class" name="test.block"/> + <referenceBlock name="test.block"> + <arguments> + <argument name="test_arg" xsi:type="string">test-argument-value</argument> + </arguments> + </referenceBlock> + </body> +</page> diff --git a/dev/tests/integration/testsuite/Magento/Core/Model/App/EmulationTest.php b/dev/tests/integration/testsuite/Magento/Store/Model/App/EmulationTest.php similarity index 75% rename from dev/tests/integration/testsuite/Magento/Core/Model/App/EmulationTest.php rename to dev/tests/integration/testsuite/Magento/Store/Model/App/EmulationTest.php index 6bd0071e9409f9d301de908f5137e8f1e084a735..d374b8cea90345fe3f13f7765fb2d1bf42133327 100644 --- a/dev/tests/integration/testsuite/Magento/Core/Model/App/EmulationTest.php +++ b/dev/tests/integration/testsuite/Magento/Store/Model/App/EmulationTest.php @@ -3,23 +3,23 @@ * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Magento\Core\Model\App; +namespace Magento\Store\Model\App; class EmulationTest extends \PHPUnit_Framework_TestCase { /** - * @var \Magento\Core\Model\App\Emulation + * @var \Magento\Store\Model\App\Emulation */ protected $_model; /** - * @covers \Magento\Core\Model\App\Emulation::startEnvironmentEmulation - * @covers \Magento\Core\Model\App\Emulation::stopEnvironmentEmulation + * @covers \Magento\Store\Model\App\Emulation::startEnvironmentEmulation + * @covers \Magento\Store\Model\App\Emulation::stopEnvironmentEmulation */ public function testEnvironmentEmulation() { $this->_model = \Magento\TestFramework\Helper\Bootstrap::getObjectManager() - ->create('Magento\Core\Model\App\Emulation'); + ->create('Magento\Store\Model\App\Emulation'); \Magento\TestFramework\Helper\Bootstrap::getInstance() ->loadArea(\Magento\Backend\App\Area\FrontNameResolver::AREA_CODE); $design = \Magento\TestFramework\Helper\Bootstrap::getObjectManager() diff --git a/dev/tests/integration/testsuite/Magento/TaxImportExport/Model/Rate/CsvImportHandlerTest.php b/dev/tests/integration/testsuite/Magento/TaxImportExport/Model/Rate/CsvImportHandlerTest.php index de8fa89724500d947fec6e2d01fe3f121863aa40..465309edf17721e36d7caaadbdba747d587f736f 100644 --- a/dev/tests/integration/testsuite/Magento/TaxImportExport/Model/Rate/CsvImportHandlerTest.php +++ b/dev/tests/integration/testsuite/Magento/TaxImportExport/Model/Rate/CsvImportHandlerTest.php @@ -8,7 +8,7 @@ namespace Magento\TaxImportExport\Model\Rate; class CsvImportHandlerTest extends \PHPUnit_Framework_TestCase { /** - * @var \Magento\Tax\Model\Rate\CsvImportHandler + * @var \Magento\TaxImportExport\Model\Rate\CsvImportHandler */ protected $_importHandler; diff --git a/dev/tests/static/testsuite/Magento/Test/Integrity/ComposerTest.php b/dev/tests/static/testsuite/Magento/Test/Integrity/ComposerTest.php new file mode 100644 index 0000000000000000000000000000000000000000..97039e891351231f60d6c028e57585596dfd78aa --- /dev/null +++ b/dev/tests/static/testsuite/Magento/Test/Integrity/ComposerTest.php @@ -0,0 +1,439 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Test\Integrity; + +use Magento\Framework\Composer\MagentoComponent; +use Magento\Framework\Test\Utility\Files; +use Magento\Framework\Shell; +use Magento\Framework\Exception; + +/** + * A test that enforces validity of composer.json files and any other conventions in Magento components + */ +class ComposerTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\Framework\Shell + */ + private static $shell; + + /** + * @var bool + */ + private static $isComposerAvailable; + + /** + * @var string + */ + private static $root; + + /** + * @var \stdClass + */ + private static $rootJson; + + /** + * @var array + */ + private static $dependencies; + + /** + * @var string + */ + private static $composerPath = 'composer'; + + public static function setUpBeforeClass() + { + if (defined('TESTS_COMPOSER_PATH')) { + self::$composerPath = TESTS_COMPOSER_PATH; + } + self::$shell = self::createShell(); + self::$isComposerAvailable = self::isComposerAvailable(); + self::$root = Files::init()->getPathToSource(); + self::$rootJson = json_decode(file_get_contents(self::$root . '/composer.json'), true); + self::$dependencies = []; + } + + public function testValidComposerJson() + { + $invoker = new \Magento\Framework\Test\Utility\AggregateInvoker($this); + $invoker( + /** + * @param string $dir + * @param string $packageType + */ + function ($dir, $packageType) { + $this->assertComposerAvailable(); + $file = $dir . '/composer.json'; + $this->assertFileExists($file); + self::$shell->execute(self::$composerPath . ' validate --working-dir=%s', [$dir]); + $contents = file_get_contents($file); + $json = json_decode($contents); + $this->assertCodingStyle($contents); + $this->assertMagentoConventions($dir, $packageType, $json); + }, + $this->validateComposerJsonDataProvider() + ); + } + + /** + * @return array + */ + public function validateComposerJsonDataProvider() + { + $root = \Magento\Framework\Test\Utility\Files::init()->getPathToSource(); + $result = []; + foreach (glob("{$root}/app/code/Magento/*", GLOB_ONLYDIR) as $dir) { + $result[$dir] = [$dir, 'magento2-module']; + } + foreach (glob("{$root}/app/i18n/magento/*", GLOB_ONLYDIR) as $dir) { + $result[$dir] = [$dir, 'magento2-language']; + } + foreach (glob("{$root}/app/design/adminhtml/Magento/*", GLOB_ONLYDIR) as $dir) { + $result[$dir] = [$dir, 'magento2-theme']; + } + foreach (glob("{$root}/app/design/frontend/Magento/*", GLOB_ONLYDIR) as $dir) { + $result[$dir] = [$dir, 'magento2-theme']; + } + foreach (glob("{$root}/lib/internal/Magento/*", GLOB_ONLYDIR) as $dir) { + $result[$dir] = [$dir, 'magento2-library']; + } + $result[$root] = [$root, 'project']; + + return $result; + } + + /** + * Some of coding style conventions + * + * @param string $contents + */ + private function assertCodingStyle($contents) + { + $this->assertNotRegExp('/" :\s*["{]/', $contents, 'Coding style: no space before colon.'); + $this->assertNotRegExp('/":["{]/', $contents, 'Coding style: a space is necessary after colon.'); + } + + /** + * Enforce Magento-specific conventions to a composer.json file + * + * @param string $dir + * @param string $packageType + * @param \StdClass $json + * @throws \InvalidArgumentException + */ + private function assertMagentoConventions($dir, $packageType, \StdClass $json) + { + $this->assertObjectHasAttribute('name', $json); + $this->assertObjectHasAttribute('license', $json); + $this->assertObjectHasAttribute('type', $json); + $this->assertObjectHasAttribute('version', $json); + $this->assertVersionInSync($json->name, $json->version); + $this->assertObjectHasAttribute('require', $json); + $this->assertEquals($packageType, $json->type); + if ($packageType !== 'project') { + self::$dependencies[] = $json->name; + $this->assertHasMap($json); + $this->assertMapConsistent($dir, $json); + } + switch ($packageType) { + case 'magento2-module': + $xml = simplexml_load_file("$dir/etc/module.xml"); + $this->assertConsistentModuleName($xml, $json->name); + $this->assertDependsOnPhp($json->require); + $this->assertDependsOnFramework($json->require); + $this->assertDependsOnInstaller($json->require); + $this->assertRequireInSync($json); + break; + case 'magento2-language': + $this->assertRegExp('/^magento\/language\-[a-z]{2}_[a-z]{2}$/', $json->name); + $this->assertDependsOnFramework($json->require); + $this->assertDependsOnInstaller($json->require); + $this->assertRequireInSync($json); + break; + case 'magento2-theme': + $this->assertRegExp('/^magento\/theme-(?:adminhtml|frontend)(\-[a-z0-9_]+)+$/', $json->name); + $this->assertDependsOnPhp($json->require); + $this->assertDependsOnFramework($json->require); + $this->assertDependsOnInstaller($json->require); + $this->assertRequireInSync($json); + break; + case 'magento2-library': + $this->assertDependsOnPhp($json->require); + $this->assertRegExp('/^magento\/framework$/', $json->name); + $this->assertDependsOnInstaller($json->require); + $this->assertRequireInSync($json); + break; + case 'project': + sort(self::$dependencies); + $dependenciesListed = []; + foreach (array_keys((array)self::$rootJson['replace']) as $key) { + if (MagentoComponent::matchMagentoComponent($key)) { + $dependenciesListed[] = $key; + } + } + sort($dependenciesListed); + $nonDeclaredDependencies = array_diff(self::$dependencies, $dependenciesListed); + $nonexistentDependencies = array_diff($dependenciesListed, self::$dependencies); + $this->assertEmpty( + $nonDeclaredDependencies, + 'Following dependencies are not declared in the root composer.json: ' + . join(', ', $nonDeclaredDependencies) + ); + $this->assertEmpty( + $nonexistentDependencies, + 'Following dependencies declared in the root composer.json do not exist: ' + . join(', ', $nonexistentDependencies) + ); + break; + default: + throw new \InvalidArgumentException("Unknown package type {$packageType}"); + } + } + + /** + * Assert that there is map in specified composer json + * + * @param \StdClass $json + */ + private function assertHasMap(\StdClass $json) + { + $error = 'There must be an "extra->map" node in composer.json of each Magento component.'; + $this->assertObjectHasAttribute('extra', $json, $error); + $this->assertObjectHasAttribute('map', $json->extra, $error); + $this->assertInternalType('array', $json->extra->map, $error); + } + + /** + * Assert that component directory name and mapping information are consistent + * + * @param string $dir + * @param \StdClass $json + */ + private function assertMapConsistent($dir, $json) + { + preg_match('/^.+\/(.+)\/(.+)$/', $dir, $matches); + list(, $vendor, $name) = $matches; + $map = $json->extra->map; + $this->assertArrayHasKey(0, $map); + $this->assertArrayHasKey(1, $map[0]); + $this->assertRegExp( + "/{$vendor}\\/{$name}$/", + $map[0][1], + 'Mapping info is inconsistent with the directory structure' + ); + } + + /** + * Enforce package naming conventions for modules + * + * @param \SimpleXMLElement $xml + * @param string $packageName + */ + private function assertConsistentModuleName(\SimpleXMLElement $xml, $packageName) + { + $moduleName = (string)$xml->module->attributes()->name; + $this->assertEquals( + $packageName, + $this->convertModuleToPackageName($moduleName), + "For the module '{$moduleName}', the expected package name is '{$packageName}'" + ); + } + + /** + * Make sure a component depends on php version + * + * @param \StdClass $json + */ + private function assertDependsOnPhp(\StdClass $json) + { + $this->assertObjectHasAttribute('php', $json, 'This component is expected to depend on certain PHP version(s)'); + } + + /** + * Make sure a component depends on magento/framework component + * + * @param \StdClass $json + */ + private function assertDependsOnFramework(\StdClass $json) + { + $this->assertObjectHasAttribute( + 'magento/framework', + $json, + 'This component is expected to depend on magento/framework' + ); + } + + /** + * Make sure a component depends on Magento Composer Installer component + * + * @param \StdClass $json + */ + private function assertDependsOnInstaller(\StdClass $json) + { + $this->assertObjectHasAttribute( + 'magento/magento-composer-installer', + $json, + 'This component is expected to depend on magento/magento-composer-installer' + ); + } + + /** + * Assert that versions in root composer.json and Magento component's composer.json are not out of sync + * + * @param string $name + * @param string $version + */ + private function assertVersionInSync($name, $version) + { + $this->assertEquals( + self::$rootJson['version'], + $version, + "Version {$version} in component {$name} is inconsistent with version " + . self::$rootJson['version'] . ' in root composer.json' + ); + } + + /** + * Make sure requirements of components are reflected in root composer.json + * + * @param \StdClass $json + */ + private function assertRequireInSync(\StdClass $json) + { + $name = $json->name; + if (isset($json->require)) { + $errors = []; + foreach (array_keys((array)$json->require) as $depName) { + if ($depName == 'magento/magento-composer-installer') { + // Magento Composer Installer is not needed for already existing components + continue; + } + if (!isset(self::$rootJson['require-dev'][$depName]) && !isset(self::$rootJson['require'][$depName]) + && !isset(self::$rootJson['replace'][$depName])) { + $errors[] = "'$name' depends on '$depName'"; + } + } + if (!empty($errors)) { + $this->fail( + "The following dependencies are missing in root 'composer.json'," + . " while declared in child components.\n" + . "Consider adding them to 'require-dev' section (if needed for child components only)," + . " to 'replace' section (if they are present in the project)," + . " to 'require' section (if needed for the skeleton).\n" + . join("\n", $errors) + ); + } + } + } + + /** + * Convert a fully qualified module name to a composer package name according to conventions + * + * @param string $moduleName + * @return string + */ + private function convertModuleToPackageName($moduleName) + { + list($vendor, $name) = explode('_', $moduleName, 2); + $package = 'module'; + foreach (preg_split('/([A-Z][a-z\d]+)/', $name, -1, PREG_SPLIT_DELIM_CAPTURE) as $chunk) { + $package .= $chunk ? "-{$chunk}" : ''; + } + return strtolower("{$vendor}/{$package}"); + } + + /** + * Create shell wrapper + * + * @return \Magento\Framework\Shell + */ + private static function createShell() + { + return new Shell(new Shell\CommandRenderer, null); + } + + /** + * Check if composer command is available in the environment + * + * @return bool + */ + private static function isComposerAvailable() + { + try { + self::$shell->execute(self::$composerPath . ' --version'); + } catch (Exception $e) { + return false; + } + return true; + } + + /** + * Skip the test if composer is unavailable + */ + private function assertComposerAvailable() + { + if (!self::$isComposerAvailable) { + $this->markTestSkipped(); + } + } + + public function testComponentPathsInRoot() + { + if (!isset(self::$rootJson['extra']) || !isset(self::$rootJson['extra']['component_paths'])) { + $this->markTestSkipped("The root composer.json file doesn't mention any extra component paths information"); + } + $this->assertArrayHasKey( + 'replace', + self::$rootJson, + "If there are any component paths specified, then they must be reflected in 'replace' section" + ); + $flat = $this->getFlatPathsInfo(self::$rootJson['extra']['component_paths']); + while (list(, list($component, $path)) = each($flat)) { + $this->assertFileExists( + self::$root . '/' . $path, + "Missing or invalid component path: {$component} -> {$path}" + ); + $this->assertArrayHasKey( + $component, + self::$rootJson['replace'], + "The {$component} is specified in 'extra->component_paths', but missing in 'replace' section" + ); + } + foreach (array_keys(self::$rootJson['replace']) as $replace) { + if (!MagentoComponent::matchMagentoComponent($replace)) { + $this->assertArrayHasKey( + $replace, + self::$rootJson['extra']['component_paths'], + "The {$replace} is specified in 'replace', but missing in 'extra->component_paths' section" + ); + } + } + } + + /** + * @param array $info + * @return array + * @throws \Exception + */ + private function getFlatPathsInfo(array $info) + { + $flat = []; + foreach ($info as $key => $element) { + if (is_string($element)) { + $flat[] = [$key, $element]; + } elseif (is_array($element)) { + foreach ($element as $path) { + $flat[] = [$key, $path]; + } + } else { + throw new \Exception("Unexpected element 'in extra->component_paths' section"); + } + } + + return $flat; + } +} diff --git a/dev/tests/static/testsuite/Magento/Test/Integrity/_files/blacklist/reference.txt b/dev/tests/static/testsuite/Magento/Test/Integrity/_files/blacklist/reference.txt index c6bac2ba9f3b3dd5970b717f88acea5427bb38bb..29a6687221a578eec95394ebb2161c46ceba331f 100644 --- a/dev/tests/static/testsuite/Magento/Test/Integrity/_files/blacklist/reference.txt +++ b/dev/tests/static/testsuite/Magento/Test/Integrity/_files/blacklist/reference.txt @@ -51,3 +51,17 @@ Model3 \Magento\TestModule2\Service\V1\Entity\ItemBuilder \Magento\TestModule4\Service\V1\Entity\DataObjectResponse \Magento\TestModule4\Service\V1\Entity\DataObjectRequest +\Magento\Mtf\ObjectManager\Config\Mapper\Dom +\Magento\Mtf\Data\Argument\Interpreter\Constant +\Magento\Mtf\Data\Argument\Interpreter\Boolean +\Magento\Mtf\Data\Argument\Interpreter\String +\Magento\Mtf\Data\Argument\Interpreter\Number +\Magento\Mtf\Data\Argument\Interpreter\NullType +\Magento\Mtf\Data\Argument\Interpreter\Object +\Magento\Mtf\Data\Argument\Interpreter\Argument +\Magento\Mtf\Data\Argument\Interpreter\ArrayType +\Magento\Mtf\Data\Argument\InterpreterInterface +\Magento\Mtf\Util\Generate\GenerateResult +\Magento\Mtf\Util\Generate\Repository\Resource +\Magento\Mtf\Client\Element +\Magento\Mtf\TestSuite\AppState \ No newline at end of file diff --git a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_classes.php b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_classes.php index 50c4be7bfcaccea0ba7e01ab0070c4c669a2ab84..f12e7d360fea297c329082f978afe83b0d77d3db 100644 --- a/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_classes.php +++ b/dev/tests/static/testsuite/Magento/Test/Legacy/_files/obsolete_classes.php @@ -1302,6 +1302,7 @@ return [ ['Magento\Core\Controller\Varien\DispatchableInterface'], ['Magento\Core\Controller\Varien\Front', 'Magento\Framework\App\FrontController'], ['Magento\Core\Controller\FrontInterface', 'Magento\Framework\App\FrontControllerInterface'], + ['Magento\Core\Model\App\Emulation', 'Magento\Store\Model\App\Emulation'], ['Magento\Core\Model\App\Handler'], ['Magento\Core\Model\App\Proxy'], ['Magento\Core\Model\Event\Config\SchemaLocator', 'Magento\Framework\Event\Config\SchemaLocator'], @@ -2853,4 +2854,5 @@ return [ ['Magento\Sales\Model\Quote\Address\Total\Nominal\Collector'], ['Magento\Sales\Model\Quote\Address\Total\Nominal\Shipping'], ['Magento\Sales\Model\Quote\Address\Total\Nominal\Subtotal'], + ['Magento\Core\Model\Validator\Factory', 'Magento\Framework\Validator\Factory'], ]; diff --git a/dev/tests/unit/testsuite/Magento/Catalog/Model/ProductTest.php b/dev/tests/unit/testsuite/Magento/Catalog/Model/ProductTest.php index 5706d834dfd2a4cade0a9fcc91a5d2c8ab2ca29f..67628ef7ea3e5859626d039be8a1cb3b8f1c42d0 100644 --- a/dev/tests/unit/testsuite/Magento/Catalog/Model/ProductTest.php +++ b/dev/tests/unit/testsuite/Magento/Catalog/Model/ProductTest.php @@ -424,10 +424,16 @@ class ProductTest extends \PHPUnit_Framework_TestCase */ public function testSetQty() { - $this->productTypeInstanceMock->expects($this->once()) + $this->productTypeInstanceMock->expects($this->exactly(2)) ->method('getPriceInfo') ->with($this->equalTo($this->model)) ->will($this->returnValue($this->_priceInfoMock)); + + //initialize the priceInfo field + $this->model->getPriceInfo(); + //Calling setQty will reset the priceInfo field + $this->assertEquals($this->model, $this->model->setQty(1)); + //Call the setQty method with the same qty, getPriceInfo should not be called this time $this->assertEquals($this->model, $this->model->setQty(1)); $this->assertEquals($this->model->getPriceInfo(), $this->_priceInfoMock); } diff --git a/dev/tests/unit/testsuite/Magento/Checkout/Controller/Cart/ConfigureTest.php b/dev/tests/unit/testsuite/Magento/Checkout/Controller/Cart/ConfigureTest.php new file mode 100644 index 0000000000000000000000000000000000000000..716661bd022b1c8f81e0fa397bb1bf4f48ae5232 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/Checkout/Controller/Cart/ConfigureTest.php @@ -0,0 +1,250 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Checkout\Controller\Cart; + +/** + * Shopping cart edit tests + */ +class ConfigureTest extends \PHPUnit_Framework_TestCase +{ + + /** + * @var \Magento\Framework\ObjectManagerInterface | \PHPUnit_Framework_MockObject_MockObject + */ + protected $objectManagerMock; + + /** + * @var \Magento\Framework\View\Result\PageFactory | \PHPUnit_Framework_MockObject_MockObject + */ + protected $resultPageFactoryMock; + + /** + * @var \Magento\Framework\App\ResponseInterface | \PHPUnit_Framework_MockObject_MockObject + */ + protected $responseMock; + + /** + * @var \Magento\Framework\App\RequestInterface | \PHPUnit_Framework_MockObject_MockObject + */ + protected $requestMock; + + /** + * @var \Magento\Framework\Message\ManagerInterface | \PHPUnit_Framework_MockObject_MockObject + */ + protected $messageManagerMock; + + /** + * @var \Magento\Framework\App\Response\RedirectInterface | \PHPUnit_Framework_MockObject_MockObject + */ + protected $redirectMock; + + /** + * @var \Magento\Checkout\Controller\Cart\Configure | \PHPUnit_Framework_MockObject_MockObject + */ + protected $configureController; + + /** + * @var \Magento\Framework\App\Action\Context | \PHPUnit_Framework_MockObject_MockObject + */ + protected $contextMock; + + /** + * @var \Magento\Checkout\Model\Cart | \PHPUnit_Framework_MockObject_MockObject + */ + protected $cartMock; + + public function setUp() + { + $eventManagerMock = $this->getMockBuilder('Magento\Framework\Event\ManagerInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $urlMock = $this->getMockBuilder('Magento\Framework\UrlInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $actionFlagMock = $this->getMockBuilder('Magento\Framework\App\ActionFlag') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $viewMock = $this->getMockBuilder('Magento\Framework\App\ViewInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $this->objectManagerMock = $this->getMockBuilder('Magento\Framework\ObjectManagerInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $this->responseMock = $this->getMockBuilder('Magento\Framework\App\ResponseInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $this->requestMock = $this->getMockBuilder('Magento\Framework\App\RequestInterface') + ->disableOriginalConstructor() + ->setMethods(['getParam']) + ->getMockForAbstractClass(); + $this->messageManagerMock = $this->getMockBuilder('Magento\Framework\Message\ManagerInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMockForAbstractClass(); + $this->redirectMock = $this->getMockBuilder('Magento\Framework\App\Response\RedirectInterface') + ->disableOriginalConstructor() + ->setMethods([]) + ->getMock(); + + $this->contextMock = $this->getMockBuilder('Magento\Framework\App\Action\Context') + ->setConstructorArgs( + [ + $this->requestMock, + $this->responseMock, + $this->objectManagerMock, + $eventManagerMock, + $urlMock, + $this->redirectMock, + $actionFlagMock, + $viewMock, + $this->messageManagerMock + ] + ) + ->setMethods([]) + ->getMock(); + $this->contextMock->expects($this->any())->method('getObjectManager')->willReturn($this->objectManagerMock); + $this->contextMock->expects($this->any())->method('getRequest')->willReturn($this->requestMock); + $this->contextMock->expects($this->any())->method('getResponse')->willReturn($this->responseMock); + $this->contextMock->expects($this->any())->method('getMessageManager')->willReturn($this->messageManagerMock); + $this->contextMock->expects($this->any())->method('getRedirect')->willReturn($this->redirectMock); + $scopeConfig = $this->getMockBuilder('Magento\Framework\App\Config\ScopeConfigInterface') + ->disableOriginalConstructor() + ->getMock(); + $session = $this->getMockBuilder('Magento\Checkout\Model\Session') + ->disableOriginalConstructor() + ->getMock(); + $storeManager = $this->getMockBuilder('Magento\Store\Model\StoreManagerInterface') + ->disableOriginalConstructor() + ->getMockForAbstractClass(); + $formKeyValidator = $this->getMockBuilder('Magento\Core\App\Action\FormKeyValidator') + ->disableOriginalConstructor() + ->getMockForAbstractClass(); + $this->cartMock = $this->getMockBuilder('Magento\Checkout\Model\Cart') + ->disableOriginalConstructor() + ->getMock(); + $this->resultPageFactoryMock = $this->getMockBuilder('Magento\Framework\View\Result\PageFactory') + ->disableOriginalConstructor() + ->getMock(); + + $this->configureController = new \Magento\Checkout\Controller\Cart\Configure( + $this->contextMock, + $scopeConfig, + $session, + $storeManager, + $formKeyValidator, + $this->cartMock, + $this->resultPageFactoryMock + ); + } + + /** + * Test checks controller call product view and send parameter to it + * + * @return void + */ + public function testPrepareAndRenderCall() + { + $quoteId = 1; + $actualProductId = 1; + $quoteMock = $this->getMockBuilder('Magento\Quote\Model\Quote') + ->disableOriginalConstructor() + ->getMock(); + $quoteItemMock = $this->getMockBuilder('Magento\Quote\Model\Quote\Item') + ->disableOriginalConstructor() + ->getMock(); + $productMock = $this->getMockBuilder('Magento\Catalog\Model\Product') + ->disableOriginalConstructor() + ->getMock(); + $viewMock = $this->getMockBuilder('Magento\Catalog\Helper\Product\View') + ->disableOriginalConstructor() + ->getMock(); + $pageMock = $this->getMockBuilder('Magento\Framework\View\Result\Page') + ->disableOriginalConstructor() + ->getMock(); + $buyRequestMock = $this->getMockBuilder('Magento\Framework\Object') + ->disableOriginalConstructor() + ->getMock(); + //expects + $this->requestMock->expects($this->at(0)) + ->method('getParam') + ->with('id') + ->willReturn($quoteId); + $this->requestMock->expects($this->at(1)) + ->method('getParam') + ->with('product_id') + ->willReturn($actualProductId); + $this->cartMock->expects($this->any())->method('getQuote')->willReturn($quoteMock); + + $quoteItemMock->expects($this->exactly(1))->method('getBuyRequest')->willReturn($buyRequestMock); + + $this->resultPageFactoryMock->expects($this->once())->method('create')->willReturn($pageMock); + $this->objectManagerMock->expects($this->at(0)) + ->method('get') + ->with('Magento\Catalog\Helper\Product\View') + ->willReturn($viewMock); + + $viewMock->expects($this->once())->method('prepareAndRender')->with( + $pageMock, + $actualProductId, + $this->configureController, + $this->callback( + function ($subject) use ($buyRequestMock) { + return $subject->getBuyRequest() === $buyRequestMock; + } + ) + )->willReturn($pageMock); + + $quoteMock->expects($this->once())->method('getItemById')->willReturn($quoteItemMock); + $quoteItemMock->expects($this->exactly(2))->method('getProduct')->willReturn($productMock); + + $productMock->expects($this->exactly(2))->method('getId')->willReturn($actualProductId); + + $this->assertSame($pageMock, $this->configureController->execute()); + } + + /** + * Test checks controller redirect user to cart + * if user request product id in cart edit page is not same as quota product id + * + * @return void + */ + public function testRedirectWithWrongProductId() + { + $quotaId = 1; + $productIdInQuota = 1; + $productIdInRequest = null; + $quoteItemMock = $this->getMockBuilder('Magento\Quote\Model\Quote\Item') + ->disableOriginalConstructor() + ->getMock(); + $quoteMock = $this->getMockBuilder('Magento\Quote\Model\Quote') + ->disableOriginalConstructor() + ->getMock(); + $productMock = $this->getMockBuilder('Magento\Catalog\Model\Product') + ->disableOriginalConstructor() + ->getMock(); + $this->requestMock->expects($this->at(0)) + ->method('getParam') + ->with('id') + ->willReturn($quotaId); + $this->requestMock->expects($this->at(1)) + ->method('getParam') + ->with('product_id') + ->willReturn($productIdInRequest); + $this->cartMock->expects($this->any())->method('getQuote')->willReturn($quoteMock); + $quoteMock->expects($this->once())->method('getItemById')->willReturn($quoteItemMock); + $quoteItemMock->expects($this->exactly(1))->method('getProduct')->willReturn($productMock); + $productMock->expects($this->exactly(1))->method('getId')->willReturn($productIdInQuota); + $this->messageManagerMock->expects($this->once())->method('addError'); + $this->redirectMock->expects($this->once())->method('redirect')->with($this->responseMock, 'checkout/cart', []); + $this->configureController->execute(); + } +} diff --git a/dev/tests/unit/testsuite/Magento/Customer/Model/Resource/AddressTest.php b/dev/tests/unit/testsuite/Magento/Customer/Model/Resource/AddressTest.php index f87981471b7ae6cef2451d916fca40edbb119ed4..ef3eadbebd0f669cbd7698571044358fe5c16e8c 100644 --- a/dev/tests/unit/testsuite/Magento/Customer/Model/Resource/AddressTest.php +++ b/dev/tests/unit/testsuite/Magento/Customer/Model/Resource/AddressTest.php @@ -230,7 +230,7 @@ class AddressTest extends \PHPUnit_Framework_TestCase /** * Prepare validator mock object * - * @return \Magento\Core\Model\Validator\Factory|\PHPUnit_Framework_MockObject_MockObject + * @return \Magento\Framework\Validator\Factory|\PHPUnit_Framework_MockObject_MockObject */ protected function prepareValidatorFactory() { @@ -240,7 +240,7 @@ class AddressTest extends \PHPUnit_Framework_TestCase ->willReturn(true); $validatorFactory = $this->getMock( - 'Magento\Core\Model\Validator\Factory', + 'Magento\Framework\Validator\Factory', ['createValidator'], [], '', diff --git a/dev/tests/unit/testsuite/Magento/Email/Model/TemplateTest.php b/dev/tests/unit/testsuite/Magento/Email/Model/TemplateTest.php index 7ff2358c4f2418b84133c905af8d97a756a2532c..f63b91e5ea668c01c7e135ebc1affea073fc133f 100644 --- a/dev/tests/unit/testsuite/Magento/Email/Model/TemplateTest.php +++ b/dev/tests/unit/testsuite/Magento/Email/Model/TemplateTest.php @@ -30,7 +30,7 @@ class TemplateTest extends \PHPUnit_Framework_TestCase $this->getMock('Magento\Framework\Model\Context', [], [], '', false), $this->getMock('Magento\Core\Model\View\Design', [], [], '', false), $this->getMock('Magento\Framework\Registry', [], [], '', false), - $this->getMock('Magento\Core\Model\App\Emulation', [], [], '', false), + $this->getMock('Magento\Store\Model\App\Emulation', [], [], '', false), $this->getMock('Magento\Store\Model\StoreManager', [], [], '', false), $this->getMock('Magento\Framework\Filesystem', [], [], '', false), $this->getMock('Magento\Framework\View\Asset\Repository', [], [], '', false), diff --git a/dev/tests/unit/testsuite/Magento/Framework/App/View/Asset/PublisherTest.php b/dev/tests/unit/testsuite/Magento/Framework/App/View/Asset/PublisherTest.php index 4b3658be21981a6966f106cddeb526eee19a55ea..6d5c40ea63d013761e9fe36364cee1db4d29c641 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/App/View/Asset/PublisherTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/App/View/Asset/PublisherTest.php @@ -7,6 +7,7 @@ namespace Magento\Framework\App\View\Asset; use Magento\Framework\App\Filesystem\DirectoryList; +use Magento\Framework\Filesystem\DriverPool; class PublisherTest extends \PHPUnit_Framework_TestCase { @@ -56,8 +57,8 @@ class PublisherTest extends \PHPUnit_Framework_TestCase $this->filesystem->expects($this->any()) ->method('getDirectoryWrite') ->will($this->returnValueMap([ - [DirectoryList::ROOT, $this->rootDirWrite], - [DirectoryList::STATIC_VIEW, $this->staticDirWrite], + [DirectoryList::ROOT, DriverPool::FILE, $this->rootDirWrite], + [DirectoryList::STATIC_VIEW, DriverPool::FILE, $this->staticDirWrite], ])); } diff --git a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/Directory/ReadTest.php b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/Directory/ReadTest.php index b84c08e9a72c529606b33a3d4fdf4a857700222c..640724c6bb59081771f676b8a4bc27cf35985b90 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/Directory/ReadTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/Directory/ReadTest.php @@ -77,7 +77,7 @@ class ReadTest extends \PHPUnit_Framework_TestCase $this->assertEquals(['some-stat-data'], $this->read->stat('correct-path')); } - public function testReadFileNoProtocol() + public function testReadFile() { $path = 'filepath'; $flag = 'flag'; @@ -95,32 +95,4 @@ class ReadTest extends \PHPUnit_Framework_TestCase $this->assertEquals($contents, $this->read->readFile($path, $flag, $context)); } - - public function testReadFileCustomProtocol() - { - $path = 'filepath'; - $flag = 'flag'; - $context = 'context'; - $protocol = 'ftp'; - $contents = 'contents'; - - $fileMock = $this->getMock('Magento\Framework\Filesystem\File\Read', [], [], '', false); - $fileMock->expects($this->once()) - ->method('readAll') - ->with($flag, $context) - ->will($this->returnValue($contents)); - - $this->driver->expects($this->once()) - ->method('getAbsolutePath') - ->with($this->path, $path, $protocol) - ->will($this->returnValue($path)); - $this->driver->expects($this->never()) - ->method('fileGetContents'); - $this->fileFactory->expects($this->once()) - ->method('create') - ->with($path, $protocol, $this->driver) - ->will($this->returnValue($fileMock)); - - $this->assertEquals($contents, $this->read->readFile($path, $flag, $context, $protocol)); - } } diff --git a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/ReadFactoryTest.php b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/ReadFactoryTest.php index f41817b6cf3c459859461727f6362df7ece8599c..41f52ea79834c3be4f8369397fb79afebf2e50c5 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/ReadFactoryTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/ReadFactoryTest.php @@ -12,45 +12,25 @@ use Magento\Framework\Filesystem\DriverPool; */ class ReadFactoryTest extends \PHPUnit_Framework_TestCase { - /** - * @param string|null $protocol - * @param \PHPUnit_Framework_MockObject_MockObject|null $driver - * @dataProvider createProvider - */ - public function testCreate($protocol, $driver) + public function testCreate() { $driverPool = $this->getMock('Magento\Framework\Filesystem\DriverPool', ['getDriver']); - if ($protocol) { - $driverMock = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); - $driverMock->expects($this->any())->method('isExists')->willReturn(true); - $driverPool->expects($this->once())->method('getDriver')->willReturn($driverMock); - } else { - $driverPool->expects($this->never())->method('getDriver'); - } - $factory = new ReadFactory($driverPool); - $result = $factory->create('path', $protocol, $driver); - $this->assertInstanceOf('Magento\Framework\Filesystem\File\Read', $result); - } - - /** - * @return array - */ - public function createProvider() - { + $driverPool->expects($this->never())->method('getDriver'); $driver = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); $driver->expects($this->any())->method('isExists')->willReturn(true); - return [ - [null, $driver], - ['custom_protocol', null] - ]; + $factory = new ReadFactory($driverPool); + $result = $factory->create('path', $driver); + $this->assertInstanceOf('Magento\Framework\Filesystem\File\Read', $result); } - /** - * @expectedException \InvalidArgumentException - */ - public function testCreateException() + public function testCreateWithDriverCode() { - $factory = new ReadFactory(new DriverPool()); - $factory->create('path'); + $driverPool = $this->getMock('Magento\Framework\Filesystem\DriverPool', ['getDriver']); + $driverMock = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); + $driverMock->expects($this->any())->method('isExists')->willReturn(true); + $driverPool->expects($this->once())->method('getDriver')->willReturn($driverMock); + $factory = new ReadFactory($driverPool); + $result = $factory->create('path', 'driverCode'); + $this->assertInstanceOf('Magento\Framework\Filesystem\File\Read', $result); } } diff --git a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/WriteFactoryTest.php b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/WriteFactoryTest.php index 256dbf1a7c36cafa19e4e23d17d24bc0c32cf341..bd9c483346ecffd4cc09b1a63e7dd55f2c6d9a03 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/WriteFactoryTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Filesystem/File/WriteFactoryTest.php @@ -5,63 +5,41 @@ */ namespace Magento\Framework\Filesystem\File; -use Magento\Framework\Filesystem\DriverPool; - /** * Class WriteFactoryTest */ class WriteFactoryTest extends \PHPUnit_Framework_TestCase { - /** - * @param string|null $protocol - * @param \PHPUnit_Framework_MockObject_MockObject|null $driver - * @dataProvider createProvider - */ - public function testCreate($protocol, $driver) + public function testCreate() { $driverPool = $this->getMock('Magento\Framework\Filesystem\DriverPool', ['getDriver']); - if ($protocol) { - $driverMock = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); - $driverMock->expects($this->any())->method('isExists')->willReturn(true); - $driverPool->expects($this->once())->method('getDriver')->willReturn($driverMock); - } else { - $driverPool->expects($this->never())->method('getDriver'); - } + $driverPool->expects($this->never())->method('getDriver'); $factory = new WriteFactory($driverPool); - $result = $factory->create('path', $protocol, $driver); - $this->assertInstanceOf('Magento\Framework\Filesystem\File\Write', $result); - } - - /** - * @return array - */ - public function createProvider() - { $driver = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); $driver->expects($this->any())->method('isExists')->willReturn(true); - return [ - [null, $driver], - ['custom_protocol', null] - ]; + $result = $factory->create('path', $driver); + $this->assertInstanceOf('Magento\Framework\Filesystem\File\Write', $result); } - /** - * @expectedException \InvalidArgumentException - */ - public function testCreateException() + public function testCreateWithDriverCode() { - $factory = new WriteFactory(new DriverPool()); - $factory->create('path'); + $driverPool = $this->getMock('Magento\Framework\Filesystem\DriverPool', ['getDriver']); + $driverMock = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); + $driverMock->expects($this->any())->method('isExists')->willReturn(true); + $driverPool->expects($this->once())->method('getDriver')->willReturn($driverMock); + $factory = new WriteFactory($driverPool); + $result = $factory->create('path', 'driverCode'); + $this->assertInstanceOf('Magento\Framework\Filesystem\File\Write', $result); } public function testCreateWithMode() { - $driver = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); - $driver->expects($this->any())->method('isExists')->willReturn(false); $driverPool = $this->getMock('Magento\Framework\Filesystem\DriverPool', ['getDriver']); - $driverPool->expects($this->once())->method('getDriver')->with('protocol')->willReturn($driver); + $driverPool->expects($this->never())->method('getDriver'); + $driver = $this->getMockForAbstractClass('Magento\Framework\Filesystem\DriverInterface'); + $driver->expects($this->any())->method('isExists')->willReturn(true); $factory = new WriteFactory($driverPool); - $result = $factory->create('path', 'protocol', null, 'a+'); + $result = $factory->create('path', $driver, 'a+'); $this->assertInstanceOf('Magento\Framework\Filesystem\File\Write', $result); } } diff --git a/dev/tests/unit/testsuite/Magento/Framework/Less/File/Collector/LibraryTest.php b/dev/tests/unit/testsuite/Magento/Framework/Less/File/Collector/LibraryTest.php index f5d9ef63f16d5055d26f70e4a269a641e4f348be..396fad99d70d6ff501dfe7d3b6d6af1718c5de64 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/Less/File/Collector/LibraryTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Less/File/Collector/LibraryTest.php @@ -72,8 +72,8 @@ class LibraryTest extends \PHPUnit_Framework_TestCase ->will( $this->returnValueMap( [ - [DirectoryList::LIB_WEB, $this->libraryDirectoryMock], - [DirectoryList::THEMES, $this->themesDirectoryMock], + [DirectoryList::LIB_WEB, Filesystem\DriverPool::FILE, $this->libraryDirectoryMock], + [DirectoryList::THEMES, Filesystem\DriverPool::FILE, $this->themesDirectoryMock], ] ) ); diff --git a/dev/tests/unit/testsuite/Magento/Framework/Pricing/Price/CollectionTest.php b/dev/tests/unit/testsuite/Magento/Framework/Pricing/Price/CollectionTest.php index 4b495ba6e0162a162c2b6ed9998e6603418963af..8c007c762bbfcc065f37562c78849adcfb1bf707 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/Pricing/Price/CollectionTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Pricing/Price/CollectionTest.php @@ -80,6 +80,8 @@ class CollectionTest extends \PHPUnit_Framework_TestCase ) ->will($this->returnValue($this->priceMock)); $this->assertEquals($this->priceMock, $this->collection->get('regular_price')); + //Calling the get method again with the same code, cached copy should be used + $this->assertEquals($this->priceMock, $this->collection->get('regular_price')); } /** diff --git a/dev/tests/unit/testsuite/Magento/Core/Model/Validator/FactoryTest.php b/dev/tests/unit/testsuite/Magento/Framework/Validator/FactoryTest.php similarity index 94% rename from dev/tests/unit/testsuite/Magento/Core/Model/Validator/FactoryTest.php rename to dev/tests/unit/testsuite/Magento/Framework/Validator/FactoryTest.php index 2ad8b19d563dcc38632187c3c99975f500d3c70e..649ad967473afc3a7d961029f56eb907e229d66b 100644 --- a/dev/tests/unit/testsuite/Magento/Core/Model/Validator/FactoryTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/Validator/FactoryTest.php @@ -1,11 +1,11 @@ <?php /** - * Unit test for \Magento\Core\Model\Validator\Factory + * Unit test for \Magento\Framework\Validator\Factory * * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Magento\Core\Model\Validator; +namespace Magento\Framework\Validator; class FactoryTest extends \PHPUnit_Framework_TestCase { @@ -104,7 +104,7 @@ class FactoryTest extends \PHPUnit_Framework_TestCase */ public function testGetValidatorConfig() { - $factory = new \Magento\Core\Model\Validator\Factory( + $factory = new \Magento\Framework\Validator\Factory( $this->_objectManager, $this->_config, $this->_translateAdapter @@ -144,7 +144,7 @@ class FactoryTest extends \PHPUnit_Framework_TestCase $objectManager->getObject('Magento\Framework\Validator\Builder', ['constraints' => []]) ) ); - $factory = new \Magento\Core\Model\Validator\Factory( + $factory = new \Magento\Framework\Validator\Factory( $this->_objectManager, $this->_config, $this->_translateAdapter @@ -171,7 +171,7 @@ class FactoryTest extends \PHPUnit_Framework_TestCase )->will( $this->returnValue(new \Magento\Framework\Validator()) ); - $factory = new \Magento\Core\Model\Validator\Factory( + $factory = new \Magento\Framework\Validator\Factory( $this->_objectManager, $this->_config, $this->_translateAdapter diff --git a/dev/tests/unit/testsuite/Magento/Framework/View/Asset/MinifiedTest.php b/dev/tests/unit/testsuite/Magento/Framework/View/Asset/MinifiedTest.php index 7b501992bca1fcbb3efed587558e9008a53a836b..50e39edc08a4a7a48ac4e7c314ae60a36ff9c492 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/View/Asset/MinifiedTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/View/Asset/MinifiedTest.php @@ -6,6 +6,7 @@ namespace Magento\Framework\View\Asset; use Magento\Framework\App\Filesystem\DirectoryList; +use Magento\Framework\Filesystem\DriverPool; class MinifiedTest extends \PHPUnit_Framework_TestCase { @@ -62,8 +63,8 @@ class MinifiedTest extends \PHPUnit_Framework_TestCase $this->_filesystem->expects($this->any()) ->method('getDirectoryRead') ->will($this->returnValueMap([ - [DirectoryList::STATIC_VIEW, $this->_staticViewDir], - [DirectoryList::ROOT, $this->_rootDir], + [DirectoryList::STATIC_VIEW, DriverPool::FILE, $this->_staticViewDir], + [DirectoryList::ROOT, DriverPool::FILE, $this->_rootDir], ])); $this->_filesystem->expects($this->any()) ->method('getDirectoryWrite') diff --git a/dev/tests/unit/testsuite/Magento/Framework/View/Asset/SourceTest.php b/dev/tests/unit/testsuite/Magento/Framework/View/Asset/SourceTest.php index 09c0ac59216d9d4dd2764a28acc340019e54b4f2..15862f74256296debae5f7352a4c26a33ac0b8b3 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/View/Asset/SourceTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/View/Asset/SourceTest.php @@ -7,6 +7,7 @@ namespace Magento\Framework\View\Asset; use Magento\Framework\App\Filesystem\DirectoryList; +use Magento\Framework\Filesystem\DriverPool; /** * @SuppressWarnings(PHPMD.CouplingBetweenObjects) @@ -245,9 +246,9 @@ class SourceTest extends \PHPUnit_Framework_TestCase $this->varDir = $this->getMockForAbstractClass('Magento\Framework\Filesystem\Directory\WriteInterface'); $readDirMap = [ - [DirectoryList::ROOT, $this->rootDirRead], - [DirectoryList::STATIC_VIEW, $this->staticDirRead], - [DirectoryList::VAR_DIR, $this->varDir], + [DirectoryList::ROOT, DriverPool::FILE, $this->rootDirRead], + [DirectoryList::STATIC_VIEW, DriverPool::FILE, $this->staticDirRead], + [DirectoryList::VAR_DIR, DriverPool::FILE, $this->varDir], ]; $this->filesystem->expects($this->any()) diff --git a/dev/tests/unit/testsuite/Magento/Framework/View/Element/TemplateTest.php b/dev/tests/unit/testsuite/Magento/Framework/View/Element/TemplateTest.php index 3a3fd0e8709e7d36305e35aecd68ec313b05a143..59f6568e91e8cb8668b08e1836833d4d6a74758e 100644 --- a/dev/tests/unit/testsuite/Magento/Framework/View/Element/TemplateTest.php +++ b/dev/tests/unit/testsuite/Magento/Framework/View/Element/TemplateTest.php @@ -5,6 +5,8 @@ */ namespace Magento\Framework\View\Element; +use Magento\Framework\Filesystem\DriverPool; + class TemplateTest extends \PHPUnit_Framework_TestCase { /** @@ -50,9 +52,9 @@ class TemplateTest extends \PHPUnit_Framework_TestCase $this->_filesystem->expects($this->any()) ->method('getDirectoryRead') ->will($this->returnValueMap([ - [\Magento\Framework\App\Filesystem\DirectoryList::THEMES, $themesDirMock], - [\Magento\Framework\App\Filesystem\DirectoryList::APP, $appDirMock], - [\Magento\Framework\App\Filesystem\DirectoryList::ROOT, $this->rootDirMock], + [\Magento\Framework\App\Filesystem\DirectoryList::THEMES, DriverPool::FILE, $themesDirMock], + [\Magento\Framework\App\Filesystem\DirectoryList::APP, DriverPool::FILE, $appDirMock], + [\Magento\Framework\App\Filesystem\DirectoryList::ROOT, DriverPool::FILE, $this->rootDirMock], ])); $this->_templateEngine = $this->getMock( diff --git a/dev/tests/unit/testsuite/Magento/Newsletter/Model/TemplateTest.php b/dev/tests/unit/testsuite/Magento/Newsletter/Model/TemplateTest.php index ca617c4f218d65db0ae07bc944463333e1724a90..617131882a610b46a53c729557a28741fae9b448 100644 --- a/dev/tests/unit/testsuite/Magento/Newsletter/Model/TemplateTest.php +++ b/dev/tests/unit/testsuite/Magento/Newsletter/Model/TemplateTest.php @@ -40,7 +40,7 @@ class TemplateTest extends \PHPUnit_Framework_TestCase } $filter = $this->getMock('Magento\Newsletter\Model\Template\Filter', [], [], '', false); - $appEmulation = $this->getMock('Magento\Core\Model\App\Emulation', [], [], '', false); + $appEmulation = $this->getMock('Magento\Store\Model\App\Emulation', [], [], '', false); $filter->expects($this->once())->method('setStoreId')->with('test_id'); $filter->expects($this->once())->method('setIncludeProcessor')->will($this->returnSelf()); $filter->expects( diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Form/AbstractInstructionTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Form/AbstractInstructionTest.php new file mode 100644 index 0000000000000000000000000000000000000000..a6ef83d4f0e1184643c0f34a8cef525b6eaf94e3 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Form/AbstractInstructionTest.php @@ -0,0 +1,40 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Block\Form; + +class AbstractInstructionTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflinePayments\Block\Form\AbstractInstruction + */ + protected $_model; + + protected function setUp() + { + $context = $this->getMock('Magento\Framework\View\Element\Template\Context', [], [], '', false); + $this->_model = $this->getMockForAbstractClass( + 'Magento\OfflinePayments\Block\Form\AbstractInstruction', + ['context' => $context] + ); + } + + public function testGetInstructions() + { + $method = $this->getMock( + 'Magento\Payment\Model\MethodInterface', + ['getInstructions', 'getCode', 'getFormBlockType', 'getTitle'], + [], + '', + false + ); + $method->expects($this->once()) + ->method('getInstructions') + ->willReturn('instructions'); + $this->_model->setData('method', $method); + + $this->assertEquals('instructions', $this->_model->getInstructions()); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Info/CheckmoTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Info/CheckmoTest.php new file mode 100644 index 0000000000000000000000000000000000000000..04748038a9c2d60dd98a8f42c8e92db1dfc9f123 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Block/Info/CheckmoTest.php @@ -0,0 +1,85 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Block\Info; + +class CheckmoTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflinePayments\Block\Info\Checkmo + */ + protected $_model; + + protected function setUp() + { + $context = $this->getMock('Magento\Framework\View\Element\Template\Context', [], [], '', false); + $this->_model = new \Magento\OfflinePayments\Block\Info\Checkmo($context); + } + + /** + * @dataProvider getPayableToDataProvider + */ + public function testGetPayableTo($details, $expected) + { + $info = $this->getMock('Magento\Payment\Model\Info', ['getAdditionalData'], [], '', false); + $info->expects($this->once()) + ->method('getAdditionalData') + ->willReturn(serialize($details)); + $this->_model->setData('info', $info); + + $this->assertEquals($expected, $this->_model->getPayableTo()); + } + + /** + * @return array + */ + public function getPayableToDataProvider() + { + return [ + [['payable_to' => 'payable'], 'payable'], + ['', ''] + ]; + } + + /** + * @dataProvider getMailingAddressDataProvider + */ + public function testGetMailingAddress($details, $expected) + { + $info = $this->getMock('Magento\Payment\Model\Info', ['getAdditionalData'], [], '', false); + $info->expects($this->once()) + ->method('getAdditionalData') + ->willReturn(serialize($details)); + $this->_model->setData('info', $info); + + $this->assertEquals($expected, $this->_model->getMailingAddress()); + } + + /** + * @return array + */ + public function getMailingAddressDataProvider() + { + return [ + [['mailing_address' => 'blah@blah.com'], 'blah@blah.com'], + ['', ''] + ]; + } + + public function testConvertAdditionalDataIsNeverCalled() + { + $info = $this->getMock('Magento\Payment\Model\Info', ['getAdditionalData'], [], '', false); + $info->expects($this->once()) + ->method('getAdditionalData') + ->willReturn(serialize(['mailing_address' => 'blah@blah.com'])); + $this->_model->setData('info', $info); + + // First we set the property $this->_mailingAddress + $this->_model->getMailingAddress(); + + // And now we get already setted property $this->_mailingAddress + $this->assertEquals('blah@blah.com', $this->_model->getMailingAddress()); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/BanktransferTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/BanktransferTest.php index 7dbc702c60f2c83658f7e3afc3be1518b1a5228e..18fb24e1ae8e9e67ddb04735302a0eefd64084dc 100644 --- a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/BanktransferTest.php +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/BanktransferTest.php @@ -12,18 +12,23 @@ class BanktransferTest extends \PHPUnit_Framework_TestCase */ protected $_object; + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $_scopeConfig; + protected function setUp() { $objectManagerHelper = new \Magento\TestFramework\Helper\ObjectManager($this); $eventManager = $this->getMock('Magento\Framework\Event\ManagerInterface', [], [], '', false); $paymentDataMock = $this->getMock('Magento\Payment\Helper\Data', [], [], '', false); - $scopeConfig = $this->getMock('Magento\Framework\App\Config\ScopeConfigInterface'); + $this->_scopeConfig = $this->getMock('Magento\Framework\App\Config\ScopeConfigInterface', [], [], '', false); $this->_object = $objectManagerHelper->getObject( 'Magento\OfflinePayments\Model\Banktransfer', [ 'eventManager' => $eventManager, 'paymentData' => $paymentDataMock, - 'scopeConfig' => $scopeConfig, + 'scopeConfig' => $this->_scopeConfig, ] ); } diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CashondeliveryTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CashondeliveryTest.php index e0f11d0283bfea5f4c2a8ee5fa3f835f54ea6079..cd4d60d27533e2421f7b68d12d16cc84da178be6 100644 --- a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CashondeliveryTest.php +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CashondeliveryTest.php @@ -12,6 +12,11 @@ class CashondeliveryTest extends \PHPUnit_Framework_TestCase */ protected $_object; + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $_scopeConfig; + protected function setUp() { $helper = new \Magento\TestFramework\Helper\ObjectManager($this); @@ -19,13 +24,13 @@ class CashondeliveryTest extends \PHPUnit_Framework_TestCase $eventManager = $this->getMock('Magento\Framework\Event\ManagerInterface', [], [], '', false); $paymentDataMock = $this->getMock('Magento\Payment\Helper\Data', [], [], '', false); - $scopeConfig = $this->getMock('Magento\Framework\App\Config\ScopeConfigInterface'); + $this->_scopeConfig = $this->getMock('Magento\Framework\App\Config\ScopeConfigInterface', [], [], '', false); $this->_object = $helper->getObject( 'Magento\OfflinePayments\Model\Cashondelivery', [ 'eventManager' => $eventManager, 'paymentData' => $paymentDataMock, - 'scopeConfig' => $scopeConfig, + 'scopeConfig' => $this->_scopeConfig, ] ); } diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CheckmoTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CheckmoTest.php new file mode 100644 index 0000000000000000000000000000000000000000..b6aee65b11e3e53bd8b94f17c304e743108ea89e --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/CheckmoTest.php @@ -0,0 +1,80 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Model; + +class CheckmoTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflinePayments\Model\Checkmo + */ + protected $_object; + + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $_scopeConfig; + + protected function setUp() + { + $objectManagerHelper = new \Magento\TestFramework\Helper\ObjectManager($this); + $eventManager = $this->getMock('Magento\Framework\Event\ManagerInterface', [], [], '', false); + $paymentDataMock = $this->getMock('Magento\Payment\Helper\Data', [], [], '', false); + $this->_scopeConfig = $this->getMock( + 'Magento\Framework\App\Config\ScopeConfigInterface', + ['getValue', 'isSetFlag'], + [], + '', + false + ); + $this->_object = $objectManagerHelper->getObject( + 'Magento\OfflinePayments\Model\Checkmo', + [ + 'eventManager' => $eventManager, + 'paymentData' => $paymentDataMock, + 'scopeConfig' => $this->_scopeConfig, + ] + ); + } + + public function testGetPayableTo() + { + $this->_object->setStore(1); + $this->_scopeConfig->expects($this->once()) + ->method('getValue') + ->with('payment/checkmo/payable_to', 'store', 1) + ->willReturn('payable'); + $this->assertEquals('payable', $this->_object->getPayableTo()); + } + + public function testGetMailingAddress() + { + $this->_object->setStore(1); + $this->_scopeConfig->expects($this->once()) + ->method('getValue') + ->with('payment/checkmo/mailing_address', 'store', 1) + ->willReturn('blah@blah.com'); + $this->assertEquals('blah@blah.com', $this->_object->getMailingAddress()); + } + + public function testAssignData() + { + $details['payable_to'] = 'payable'; + $details['mailing_address'] = 'blah@blah.com'; + $this->_object->setStore(1); + $this->_scopeConfig->expects($this->any()) + ->method('getValue') + ->willReturnMap([ + ['payment/checkmo/payable_to', 'store', 1, 'payable'], + ['payment/checkmo/mailing_address', 'store', 1, 'blah@blah.com'] + ]); + $instance = $this->getMock('Magento\Payment\Model\Info', ['setAdditionalData'], [], '', false); + $instance->expects($this->once()) + ->method('setAdditionalData') + ->with(serialize($details)); + $this->_object->setData('info_instance', $instance); + $this->_object->assignData(''); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/ObserverTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/ObserverTest.php new file mode 100644 index 0000000000000000000000000000000000000000..708b25093f52be0cb438d79411931480af7ac1c3 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/ObserverTest.php @@ -0,0 +1,84 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Model; + +class ObserverTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflinePayments\Model\Observer + */ + protected $_model; + + protected function setUp() + { + $objectManagerHelper = new \Magento\TestFramework\Helper\ObjectManager($this); + $this->_model = $objectManagerHelper->getObject('Magento\OfflinePayments\Model\Observer'); + } + + public function testBeforeOrderPaymentSave() + { + $observer = $this->getMock('Magento\Framework\Event\Observer', ['getEvent'], [], '', false); + $event = $this->getMock('Magento\Framework\Event', ['getPayment'], [], '', false); + $payment = $this->getMock( + 'Magento\Sales\Model\Order\Payment', + ['getMethod', 'setAdditionalInformation', 'getMethodInstance'], + [], + '', + false + ); + $payment->expects($this->once()) + ->method('getMethod') + ->willReturn('banktransfer'); + $payment->expects($this->once()) + ->method('setAdditionalInformation') + ->with('instructions', 'payment configuration'); + $method = $this->getMock( + 'Magento\Payment\Model\MethodInterface', + ['getConfigData', 'getFormBlockType', 'getTitle', 'getCode'], + [], + '', + false + ); + $method->expects($this->once()) + ->method('getConfigData') + ->willReturn('payment configuration'); + $payment->expects($this->once()) + ->method('getMethodInstance') + ->willReturn($method); + $event->expects($this->once()) + ->method('getPayment') + ->willReturn($payment); + $observer->expects($this->once()) + ->method('getEvent') + ->willReturn($event); + $this->_model->beforeOrderPaymentSave($observer); + } + + public function testBeforeOrderPaymentSaveNoBanktransfer() + { + $observer = $this->getMock('Magento\Framework\Event\Observer', ['getEvent'], [], '', false); + $event = $this->getMock('Magento\Framework\Event', ['getPayment'], [], '', false); + $payment = $this->getMock( + 'Magento\Sales\Model\Order\Payment', + ['getMethod', 'setAdditionalInformation', 'getMethodInstance'], + [], + '', + false + ); + $payment->expects($this->once()) + ->method('getMethod') + ->willReturn('somepaymentmethod'); + $payment->expects($this->never()) + ->method('setAdditionalInformation'); + $event->expects($this->once()) + ->method('getPayment') + ->willReturn($payment); + $observer->expects($this->once()) + ->method('getEvent') + ->willReturn($event); + $this->_model->beforeOrderPaymentSave($observer); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/PurchaseorderTest.php b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/PurchaseorderTest.php new file mode 100644 index 0000000000000000000000000000000000000000..fb08707e9e4b9d44d89c6e5d2dd7488cbe806835 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflinePayments/Model/PurchaseorderTest.php @@ -0,0 +1,52 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflinePayments\Model; + +class PurchaseorderTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflinePayments\Model\Purchaseorder + */ + protected $_object; + + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $_scopeConfig; + + protected function setUp() + { + $objectManagerHelper = new \Magento\TestFramework\Helper\ObjectManager($this); + $eventManager = $this->getMock('Magento\Framework\Event\ManagerInterface', [], [], '', false); + $paymentDataMock = $this->getMock('Magento\Payment\Helper\Data', [], [], '', false); + $this->_scopeConfig = $this->getMock( + 'Magento\Framework\App\Config\ScopeConfigInterface', + ['getValue', 'isSetFlag'], + [], + '', + false + ); + $this->_object = $objectManagerHelper->getObject( + 'Magento\OfflinePayments\Model\Purchaseorder', + [ + 'eventManager' => $eventManager, + 'paymentData' => $paymentDataMock, + 'scopeConfig' => $this->_scopeConfig, + ] + ); + } + + public function testAssignData() + { + $data = new \Magento\Framework\Object([ + 'po_number' => '12345' + ]); + + $instance = $this->getMock('Magento\Payment\Model\Info', [], [], '', false); + $this->_object->setData('info_instance', $instance); + $this->_object->assignData($data); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Block/Adminhtml/Carrier/Tablerate/GridTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Block/Adminhtml/Carrier/Tablerate/GridTest.php new file mode 100644 index 0000000000000000000000000000000000000000..09434687725e98ae388fb66f649e57ed92a31ff8 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Block/Adminhtml/Carrier/Tablerate/GridTest.php @@ -0,0 +1,127 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Block\Adminhtml\Carrier\Tablerate; + +class GridTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Block\Adminhtml\Carrier\Tablerate\Grid + */ + protected $model; + + /** + * @var \Magento\Store\Model\StoreManagerInterface|\PHPUnit_Framework_MockObject_MockObject + */ + protected $storeManagerMock; + + /** + * @var \Magento\Backend\Helper\Data|\PHPUnit_Framework_MockObject_MockObject + */ + protected $backendHelperMock; + + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $tablerateMock; + + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $context; + + /** + * @var \PHPUnit_Framework_MockObject_MockObject + */ + protected $collectionFactoryMock; + + protected function setUp() + { + $objectManager = new \Magento\TestFramework\Helper\ObjectManager($this); + + $this->storeManagerMock = $this->getMockBuilder('Magento\Store\Model\StoreManagerInterface') + ->disableOriginalConstructor() + ->getMock(); + + $this->context = $objectManager->getObject('Magento\Backend\Block\Template\Context', [ + 'storeManager' => $this->storeManagerMock + ]); + + $this->backendHelperMock = $this->getMockBuilder('\Magento\Backend\Helper\Data') + ->disableOriginalConstructor() + ->getMock(); + + $this->collectionFactoryMock = + $this->getMockBuilder('\Magento\OfflineShipping\Model\Resource\Carrier\Tablerate\CollectionFactory') + ->disableOriginalConstructor() + ->getMock(); + + $this->tablerateMock = $this->getMockBuilder('Magento\OfflineShipping\Model\Carrier\Tablerate') + ->disableOriginalConstructor() + ->getMock(); + + $this->model = new \Magento\OfflineShipping\Block\Adminhtml\Carrier\Tablerate\Grid( + $this->context, + $this->backendHelperMock, + $this->collectionFactoryMock, + $this->tablerateMock + ); + } + + public function testSetWebsiteId() + { + $websiteId = 1; + + $websiteMock = $this->getMockBuilder('Magento\Store\Model\Website') + ->setMethods(['getId']) + ->disableOriginalConstructor() + ->getMock(); + + $this->storeManagerMock->expects($this->once()) + ->method('getWebsite') + ->with($websiteId) + ->willReturn($websiteMock); + + $websiteMock->expects($this->once()) + ->method('getId') + ->willReturn($websiteId); + + $this->assertSame($this->model, $this->model->setWebsiteId($websiteId)); + $this->assertEquals($websiteId, $this->model->getWebsiteId()); + } + + public function testGetWebsiteId() + { + $websiteId = 10; + + $websiteMock = $this->getMockBuilder('Magento\Store\Model\Website') + ->disableOriginalConstructor() + ->setMethods(['getId']) + ->getMock(); + + $websiteMock->expects($this->once()) + ->method('getId') + ->willReturn($websiteId); + + $this->storeManagerMock->expects($this->once()) + ->method('getWebsite') + ->willReturn($websiteMock); + + $this->assertEquals($websiteId, $this->model->getWebsiteId()); + + $this->storeManagerMock->expects($this->never()) + ->method('getWebsite') + ->willReturn($websiteMock); + + $this->assertEquals($websiteId, $this->model->getWebsiteId()); + } + + public function testSetAndGetConditionName() + { + $conditionName = 'someName'; + $this->assertEquals($this->model, $this->model->setConditionName($conditionName)); + $this->assertEquals($conditionName, $this->model->getConditionName()); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Backend/TablerateTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Backend/TablerateTest.php new file mode 100644 index 0000000000000000000000000000000000000000..16ff0b107650fb8371f8bc90c03ffa4ddbdeb28c --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Backend/TablerateTest.php @@ -0,0 +1,51 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Model\Config\Backend; + +class TablerateTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Model\Config\Backend\Tablerate + */ + protected $model; + + /** + * @var \Magento\OfflineShipping\Model\Resource\Carrier\TablerateFactory|\PHPUnit_Framework_MockObject_MockObject + */ + protected $tableateFactoryMock; + + protected function setUp() + { + $this->tableateFactoryMock = + $this->getMockBuilder('Magento\OfflineShipping\Model\Resource\Carrier\TablerateFactory') + ->disableOriginalConstructor() + ->setMethods(['create']) + ->getMock(); + + $helper = new \Magento\TestFramework\Helper\ObjectManager($this); + $this->model = $helper->getObject('\Magento\OfflineShipping\Model\Config\Backend\Tablerate', [ + 'tablerateFactory' => $this->tableateFactoryMock + ]); + } + + public function testAfterSave() + { + $tablerateMock = $this->getMockBuilder('Magento\OfflineShipping\Model\Resource\Carrier\Tablerate') + ->disableOriginalConstructor() + ->setMethods(['uploadAndImport']) + ->getMock(); + + $this->tableateFactoryMock->expects($this->once()) + ->method('create') + ->willReturn($tablerateMock); + + $tablerateMock->expects($this->once()) + ->method('uploadAndImport') + ->with($this->model); + + $this->model->afterSave(); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/FlatrateTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/FlatrateTest.php new file mode 100644 index 0000000000000000000000000000000000000000..c133cd1e07d79ca79ff22e5d5eb0ef8060e76568 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/FlatrateTest.php @@ -0,0 +1,30 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Model\Config\Source; + +class FlatrateTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Model\Config\Source\Flatrate + */ + protected $model; + + protected function setUp() + { + $this->model = new Flatrate(); + } + + public function testToOptionArray() + { + $expected = [ + ['value' => '', 'label' => __('None')], + ['value' => 'O', 'label' => __('Per Order')], + ['value' => 'I', 'label' => __('Per Item')] + ]; + + $this->assertEquals($expected, $this->model->toOptionArray()); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/TablerateTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/TablerateTest.php new file mode 100644 index 0000000000000000000000000000000000000000..8eea5073c3f3ecfca6593ad497b5201f83efcc03 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Config/Source/TablerateTest.php @@ -0,0 +1,47 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Model\Config\Source; + +class TablerateTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Model\Config\Source\Tablerate + */ + protected $model; + + /** + * @var \Magento\OfflineShipping\Model\Carrier\Tablerate|\PHPUnit_Framework_MockObject_MockObject + */ + protected $carrierTablerateMock; + + protected function setUp() + { + $this->carrierTablerateMock = $this->getMockBuilder('\Magento\OfflineShipping\Model\Carrier\Tablerate') + ->disableOriginalConstructor() + ->setMethods(['getCode']) + ->getMock(); + + $helper = new \Magento\TestFramework\Helper\ObjectManager($this); + $this->model = $helper->getObject('Magento\OfflineShipping\Model\Config\Source\Tablerate', [ + 'carrierTablerate' => $this->carrierTablerateMock + ]); + } + + public function testToOptionArray() + { + $codes = [1, 2, 3, 4, 5]; + $expected = []; + foreach ($codes as $k => $v) { + $expected[] = ['value' => $k, 'label' => $v]; + } + + $this->carrierTablerateMock->expects($this->once()) + ->method('getCode') + ->willReturn($codes); + + $this->assertEquals($expected, $this->model->toOptionArray()); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTabTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTabTest.php new file mode 100644 index 0000000000000000000000000000000000000000..751faf0cf82c8c1c32b78e51918136fc4c943018 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Observer/SalesRule/ActionsTabTest.php @@ -0,0 +1,70 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Model\Observer\SalesRule; + +use Magento\OfflineShipping\Model\SalesRule\Rule; + +class ActionsTabTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Model\Observer\SalesRule\ActionsTab + */ + protected $model; + + protected function setUp() + { + $this->model = new ActionsTab(); + } + + public function testPrepareForm() + { + $observerMock = $this->getMockBuilder('\Magento\Framework\Event\Observer') + ->disableOriginalConstructor() + ->setMethods(['getForm']) + ->getMock(); + + $formMock = $this->getMockBuilder('\Magento\Framework\Data\Form') + ->disableOriginalConstructor() + ->setMethods(['getElements']) + ->getMock(); + + $elementMock = $this->getMockBuilder('\Magento\Framework\Data\Form\Element\AbstractElement') + ->disableOriginalConstructor() + ->setMethods(['getId', 'addField']) + ->getMock(); + + $elementMock->expects($this->once()) + ->method('getId') + ->willReturn('action_fieldset'); + + $elementMock->expects($this->once()) + ->method('addField') + ->with( + 'simple_free_shipping', + 'select', + [ + 'label' => __('Free Shipping'), + 'title' => __('Free Shipping'), + 'name' => 'simple_free_shipping', + 'options' => [ + 0 => __('No'), + Rule::FREE_SHIPPING_ITEM => __('For matching items only'), + Rule::FREE_SHIPPING_ADDRESS => __('For shipment with matching items'), + ] + ] + ); + + $formMock->expects($this->once()) + ->method('getElements') + ->willReturn([$elementMock]); + + $observerMock->expects($this->once()) + ->method('getForm') + ->willReturn($formMock); + + $this->model->prepareForm($observerMock); + } +} diff --git a/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Plugin/Checkout/Block/Cart/ShippingTest.php b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Plugin/Checkout/Block/Cart/ShippingTest.php new file mode 100644 index 0000000000000000000000000000000000000000..0fc0f97fbb760e440c728169b047e2788d04f397 --- /dev/null +++ b/dev/tests/unit/testsuite/Magento/OfflineShipping/Model/Plugin/Checkout/Block/Cart/ShippingTest.php @@ -0,0 +1,74 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\OfflineShipping\Model\Plugin\Checkout\Block\Cart; + +class ShippingTest extends \PHPUnit_Framework_TestCase +{ + /** + * @var \Magento\OfflineShipping\Model\Plugin\Checkout\Block\Cart\Shipping + */ + protected $model; + + /** + * @var \Magento\Framework\App\Config\ScopeConfigInterface|\PHPUnit_Framework_MockObject_MockObject + */ + protected $scopeConfigMock; + + protected function setUp() + { + $helper = new \Magento\TestFramework\Helper\ObjectManager($this); + + $this->scopeConfigMock = $this->getMockBuilder('\Magento\Framework\App\Config\ScopeConfigInterface') + ->disableOriginalConstructor() + ->setMethods([ + 'getValue', + 'isSetFlag' + ]) + ->getMock(); + + $this->model = $helper->getObject('\Magento\OfflineShipping\Model\Plugin\Checkout\Block\Cart\Shipping', [ + 'scopeConfig' => $this->scopeConfigMock + ]); + } + + /** + * @dataProvider afterGetStateActiveDataProvider + */ + public function testAfterGetStateActive($scopeConfigMockReturnValue, $result, $assertResult) + { + /** @var \Magento\Checkout\Block\Cart\Shipping $subjectMock */ + $subjectMock = $this->getMockBuilder('Magento\Checkout\Block\Cart\Shipping') + ->disableOriginalConstructor() + ->getMock(); + + $this->scopeConfigMock->expects($result ? $this->never() : $this->once()) + ->method('getValue') + ->willReturn($scopeConfigMockReturnValue); + + $this->assertEquals($assertResult, $this->model->afterGetStateActive($subjectMock, $result)); + } + + public function afterGetStateActiveDataProvider() + { + return [ + [ + true, + true, + true + ], + [ + true, + false, + true + ], + [ + false, + false, + false + ] + ]; + } +} diff --git a/dev/tests/unit/testsuite/Magento/Payment/Block/Info/InstructionsTest.php b/dev/tests/unit/testsuite/Magento/Payment/Block/Info/InstructionsTest.php index 43528a3ce3970a9aa067fc1739a2e67bf32196ea..7c035de52c8a1866e0ab4faff8599b8442c9229e 100644 --- a/dev/tests/unit/testsuite/Magento/Payment/Block/Info/InstructionsTest.php +++ b/dev/tests/unit/testsuite/Magento/Payment/Block/Info/InstructionsTest.php @@ -12,12 +12,7 @@ namespace Magento\Payment\Block\Info; class InstructionsTest extends \PHPUnit_Framework_TestCase { /** - * @var \Magento\Framework\Object - */ - protected $_method; - - /** - * @var \Magento\Payment\Model\Info + * @var \Magento\Payment\Model\Info|\PHPUnit_Framework_MockObject_MockObject */ protected $_info; @@ -28,28 +23,44 @@ class InstructionsTest extends \PHPUnit_Framework_TestCase protected function setUp() { - $objectManagerHelper = new \Magento\TestFramework\Helper\ObjectManager($this); - $this->_method = new \Magento\Framework\Object(); - $this->_info = $objectManagerHelper->getObject('Magento\Payment\Model\Info'); - $this->_instructions = $objectManagerHelper->getObject('Magento\Payment\Block\Info\Instructions'); - - $this->_info->setMethodInstance($this->_method); - $this->_instructions->setInfo($this->_info); + $context = $this->getMock('Magento\Framework\View\Element\Template\Context', [], [], '', false); + $this->_instructions = new \Magento\Payment\Block\Info\Instructions($context); + $this->_info = $this->getMock('Magento\Payment\Model\Info', [], [], '', false); + $this->_instructions->setData('info', $this->_info); } - public function testGetInstructionsSetInstructions() + public function testGetInstructionAdditionalInformation() { - $this->assertNull($this->_instructions->getInstructions()); - $testInstruction = 'first test'; - $this->_method->setInstructions($testInstruction); - $this->assertEquals($testInstruction, $this->_instructions->getInstructions()); + $this->_info->expects($this->once()) + ->method('getAdditionalInformation') + ->with('instructions') + ->willReturn('get the instruction here'); + $this->assertEquals('get the instruction here', $this->_instructions->getInstructions()); + + // And we get the already setted param $this->_instructions + $this->assertEquals('get the instruction here', $this->_instructions->getInstructions()); } - public function testGetInstructionsSetInformation() + public function testGetInstruction() { - $this->assertNull($this->_instructions->getInstructions()); - $testInstruction = 'second test'; - $this->_info->setAdditionalInformation('instructions', $testInstruction); - $this->assertEquals($testInstruction, $this->_instructions->getInstructions()); + $methodInstance = $this->getMock( + 'Magento\Payment\Model\MethodInterface', + ['getConfigData', 'getCode', 'getFormBlockType', 'getTitle'], + [], + '', + false + ); + $methodInstance->expects($this->once()) + ->method('getConfigData') + ->with('instructions') + ->willReturn('get the instruction here'); + $this->_info->expects($this->once()) + ->method('getAdditionalInformation') + ->with('instructions') + ->willReturn(false); + $this->_info->expects($this->once()) + ->method('getMethodInstance') + ->willReturn($methodInstance); + $this->assertEquals('get the instruction here', $this->_instructions->getInstructions()); } } diff --git a/dev/tests/unit/testsuite/Magento/Payment/Helper/DataTest.php b/dev/tests/unit/testsuite/Magento/Payment/Helper/DataTest.php index f2ae8359ac89d28e21520d34c8c128bd08db6da0..0c3371787ecc978d2c0ff5b782d136227c27317c 100644 --- a/dev/tests/unit/testsuite/Magento/Payment/Helper/DataTest.php +++ b/dev/tests/unit/testsuite/Magento/Payment/Helper/DataTest.php @@ -42,7 +42,7 @@ class DataTest extends \PHPUnit_Framework_TestCase $layoutFactoryMock->expects($this->once())->method('create')->willReturn($this->layoutMock); $this->methodFactory = $this->getMock('Magento\Payment\Model\Method\Factory', [], [], '', false); - $this->appEmulation = $this->getMock('Magento\Core\Model\App\Emulation', [], [], '', false); + $this->appEmulation = $this->getMock('Magento\Store\Model\App\Emulation', [], [], '', false); $paymentConfig = $this->getMock('Magento\Payment\Model\Config', [], [], '', false); $this->initialConfig = $this->getMock('Magento\Framework\App\Config\Initial', [], [], '', false); diff --git a/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ByPercentTest.php b/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ByPercentTest.php index 3a8f64727c33d0132c3e762bd8a9f810bf6179fb..b770464aa8d2a3008ab37c34ae5b3e9a987ca5db 100644 --- a/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ByPercentTest.php +++ b/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ByPercentTest.php @@ -209,7 +209,7 @@ class ByPercentTest extends \PHPUnit_Framework_TestCase 'amount' => 42, 'baseAmount' => 25.5, 'originalAmount' => 51, - 'baseOriginalAmount' => 46.5, + 'baseOriginalAmount' => 34.5, ], ] ]; diff --git a/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ToPercentTest.php b/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ToPercentTest.php index 7163d2680c9a3884baad59d89991cd902b20b35d..13bec6ff79e5a34f1369ae363e59c1d63822d8b3 100644 --- a/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ToPercentTest.php +++ b/dev/tests/unit/testsuite/Magento/SalesRule/Model/Rule/Action/Discount/ToPercentTest.php @@ -209,7 +209,7 @@ class ToPercentTest extends \PHPUnit_Framework_TestCase 'amount' => 98, 'baseAmount' => 59.5, 'originalAmount' => 119, - 'baseOriginalAmount' => 108.5, + 'baseOriginalAmount' => 80.5, ], ] ]; diff --git a/dev/tests/unit/testsuite/Magento/Core/Model/App/EmulationTest.php b/dev/tests/unit/testsuite/Magento/Store/Model/App/EmulationTest.php similarity index 98% rename from dev/tests/unit/testsuite/Magento/Core/Model/App/EmulationTest.php rename to dev/tests/unit/testsuite/Magento/Store/Model/App/EmulationTest.php index b7e7920042130e43dc3fb50f78284544d391c794..d09271bdfd36c56921741f785ae701de299cbe36 100644 --- a/dev/tests/unit/testsuite/Magento/Core/Model/App/EmulationTest.php +++ b/dev/tests/unit/testsuite/Magento/Store/Model/App/EmulationTest.php @@ -1,11 +1,11 @@ <?php /** - * Tests Magento\Core\Model\App\Emulation + * Tests Magento\Store\Model\App\Emulation * * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Magento\Core\Model\App; +namespace Magento\Store\Model\App; class EmulationTest extends \PHPUnit_Framework_TestCase { @@ -65,7 +65,7 @@ class EmulationTest extends \PHPUnit_Framework_TestCase const NEW_STORE_ID = 9; /** - * @var \Magento\Core\Model\App\Emulation + * @var \Magento\Store\Model\App\Emulation */ private $model; @@ -105,7 +105,7 @@ class EmulationTest extends \PHPUnit_Framework_TestCase $this->designMock->expects($this->any())->method('getData')->willReturn(false); // Prepare SUT - $this->model = $this->objectManager->getObject('Magento\Core\Model\App\Emulation', + $this->model = $this->objectManager->getObject('Magento\Store\Model\App\Emulation', [ 'storeManager' => $this->storeManagerMock, 'viewDesign' => $this->viewDesignMock, diff --git a/dev/tests/unit/testsuite/Magento/Tax/Helper/DataTest.php b/dev/tests/unit/testsuite/Magento/Tax/Helper/DataTest.php index 68c8fe6eb6b0eb2124473d8da2d7571bf836328e..6bc869feb90224c5ff1c3ddde91d62699b82c864 100644 --- a/dev/tests/unit/testsuite/Magento/Tax/Helper/DataTest.php +++ b/dev/tests/unit/testsuite/Magento/Tax/Helper/DataTest.php @@ -366,6 +366,74 @@ class DataTest extends \PHPUnit_Framework_TestCase ], ], ], + //Scenario 3: one item, with both shipping and product taxes + // note that 'shipping tax' is listed before 'product tax' + 'one_item_with_both_shipping_and_product_taxes' => [ + 'order' => [ + 'order_id' => 1, + 'shipping_tax_amount' => 2, + 'order_tax_details' => [ + 'items' => [ + 'shippingTax1' => [ + 'item_id' => null, + 'type' => 'shipping', + 'applied_taxes' => [ + [ + 'amount' => 2.0, + 'base_amount' => 2.0, + 'code' => 'US-CA-Ship', + 'title' => 'US-CA-Sales-Tax-Ship', + 'percent' => 10.0, + ], + ], + ], + 'itemTax1' => [ + 'item_id' => 1, + 'applied_taxes' => [ + [ + 'amount' => 5.0, + 'base_amount' => 5.0, + 'code' => 'US-CA', + 'title' => 'US-CA-Sales-Tax', + 'percent' => 20.0, + ], + ], + ], + ], + ], + ], + 'invoice' => [ + 'shipping_tax_amount' => 2, + 'invoice_items' => [ + 'item1' => new MagentoObject( + [ + 'order_item' => new MagentoObject( + [ + 'id' => 1, + 'tax_amount' => 5.00, + ] + ), + 'tax_amount' => 5.00, + ] + ), + ], + ], + // note that 'shipping tax' is now listed after 'product tax' + 'expected_results' => [ + [ + 'title' => 'US-CA-Sales-Tax', + 'percent' => 20.0, + 'tax_amount' => 5.00, + 'base_tax_amount' => 5.00, + ], + [ + 'title' => 'US-CA-Sales-Tax-Ship', + 'percent' => 10.0, + 'tax_amount' => 2.00, + 'base_tax_amount' => 2.00, + ], + ], + ], ]; return $data; diff --git a/dev/tests/unit/testsuite/Magento/Tools/Di/Compiler/Config/ReaderTest.php b/dev/tests/unit/testsuite/Magento/Tools/Di/Compiler/Config/ReaderTest.php index 7ccdb02d2065c65f0ae3a4833b51445dbdc63090..0c2f708332fec2697a4d8bd833bf0b8a874bd5dd 100644 --- a/dev/tests/unit/testsuite/Magento/Tools/Di/Compiler/Config/ReaderTest.php +++ b/dev/tests/unit/testsuite/Magento/Tools/Di/Compiler/Config/ReaderTest.php @@ -5,6 +5,9 @@ */ namespace Magento\Tools\Di\Compiler\Config; +use Magento\Framework\App\Area; +use Magento\Tools\Di\Definition\Collection; + class ReaderTest extends \PHPUnit_Framework_TestCase { /** @@ -54,6 +57,9 @@ class ReaderTest extends \PHPUnit_Framework_TestCase false ); $this->argumentsResolver = $this->getMock('Magento\Tools\Di\Compiler\ArgumentsResolver', [], [], '', false); + $this->argumentsResolverFactory->expects($this->any()) + ->method('create') + ->willReturn($this->argumentsResolver); $this->classReaderDecorator = $this->getMock( 'Magento\Tools\Di\Code\Reader\ClassReaderDecorator', [], @@ -72,71 +78,182 @@ class ReaderTest extends \PHPUnit_Framework_TestCase ); } - public function testGenerateCachePerScopeExtends() + public function testGenerateCachePerScopeGlobal() { - $definitionsCollection = $this->getMock('Magento\Tools\Di\Definition\Collection', [], [], '', false); - $this->diContainerConfig->expects($this->once()) - ->method('extend') - ->with([]); - $this->configLoader->expects($this->once()) - ->method('load') - ->with('areaCode') - ->willReturn([]); - - $this->argumentsResolverFactory->expects($this->once()) - ->method('create') - ->with($this->diContainerConfig) - ->willReturn($this->argumentsResolver); - $definitionsCollection->expects($this->exactly(2)) - ->method('getInstancesNamesList') - ->willReturn(['instanceType1'], ['instanceType2']); - $definitionsCollection->expects($this->once()) - ->method('getInstanceArguments') - ->willReturnMap([ - ['instanceType1', null], - ['instanceType2', ['arg1', 'arg2']], - ]); - $this->typeReader->expects($this->exactly(3)) - ->method('isConcrete') - ->willReturnMap([ - ['instanceType1', true], - ['instanceType2', false], - ['originalType1', true], - ['originalType2', false], - ]); - $this->argumentsResolver->expects($this->exactly(2)) - ->method('getResolvedConstructorArguments') - ->willReturnMap([ - ['instanceType1', 'resolvedConstructor1'], - ['instanceVirtualType1', 'resolvedConstructor2'], - ]); - $this->diContainerConfig->expects($this->exactly(2)) + $definitionCollection = $this->getDefinitionsCollection(); + $this->diContainerConfig->expects($this->any()) ->method('getVirtualTypes') - ->willReturn(['instanceVirtualType1' => 1, 'instanceVirtualType2' => 2]); - $this->diContainerConfig->expects($this->exactly(4)) + ->willReturn($this->getVirtualTypes()); + $this->diContainerConfig->expects($this->any()) + ->method('getPreferences') + ->willReturn($this->getPreferences()); + + $getResolvedConstructorArgumentsMap = $this->getResolvedVirtualConstructorArgumentsMap( + $definitionCollection, + $this->getVirtualTypes() + ); + + $this->diContainerConfig->expects($this->any()) ->method('getInstanceType') - ->willReturnMap([ - ['instanceVirtualType1', 'originalType1'], - ['instanceVirtualType2', 'originalType2'], - ]); - $definitionsCollection->expects($this->exactly(2)) - ->method('hasInstance') - ->willReturn(''); - $this->classReaderDecorator->expects($this->once()) - ->method('getConstructor') - ->willReturn('constructor'); - $this->diContainerConfig->expects($this->once()) + ->willReturnMap($this->getInstanceTypeMap($this->getVirtualTypes())); + + $this->diContainerConfig->expects($this->any()) ->method('isShared') - ->willReturnMap([ - ['instanceType1', true], - ['instanceType2', false], - ]); - $this->diContainerConfig->expects($this->once()) + ->willReturnMap($this->getExpectedNonShared()); + + $this->diContainerConfig->expects($this->any()) ->method('getPreference') - ->willReturnMap([ - ['instanceType1', 'instanceType1ss'], - ['instanceType2', 'instanceType2'], - ]); - $this->model->generateCachePerScope($definitionsCollection, 'areaCode'); + ->willReturnMap($this->getPreferencesMap()); + + $isConcreteMap = []; + foreach ($definitionCollection->getInstancesNamesList() as $instanceType) { + $isConcreteMap[] = [$instanceType, strpos($instanceType, 'Interface') === false]; + + $getResolvedConstructorArgumentsMap[] = [ + $instanceType, + $definitionCollection->getInstanceArguments($instanceType), + $this->getResolvedArguments( + $definitionCollection->getInstanceArguments($instanceType) + ) + ]; + } + + $this->typeReader->expects($this->any()) + ->method('isConcrete') + ->willReturnMap($isConcreteMap); + $this->argumentsResolver->expects($this->any()) + ->method('getResolvedConstructorArguments') + ->willReturnMap($getResolvedConstructorArgumentsMap); + + $this->assertEquals( + $this->getExpectedGlobalConfig(), + $this->model->generateCachePerScope($definitionCollection, Area::AREA_GLOBAL) + ); + } + + /** + * @return array + */ + private function getExpectedGlobalConfig() + { + return [ + 'arguments' => [ + 'ConcreteType1' => serialize(['resolved_argument1', 'resolved_argument2']), + 'ConcreteType2' => serialize(['resolved_argument1', 'resolved_argument2']), + 'virtualType1' => serialize(['resolved_argument1', 'resolved_argument2']) + ], + 'nonShared' => [ + 'ConcreteType2' => true, + 'ThirdPartyInterface' => true + ], + 'preferences' => $this->getPreferences(), + 'instanceTypes' => $this->getVirtualTypes(), + ]; + } + + /** + * @return Collection + */ + private function getDefinitionsCollection() + { + $definitionCollection = new Collection(); + $definitionCollection->addDefinition('ConcreteType1', ['argument1', 'argument2']); + $definitionCollection->addDefinition('ConcreteType2', ['argument1', 'argument2']); + $definitionCollection->addDefinition('Interface1', [null]); + + return $definitionCollection; + } + + /** + * @return array + */ + private function getVirtualTypes() + { + return ['virtualType1' => 'ConcreteType1']; + } + + /** + * @return array + */ + private function getExpectedNonShared() + { + return [ + ['ConcreteType1', true], + ['ConcreteType2', false], + ['Interface1', true], + ['ThirdPartyInterface', false] + ]; + } + + /** + * @return array + */ + private function getPreferences() + { + return [ + 'Interface1' => 'ConcreteType1', + 'ThirdPartyInterface' => 'ConcreteType2' + ]; + } + + /** + * @return array + */ + private function getPreferencesMap() + { + return [ + ['ConcreteType1', 'ConcreteType1'], + ['ConcreteType2', 'ConcreteType2'], + ['Interface1', 'ConcreteType1'], + ['ThirdPartyInterface', 'ConcreteType2'] + ]; + } + + /** + * @param array $arguments + * @return array|null + */ + private function getResolvedArguments($arguments) + { + return empty($arguments) ? null : array_map( + function ($argument) { + return 'resolved_' . $argument; + }, + $arguments + ); + } + + /** + * @param array $virtualTypes + * @return array + */ + private function getInstanceTypeMap($virtualTypes) + { + $getInstanceTypeMap = []; + foreach ($virtualTypes as $virtualType => $concreteType) { + $getInstanceTypeMap[] = [$virtualType, $concreteType]; + } + + return $getInstanceTypeMap; + } + + /** + * @param Collection $definitionCollection + * @param array $virtualTypes + * @return array + */ + private function getResolvedVirtualConstructorArgumentsMap(Collection $definitionCollection, array $virtualTypes) + { + $getResolvedConstructorArgumentsMap = []; + foreach ($virtualTypes as $virtualType => $concreteType) { + $getResolvedConstructorArgumentsMap[] = [ + $virtualType, + $definitionCollection->getInstanceArguments($concreteType), + $this->getResolvedArguments( + $definitionCollection->getInstanceArguments($concreteType) + ) + ]; + } + return $getResolvedConstructorArgumentsMap; } } diff --git a/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTaxTest.php b/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTaxTest.php index f42bcdd7808be82e9f02f96d8270df72266a3187..b1be049dd0c5081adbcdb09888e2a6f5067b3098 100644 --- a/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTaxTest.php +++ b/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTaxTest.php @@ -279,7 +279,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -323,7 +323,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_unit_not_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -367,7 +367,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -411,7 +411,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_non_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -449,7 +449,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_non_taxable_unit_include_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -487,7 +487,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_row_include_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -531,7 +531,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_taxable_row_include_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -575,7 +575,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_non_taxable_row_include_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -613,7 +613,7 @@ class WeeeTaxTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_non_taxable_row_not_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, diff --git a/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTest.php b/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTest.php index a13403e3ad8c186c6ff203846d25f88cc0a2d5c6..4ddcc5d6296da7875c3b5fd16b30077efd311d19 100644 --- a/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTest.php +++ b/dev/tests/unit/testsuite/Magento/Weee/Model/Total/Quote/WeeeTest.php @@ -221,7 +221,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -261,7 +261,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_unit_not_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -301,7 +301,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -341,7 +341,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_non_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -383,7 +383,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_non_taxable_unit_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_UNIT_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_UNIT_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -425,7 +425,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_taxable_row_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -465,7 +465,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_taxable_row_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -505,7 +505,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_incl_tax_weee_non_taxable_row_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => true, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -547,7 +547,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_non_taxable_row_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, @@ -589,7 +589,7 @@ class WeeeTest extends \PHPUnit_Framework_TestCase $data['price_excl_tax_weee_non_taxable_row_not_included_in_subtotal'] = [ 'tax_config' => [ 'priceIncludesTax' => false, - 'getCalculationAgorithm' => Calculation::CALC_ROW_BASE, + 'getCalculationAlgorithm' => Calculation::CALC_ROW_BASE, ], 'weee_config' => [ 'isEnabled' => true, diff --git a/dev/tools/Magento/Tools/Di/Code/Reader/ClassesScanner.php b/dev/tools/Magento/Tools/Di/Code/Reader/ClassesScanner.php index 42076377419a344728227c49cf927d167ccb7135..97063a236a2f9543ebb4ab503ced1a75b059d0b2 100644 --- a/dev/tools/Magento/Tools/Di/Code/Reader/ClassesScanner.php +++ b/dev/tools/Magento/Tools/Di/Code/Reader/ClassesScanner.php @@ -41,7 +41,7 @@ class ClassesScanner } $classes = []; $recursiveIterator = new \RecursiveIteratorIterator( - new \RecursiveDirectoryIterator($realPath), + new \RecursiveDirectoryIterator($realPath, \FilesystemIterator::FOLLOW_SYMLINKS), \RecursiveIteratorIterator::SELF_FIRST ); /** @var $fileItem \SplFileInfo */ diff --git a/dev/tools/Magento/Tools/Di/Compiler/Config/Reader.php b/dev/tools/Magento/Tools/Di/Compiler/Config/Reader.php index 8dca09ef4e27dacae6fbf977937939595c9b0851..f885f6fd12cd39318664c508c9d80c7c9a426a96 100644 --- a/dev/tools/Magento/Tools/Di/Compiler/Config/Reader.php +++ b/dev/tools/Magento/Tools/Di/Compiler/Config/Reader.php @@ -1,6 +1,5 @@ <?php /** - * * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ @@ -49,7 +48,7 @@ class Reader * @param Type $typeReader */ public function __construct( - \Magento\Framework\ObjectManager\ConfigInterface $diContainerConfig, + ConfigInterface $diContainerConfig, App\ObjectManager\ConfigLoader $configLoader, ArgumentsResolverFactory $argumentsResolverFactory, ClassReaderDecorator $classReaderDecorator, @@ -80,12 +79,15 @@ class Reader } $config = []; + + $this->fillThirdPartyInterfaces($areaConfig, $definitionsCollection); $config['arguments'] = $this->getConfigForScope($definitionsCollection, $areaConfig); foreach ($config['arguments'] as $key => $value) { if ($value !== null) { $config['arguments'][$key] = serialize($value); } } + foreach ($definitionsCollection->getInstancesNamesList() as $instanceName) { if (!$areaConfig->isShared($instanceName)) { $config['nonShared'][$instanceName] = true; @@ -95,6 +97,7 @@ class Reader $config['preferences'][$instanceName] = $preference; } } + foreach (array_keys($areaConfig->getVirtualTypes()) as $virtualType) { $config['instanceTypes'][$virtualType] = $areaConfig->getInstanceType($virtualType); } @@ -140,4 +143,26 @@ class Reader } return $constructors; } + + /** + * Returns preferences for third party code + * + * @param ConfigInterface $config + * @param DefinitionsCollection $definitionsCollection + * @SuppressWarnings(PHPMD.UnusedLocalVariable) + * + * @return void + */ + private function fillThirdPartyInterfaces(ConfigInterface $config, DefinitionsCollection $definitionsCollection) + { + $definedInstances = $definitionsCollection->getInstancesNamesList(); + + foreach ($config->getPreferences() as $interface => $preference) { + if (in_array($interface, $definedInstances)) { + continue; + } + + $definitionsCollection->addDefinition($interface, []); + } + } } diff --git a/dev/tools/Magento/Tools/Di/Definition/Collection.php b/dev/tools/Magento/Tools/Di/Definition/Collection.php index 82638c7c5578d862fd0a24485624fe7f82b96879..580f930d24cdd59584306f0cd3eb62e696f0a170 100644 --- a/dev/tools/Magento/Tools/Di/Definition/Collection.php +++ b/dev/tools/Magento/Tools/Di/Definition/Collection.php @@ -1,6 +1,5 @@ <?php /** - * * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ @@ -33,7 +32,7 @@ class Collection * * @return void */ - public function initialize($definitions) + public function initialize(array $definitions) { $this->definitions = $definitions; } @@ -54,7 +53,7 @@ class Collection * Add new definition for instance * * @param string $instance - * @param array $arguments + * @param array|null $arguments * * @return void */ @@ -67,7 +66,7 @@ class Collection * Returns instance arguments * * @param string $instanceName - * @return null + * @return null|array */ public function getInstanceArguments($instanceName) { diff --git a/dev/tools/performance-toolkit/README.txt b/dev/tools/performance-toolkit/README.txt index f4bf6427b5f14935dbaf419bb988b44a29bf5b96..0a94b4e4b38c845d0c51f1069f88a65c14e7ff10 100644 --- a/dev/tools/performance-toolkit/README.txt +++ b/dev/tools/performance-toolkit/README.txt @@ -4,19 +4,27 @@ Performance Toolkit Installation ----------- jMeter: --- go to http://jmeter.apache.org/download_jmeter.cgi and download jMeter in Source section (pay you attention that Java 6 or later is required) +-- go to http://jmeter.apache.org/download_jmeter.cgi and download jMeter in Binary section (pay you attention that Java 6 or later is required) -- unzip archive Plugins (only if you want to use additional reports (like graphs)): -- go to http://jmeter-plugins.org/downloads/all/ and download JMeterPlugins-Standard and JMeterPlugins-Extras -- unzip them to appropriate ext directory of your jMeter instance. +-- additional reports can now be enabled via GUI (right click them, then click Enable) or editing the jMeter JMX XML (set 'enabled="true"'). Usage ----------- +Before running the jMeter tests for the first time, you will need to first use generate.php to generate the test data. + +If you do not wish to use performance metrics gathered from the server(s) (such as CPU / IO load), or do not wish to configure the jMeter metric gathering software on your server(s), you can disable that either via the GUI (right click on "Performance Metrics Collector" and click Disable) or by editing the jMeter JMX XML from: +<kg.apc.jmeter.perfmon.PerfMonCollector guiclass="kg.apc.jmeter.vizualizers.PerfMonGui" testclass="kg.apc.jmeter.perfmon.PerfMonCollector" testname="Performance Metrics Collector" enabled="true"> +to: +<kg.apc.jmeter.perfmon.PerfMonCollector guiclass="kg.apc.jmeter.vizualizers.PerfMonGui" testclass="kg.apc.jmeter.perfmon.PerfMonCollector" testname="Performance Metrics Collector" enabled="false"> +Attempting to run with Performance Metrics Collector enabled without appropriately configuring it will result in a timeout error connecting to the collector and the test not running. 1. Run via console -Scenario can accept 5 parameters that are described bellow in format <parameter_name:default_value>: +Scenario can accept parameters that are described bellow in format <parameter_name:default_value>: <host:''> URL component 'host' of application being tested (URL or IP). <base_path:'/'> Base path for tested site. @@ -24,6 +32,18 @@ Scenario can accept 5 parameters that are described bellow in format <parameter_ <ramp_period:300> Ramp period (seconds). Period the request will be distributed within. <orders:0> Number of orders in the period specified in the current allocation. If <orders> is specified, the <users> parameter will be recalculated. <report_save_path:./> Path where reports will be saved. Reports will be saved in current working directory by default. +<admin_path:backend/> Admin backend path. Default is backend. +<admin_user:admin/> Admin backend user. Default is admin. +<admin_password:123123q/> Admin backend password. Default is 123123q. +<view_product_add_to_cart_percent:62/> Percentage of users that will only reach the add to cart stage. Default is 62. +<view_catalog_percent:30/> Percentage of users that will only reach the view catalog stage. Default is 30. +<guest_checkout_percent:4/> Percentage of users that will reach the guest checkout stage. Default is 4. +<customer_checkout_percent:4/> Percentage of users that will reach the (logged-in) customer checkout stage. Default is 4. +<loops:1/> Number of loops to run. Default is 1. +<jmeter_agent_port:3450/> jMeter agent port. Default is 3450. +<db_server_ip:10.62.51.150/> DB Server IP (for jMeter Performance Metrics). Default is 10.62.51.150. +<web_server_1_ip:10.62.51.185/> Web Server 1 IP (for jMeter Performance Metrics). Default is 10.62.51.185. +<web_server_2_ip:10.62.51.186/> Web Server 2 IP (for jMeter Performance Metrics). Default is 10.62.51.186. All parameters must be passed to command line with "J" prefix: "-J<parameter_name>=<parameter_value>" diff --git a/lib/internal/Magento/Framework/Composer/MagentoComponent.php b/lib/internal/Magento/Framework/Composer/MagentoComponent.php new file mode 100644 index 0000000000000000000000000000000000000000..5e2da7bfa557e166d6f45e04efd1a584dac92a30 --- /dev/null +++ b/lib/internal/Magento/Framework/Composer/MagentoComponent.php @@ -0,0 +1,30 @@ +<?php +/** + * Copyright © 2015 Magento. All rights reserved. + * See COPYING.txt for license details. + */ +namespace Magento\Framework\Composer; + +class MagentoComponent +{ + /** + * Get matched Magento component or empty array, if it's not a Magento component + * + * @param string $key + * @return string[] ['type' => '<type>', 'area' => '<area>', 'name' => '<name>'] + * Ex.: ['type' => 'module', 'name' => 'catalog'] + * ['type' => 'theme', 'area' => 'frontend', 'name' => 'blank'] + */ + public static function matchMagentoComponent($key) + { + $typePattern = 'module|theme|language|framework'; + $areaPattern = 'frontend|adminhtml'; + $namePattern = '[a-z_-]+'; + $regex = '/^magento\/(?P<type>' . $typePattern . ')(?:-(?P<area>' . $areaPattern . '))?(?:-(?P<name>' + . $namePattern . '))?$/'; + if (preg_match($regex, $key, $matches)) { + return $matches; + } + return []; + } +} diff --git a/lib/internal/Magento/Framework/Composer/README.md b/lib/internal/Magento/Framework/Composer/README.md new file mode 100644 index 0000000000000000000000000000000000000000..fc92f73c2db20310df2d28e92c12972b78c8f80d --- /dev/null +++ b/lib/internal/Magento/Framework/Composer/README.md @@ -0,0 +1,2 @@ +**Magento\Framework\Composer** provides Magento-specific features for working with packages. + For example, ability to distinguish Magento package and any other package. diff --git a/lib/internal/Magento/Framework/Filesystem.php b/lib/internal/Magento/Framework/Filesystem.php index e55ea9d8b2dfadc626b6145a5b98423f1daa150e..6c4e7de35c2833b927ae99aecc83801bdff82ec3 100644 --- a/lib/internal/Magento/Framework/Filesystem.php +++ b/lib/internal/Magento/Framework/Filesystem.php @@ -7,7 +7,7 @@ */ namespace Magento\Framework; -use Magento\Framework\Filesystem\File\ReadInterface; +use Magento\Framework\Filesystem\DriverPool; class Filesystem { @@ -52,30 +52,34 @@ class Filesystem } /** - * Create an instance of directory with write permissions + * Create an instance of directory with read permissions * - * @param string $code + * @param string $directoryCode + * @param string $driverCode * @return \Magento\Framework\Filesystem\Directory\ReadInterface */ - public function getDirectoryRead($code) + public function getDirectoryRead($directoryCode, $driverCode = DriverPool::FILE) { + $code = $directoryCode . '_' . $driverCode; if (!array_key_exists($code, $this->readInstances)) { - $this->readInstances[$code] = $this->readFactory->create($this->getDirPath($code)); + $this->readInstances[$code] = $this->readFactory->create($this->getDirPath($directoryCode), $driverCode); } return $this->readInstances[$code]; } /** - * Create an instance of directory with read permissions + * Create an instance of directory with write permissions * - * @param string $code + * @param string $directoryCode + * @param string $driverCode * @return \Magento\Framework\Filesystem\Directory\WriteInterface * @throws \Magento\Framework\Filesystem\FilesystemException */ - public function getDirectoryWrite($code) + public function getDirectoryWrite($directoryCode, $driverCode = DriverPool::FILE) { + $code = $directoryCode . '_' . $driverCode; if (!array_key_exists($code, $this->writeInstances)) { - $this->writeInstances[$code] = $this->writeFactory->create($this->getDirPath($code)); + $this->writeInstances[$code] = $this->writeFactory->create($this->getDirPath($directoryCode), $driverCode); } return $this->writeInstances[$code]; } diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/Read.php b/lib/internal/Magento/Framework/Filesystem/Directory/Read.php index 3d10c9741cd2760926d7bbcf1075a69ac6ef4000..33f09a43d326f99fc3fbce2df3f04b573f922db6 100644 --- a/lib/internal/Magento/Framework/Filesystem/Directory/Read.php +++ b/lib/internal/Magento/Framework/Filesystem/Directory/Read.php @@ -181,15 +181,13 @@ class Read implements ReadInterface * Open file in read mode * * @param string $path - * @param string|null $protocol * * @return \Magento\Framework\Filesystem\File\ReadInterface */ - public function openFile($path, $protocol = null) + public function openFile($path) { return $this->fileFactory->create( $this->driver->getAbsolutePath($this->path, $path), - $protocol, $this->driver ); } @@ -200,21 +198,14 @@ class Read implements ReadInterface * @param string $path * @param string|null $flag * @param resource|null $context - * @param string|null $protocol * @return string * @throws FilesystemException */ - public function readFile($path, $flag = null, $context = null, $protocol = null) + public function readFile($path, $flag = null, $context = null) { - $absolutePath = $this->driver->getAbsolutePath($this->path, $path, $protocol); + $absolutePath = $this->driver->getAbsolutePath($this->path, $path); + return $this->driver->fileGetContents($absolutePath, $flag, $context); - if (is_null($protocol)) { - return $this->driver->fileGetContents($absolutePath, $flag, $context); - } - - /** @var \Magento\Framework\Filesystem\File\Read $fileReader */ - $fileReader = $this->fileFactory->create($absolutePath, $protocol, $this->driver); - return $fileReader->readAll($flag, $context); } /** diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/ReadFactory.php b/lib/internal/Magento/Framework/Filesystem/Directory/ReadFactory.php index 423ed6166a3c33f8b5f092343713ad3e3276c11b..e1a9b33ab7a97db6d71aa51a31bc479f4875d215 100644 --- a/lib/internal/Magento/Framework/Filesystem/Directory/ReadFactory.php +++ b/lib/internal/Magento/Framework/Filesystem/Directory/ReadFactory.php @@ -30,12 +30,12 @@ class ReadFactory * Create a readable directory * * @param string $path - * @param string $protocol + * @param string $driverCode * @return ReadInterface */ - public function create($path, $protocol = DriverPool::FILE) + public function create($path, $driverCode = DriverPool::FILE) { - $driver = $this->driverPool->getDriver($protocol); + $driver = $this->driverPool->getDriver($driverCode); $factory = new \Magento\Framework\Filesystem\File\ReadFactory($this->driverPool); return new Read($factory, $driver, $path); } diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/Write.php b/lib/internal/Magento/Framework/Filesystem/Directory/Write.php index 6657360dc2a50b2e5f1bbec558b36c6a50b96ce2..18ff07a750e53fdcfad8d4af7cee94cf6d59507e 100644 --- a/lib/internal/Magento/Framework/Filesystem/Directory/Write.php +++ b/lib/internal/Magento/Framework/Filesystem/Directory/Write.php @@ -197,16 +197,15 @@ class Write extends Read implements WriteInterface * * @param string $path * @param string $mode - * @param string|null $protocol * @return \Magento\Framework\Filesystem\File\WriteInterface */ - public function openFile($path, $mode = 'w', $protocol = null) + public function openFile($path, $mode = 'w') { $folder = dirname($path); $this->create($folder); $this->assertWritable($folder); $absolutePath = $this->driver->getAbsolutePath($this->path, $path); - return $this->fileFactory->create($absolutePath, $protocol, $this->driver, $mode); + return $this->fileFactory->create($absolutePath, $this->driver, $mode); } /** @@ -215,13 +214,12 @@ class Write extends Read implements WriteInterface * @param string $path * @param string $content * @param string|null $mode - * @param string|null $protocol * @return int The number of bytes that were written. * @throws FilesystemException */ - public function writeFile($path, $content, $mode = 'w+', $protocol = null) + public function writeFile($path, $content, $mode = 'w+') { - return $this->openFile($path, $mode, $protocol)->write($content); + return $this->openFile($path, $mode)->write($content); } /** diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/WriteFactory.php b/lib/internal/Magento/Framework/Filesystem/Directory/WriteFactory.php index 4585629cd98a382b1d9af12e186b27248ca26ee8..809d86bb20bc0fb59cf7ae911acced7c045c9553 100644 --- a/lib/internal/Magento/Framework/Filesystem/Directory/WriteFactory.php +++ b/lib/internal/Magento/Framework/Filesystem/Directory/WriteFactory.php @@ -30,13 +30,13 @@ class WriteFactory * Create a readable directory * * @param string $path - * @param string $protocol + * @param string $driverCode * @param int $createPermissions * @return \Magento\Framework\Filesystem\Directory\Write */ - public function create($path, $protocol = DriverPool::FILE, $createPermissions = null) + public function create($path, $driverCode = DriverPool::FILE, $createPermissions = null) { - $driver = $this->driverPool->getDriver($protocol); + $driver = $this->driverPool->getDriver($driverCode); $factory = new \Magento\Framework\Filesystem\File\WriteFactory($this->driverPool); return new Write($factory, $driver, $path, $createPermissions); } diff --git a/lib/internal/Magento/Framework/Filesystem/Directory/WriteInterface.php b/lib/internal/Magento/Framework/Filesystem/Directory/WriteInterface.php index df05fb18b13dce1c958b185009ad8635074dceac..ba46d247d4870a596a7c5affaf0bda21d97bca1e 100644 --- a/lib/internal/Magento/Framework/Filesystem/Directory/WriteInterface.php +++ b/lib/internal/Magento/Framework/Filesystem/Directory/WriteInterface.php @@ -80,10 +80,9 @@ interface WriteInterface extends ReadInterface * * @param string $path * @param string $mode - * @param string|null $protocol * @return \Magento\Framework\Filesystem\File\WriteInterface */ - public function openFile($path, $mode = 'w', $protocol = null); + public function openFile($path, $mode = 'w'); /** * Open file in given path diff --git a/lib/internal/Magento/Framework/Filesystem/File/ReadFactory.php b/lib/internal/Magento/Framework/Filesystem/File/ReadFactory.php index d142ee2a284100dfbf2b12ade18c99a82fc63475..0c758ce471dfbe4d75d6cb0e065f7b14d65c394d 100644 --- a/lib/internal/Magento/Framework/Filesystem/File/ReadFactory.php +++ b/lib/internal/Magento/Framework/Filesystem/File/ReadFactory.php @@ -31,17 +31,13 @@ class ReadFactory * Create a readable file * * @param string $path - * @param string|null $protocol [optional] - * @param DriverInterface $driver [optional] + * @param DriverInterface|string $driver Driver or driver code * @return \Magento\Framework\Filesystem\File\ReadInterface - * @throws \InvalidArgumentException */ - public function create($path, $protocol = null, DriverInterface $driver = null) + public function create($path, $driver) { - if ($protocol) { - $driver = $this->driverPool->getDriver($protocol); - } elseif (!$driver) { - throw new \InvalidArgumentException('Either driver or protocol must be specified.'); + if (is_string($driver)) { + return new Read($path, $this->driverPool->getDriver($driver)); } return new Read($path, $driver); } diff --git a/lib/internal/Magento/Framework/Filesystem/File/WriteFactory.php b/lib/internal/Magento/Framework/Filesystem/File/WriteFactory.php index 95a764a0e41966a124fec248077373891bebedae..1f0fe8066c55709b0c97287232c3ccd9e8cd56d1 100644 --- a/lib/internal/Magento/Framework/Filesystem/File/WriteFactory.php +++ b/lib/internal/Magento/Framework/Filesystem/File/WriteFactory.php @@ -31,18 +31,14 @@ class WriteFactory * Create a readable file. * * @param string $path - * @param string|null $protocol [optional] - * @param DriverInterface $driver [optional] + * @param DriverInterface|string $driver Driver or driver code * @param string $mode [optional] * @return Write - * @throws \InvalidArgumentException */ - public function create($path, $protocol = null, DriverInterface $driver = null, $mode = 'r') + public function create($path, $driver, $mode = 'r') { - if ($protocol) { - $driver = $this->driverPool->getDriver($protocol); - } elseif (!$driver) { - throw new \InvalidArgumentException('Either driver or protocol must be specified.'); + if (is_string($driver)) { + return new Write($path, $this->driverPool->getDriver($driver), $mode); } return new Write($path, $driver, $mode); } diff --git a/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php b/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php index 131e4bfcbaad6a2de4b200e3727b5b25288fd901..a7484882066437cbb5d5a97c4cdd15bf1cb474b5 100644 --- a/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php +++ b/lib/internal/Magento/Framework/ObjectManager/Config/Compiled.php @@ -145,4 +145,14 @@ class Compiled implements \Magento\Framework\ObjectManager\ConfigInterface { return $this->virtualTypes; } + + /** + * Returns list on preferences + * + * @return array + */ + public function getPreferences() + { + return $this->preferences; + } } diff --git a/lib/internal/Magento/Framework/ObjectManager/Config/Config.php b/lib/internal/Magento/Framework/ObjectManager/Config/Config.php index 29c0432bdc56d37950003bda1d2092931dd7d09b..6f05e61be5351ae55fd2b9fcc9742b042491b9ae 100644 --- a/lib/internal/Magento/Framework/ObjectManager/Config/Config.php +++ b/lib/internal/Magento/Framework/ObjectManager/Config/Config.php @@ -313,4 +313,14 @@ class Config implements \Magento\Framework\ObjectManager\ConfigInterface { return $this->_virtualTypes; } + + /** + * Returns list on preferences + * + * @return array + */ + public function getPreferences() + { + return $this->_preferences; + } } diff --git a/lib/internal/Magento/Framework/ObjectManager/ConfigInterface.php b/lib/internal/Magento/Framework/ObjectManager/ConfigInterface.php index 9e023fcc5e3e85a94f9855b0741edc5598628d80..8f8f91297dc2a9ef69417f9419b10caf31759a95 100644 --- a/lib/internal/Magento/Framework/ObjectManager/ConfigInterface.php +++ b/lib/internal/Magento/Framework/ObjectManager/ConfigInterface.php @@ -72,4 +72,11 @@ interface ConfigInterface * @return void */ public function extend(array $configuration); + + /** + * Returns list on preferences + * + * @return array + */ + public function getPreferences(); } diff --git a/lib/internal/Magento/Framework/Pricing/Price/Collection.php b/lib/internal/Magento/Framework/Pricing/Price/Collection.php index e0d9fbe0cf8947c3589aa933b44dbfc18a121b88..d9bd5730df654a221f4cf22e835394111a08dad5 100644 --- a/lib/internal/Magento/Framework/Pricing/Price/Collection.php +++ b/lib/internal/Magento/Framework/Pricing/Price/Collection.php @@ -43,6 +43,13 @@ class Collection implements \Iterator */ protected $excludes; + /** + * Cached price models + * + * @var array + */ + protected $priceModels; + /** * Constructor * @@ -61,6 +68,7 @@ class Collection implements \Iterator $this->priceFactory = $priceFactory; $this->pool = $pool; $this->quantity = $quantity; + $this->priceModels = []; } /** @@ -121,10 +129,13 @@ class Collection implements \Iterator */ public function get($code) { - return $this->priceFactory->create( - $this->saleableItem, - $this->pool[$code], - $this->quantity - ); + if (!isset($this->priceModels[$code])) { + $this->priceModels[$code] = $this->priceFactory->create( + $this->saleableItem, + $this->pool[$code], + $this->quantity + ); + } + return $this->priceModels[$code]; } } diff --git a/lib/internal/Magento/Framework/Pricing/PriceCurrencyInterface.php b/lib/internal/Magento/Framework/Pricing/PriceCurrencyInterface.php index aa86b245666d2e54f6b30df498ff93a19eb08795..9a0c8b2925b027ea2f72dfe536820fe2d3888181 100644 --- a/lib/internal/Magento/Framework/Pricing/PriceCurrencyInterface.php +++ b/lib/internal/Magento/Framework/Pricing/PriceCurrencyInterface.php @@ -30,12 +30,12 @@ interface PriceCurrencyInterface * Convert and round price value * * @param float $amount - * @param null|string|bool|int|\Magento\Store\Model\Store $store - * @param \Magento\Directory\Model\Currency|string|null $currency + * @param null|string|bool|int|\Magento\Framework\App\ScopeInterface $scope + * @param \Magento\Framework\Model\AbstractModel|string|null $currency * @param int $precision * @return float */ - public function convertAndRound($amount, $store = null, $currency = null, $precision = self::DEFAULT_PRECISION); + public function convertAndRound($amount, $scope = null, $currency = null, $precision = self::DEFAULT_PRECISION); /** * Format price value diff --git a/app/code/Magento/Core/Model/Validator/Factory.php b/lib/internal/Magento/Framework/Validator/Factory.php similarity index 98% rename from app/code/Magento/Core/Model/Validator/Factory.php rename to lib/internal/Magento/Framework/Validator/Factory.php index 87417f739e0726e41e68af83b94a16e0a5fd5646..42a9960c9de8ad210064b82ad1748673f0b4d956 100644 --- a/app/code/Magento/Core/Model/Validator/Factory.php +++ b/lib/internal/Magento/Framework/Validator/Factory.php @@ -5,7 +5,7 @@ * Copyright © 2015 Magento. All rights reserved. * See COPYING.txt for license details. */ -namespace Magento\Core\Model\Validator; +namespace Magento\Framework\Validator; class Factory { diff --git a/lib/internal/Magento/Framework/View/Layout/Reader/Block.php b/lib/internal/Magento/Framework/View/Layout/Reader/Block.php index ecc0b9c45405785294cdd89e1135307617391613..40bea712b9d27748e919b487d92389515b281c54 100644 --- a/lib/internal/Magento/Framework/View/Layout/Reader/Block.php +++ b/lib/internal/Magento/Framework/View/Layout/Reader/Block.php @@ -121,7 +121,8 @@ class Block implements Layout\ReaderInterface default: break; } - return $this->readerPool->interpret($readerContext, $currentElement); + $this->readerPool->interpret($readerContext, $currentElement); + return $this; } /** @@ -174,7 +175,7 @@ class Block implements Layout\ReaderInterface * Update data for scheduled element * * @param Layout\Element $currentElement - * @param array $data + * @param array &$data * @return array */ protected function updateScheduledData($currentElement, array &$data) diff --git a/lib/web/mage/adminhtml/form.js b/lib/web/mage/adminhtml/form.js index c6fed3aa5fc4f17ddda44a33da83d997ec122b8f..e266ece372ac4c8abda7a7b74b2b582eeffe1ed8 100644 --- a/lib/web/mage/adminhtml/form.js +++ b/lib/web/mage/adminhtml/form.js @@ -458,7 +458,7 @@ FormElementDependenceController.prototype = { } } else { $(idTo).show(); - if (isAnInputOrSelect) { + if (isAnInputOrSelect && !isInheritCheckboxChecked) { $(idTo).disabled = false; jQuery('#' + idTo).removeClass('ignore-validate'); }