Skip to content

Commit

Permalink
merge magento/2.3-develop into magento-honey-badgers/MAGETWO-8709
Browse files Browse the repository at this point in the history
  • Loading branch information
Magento CICD authored Jul 17, 2018
2 parents 525308c + 91e10cd commit c1a3261
Show file tree
Hide file tree
Showing 145 changed files with 1,212 additions and 169 deletions.
2 changes: 1 addition & 1 deletion app/code/Magento/AdvancedSearch/Block/SearchData.php
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ abstract class SearchData extends Template implements SearchDataInterface
/**
* @var string
*/
protected $_template = 'search_data.phtml';
protected $_template = 'Magento_AdvancedSearch::search_data.phtml';

/**
* @param Template\Context $context
Expand Down
20 changes: 12 additions & 8 deletions app/code/Magento/Backend/Block/Widget/Form/Element/Dependence.php
Original file line number Diff line number Diff line change
Expand Up @@ -124,14 +124,18 @@ protected function _toHtml()
if (!$this->_depends) {
return '';
}
return '<script>
require(["mage/adminhtml/form"], function(){
new FormElementDependenceController(' .
$this->_getDependsJson() .
($this->_configOptions ? ', ' .
$this->_jsonEncoder->encode(
$this->_configOptions
) : '') . '); });</script>';

$params = $this->_getDependsJson();

if ($this->_configOptions) {
$params .= ', ' . $this->_jsonEncoder->encode($this->_configOptions);
}

return "<script>
require(['mage/adminhtml/form'], function(){
new FormElementDependenceController({$params});
});
</script>";
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@
<section name="AdminMessagesSection">
<element name="success" type="text" selector="#messages div.message-success"/>
<element name="nthSuccess" type="text" selector=".message.message-success.success:nth-of-type({{n}})>div" parameterized="true"/>
<element name="error" type="text" selector="#messages div.message-error"/>
</section>
</sections>
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
<!-- Add Bundle Product to Cart from the category page with specified quantity to cart -->
<actionGroup name="StorefrontAddCategoryBundleProductToCartActionGroup">
<arguments>
<argument name="product"/>
<argument name="quantity" defaultValue="1" type="string"/>
</arguments>
<moveMouseOver selector="{{StorefrontCategoryProductSection.ProductInfoByName(product.name)}}" stepKey="moveMouseOverProduct" />
<click selector="{{StorefrontCategoryProductSection.ProductAddToCartByName(product.name)}}" stepKey="clickAddToCart" />
<waitForPageLoad time="30" stepKey="waitForPageLoad1"/>
<click selector="{{StorefrontBundleProductActionSection.customizeAndAddToCartButton}}" stepKey="clickCustomizeAndAddToCart"/>
<waitForPageLoad time="30" stepKey="waitForPageLoad2"/>
<fillField selector="{{StorefrontBundleProductActionSection.quantityField}}" userInput="{{quantity}}" stepKey="fillBundleProductQuantity"/>
<click selector="{{StorefrontBundleProductActionSection.addToCartButton}}" stepKey="clickAddBundleProductToCart"/>
<waitForPageLoad time="30" stepKey="waitForPageLoad3"/>
<waitForText userInput="{{quantity}}" selector="{{StorefrontMinicartSection.productCount}}" time="30" stepKey="assertProductCount"/>
</actionGroup>
</actionGroups>
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
<section name="StorefrontBundleProductActionSection">
<element name="customizeAndAddToCartButton" type="button" selector="#bundle-slide"/>
<element name="quantityField" type="input" selector="#qty"/>
<element name="addToCartButton" type="button" selector="#product-addtocart-button"/>
</section>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -75,11 +75,16 @@
<seeElement stepKey="LookingForNameOfProduct" selector="{{BundleStorefrontSection.bundleProductName}}"/>

<!--Testing disabled view-->
<actionGroup ref="FindProductToEdit" stepKey="FindProductEditPage"/>
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="GoToProductCatalog"/>
<waitForPageLoad stepKey="WaitForCatalogProductPageToLoad"/>
<actionGroup ref="filterProductGridBySku" stepKey="FindProductEditPage">
<argument name="product" value="BundleProduct"/>
</actionGroup>
<click selector="{{AdminDataGridTableSection.rowViewAction('1')}}" stepKey="ClickProductInGrid"/>
<click stepKey="ClickOnEnableDisableToggle" selector="{{AdminProductFormBundleSection.enableDisableToggle}}"/>
<click selector="{{AdminProductFormActionSection.saveButton}}" stepKey="clickSaveButtonAgain"/>
<seeElement selector="{{AdminCategoryMessagesSection.SuccessMessage}}" stepKey="messageYouSavedTheProductIsShown2"/>
<waitForPageLoad stepKey="PauseForSave"/>
<see selector="{{AdminCategoryMessagesSection.SuccessMessage}}" userInput="You saved the product." stepKey="messageYouSavedTheProductIsShownAgain"/>
<amOnPage url="{{BundleProduct.urlKey}}.html" stepKey="GoToProductPageAgain"/>
<waitForPageLoad stepKey="WaitForProductPageToLoadToShowElement"/>
<dontSeeElement stepKey="LookingForNameOfProductTwo" selector="{{BundleStorefrontSection.bundleProductName}}"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ class Attribute extends \Magento\Backend\Block\Template
/**
* @var string
*/
protected $_template = 'catalog/product/attribute/set/main/tree/attribute.phtml';
protected $_template = 'Magento_Catalog::catalog/product/attribute/set/main/tree/attribute.phtml';
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@
<element name="backButton" type="button" selector="#back" timeout="30"/>
<element name="saveButton" type="button" selector="#save-button" timeout="30"/>
<element name="saveArrow" type="button" selector="button[data-ui-id='save-button-dropdown']" timeout="30"/>
<!--<element name="saveAndClose" type="button" selector="span[title='Save &amp; Close']" timeout="30"/>-->
<element name="saveAndClose" type="button" selector="span[id='save_and_close']" timeout="30"/>
<element name="saveAndClose" type="button" selector="span[title='Save &amp; Close']" timeout="30"/>
<element name="changeStoreButton" type="button" selector="#store-change-button" timeout="10"/>
<element name="selectStoreView" type="button" selector="//ul[@data-role='stores-list']/li/a[normalize-space(.)='{{var1}}']" timeout="10" parameterized="true"/>
</section>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@

<!--Create Store view -->
<amOnPage url="{{AdminSystemStorePage.url}}" stepKey="amOnAdminSystemStorePage"/>
<waitForElementVisible selector="{{AdminStoresMainActionsSection.createStoreViewButton}}" stepKey="waitForStoreViewBtn"/>
<click selector="{{AdminStoresMainActionsSection.createStoreViewButton}}" stepKey="createStoreViewButton"/>
<waitForPageLoad stepKey="waitForProductPageLoad"/>
<selectOption userInput="Second Store" selector="{{AdminNewStoreSection.storeGrpDropdown}}" stepKey="selectStoreGroup"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,24 @@
<waitForText userInput="{{productCount}}" selector="{{StorefrontMinicartSection.productCount}}" time="30" stepKey="assertProductCount"/>
</actionGroup>

<!-- Add Product to Cart from the category page with specified quantity and check message and product count in Minicart -->
<actionGroup name="StorefrontAddCategoryProductToCartWithQuantityActionGroup">
<arguments>
<argument name="product"/>
<argument name="quantity" defaultValue="1" type="string"/>
<argument name="checkQuantity" defaultValue="1" type="string"/>
</arguments>
<moveMouseOver selector="{{StorefrontCategoryProductSection.ProductInfoByName(product.name)}}" stepKey="moveMouseOverProduct" />
<click selector="{{StorefrontCategoryProductSection.ProductAddToCartByName(product.name)}}" stepKey="clickAddToCart" />
<!-- @TODO: Use general message selector after MQE-694 is fixed -->
<waitForElement selector="{{StorefrontMessagesSection.messageProductAddedToCart(product.name)}}" time="30" stepKey="assertMessage"/>
<waitForText userInput="{{checkQuantity}}" selector="{{StorefrontMinicartSection.productCount}}" time="30" stepKey="assertProductCount"/>
<conditionalClick selector="{{StorefrontMinicartSection.showCart}}" dependentSelector="{{StorefrontMinicartSection.miniCartOpened}}" visible="false" stepKey="openMiniCart"/>
<waitForElementVisible selector="{{StorefrontMinicartSection.viewAndEditCart}}" stepKey="waitForViewAndEditCartVisible"/>
<fillField selector="{{StorefrontMinicartSection.itemQuantity(product.name)}}" userInput="{{quantity}}" stepKey="setProductQtyToFiftyInMiniCart"/>
<click selector="{{StorefrontMinicartSection.itemQuantityUpdate(product.name)}}" stepKey="updateQtyInMiniCart"/>
</actionGroup>

<!-- Add Product to Cart from the product page and check message and product count in Minicart -->
<actionGroup name="StorefrontAddProductToCartActionGroup">
<arguments>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,7 @@
<element name="viewAndEditCart" type="button" selector=".action.viewcart" timeout="30"/>
<element name="miniCartItemsText" type="text" selector=".minicart-items"/>
<element name="deleteMiniCartItem" type="button" selector=".action.delete" timeout="30"/>
<element name="itemQuantity" type="input" selector="//a[text()='{{productName}}']/../..//input[contains(@class,'cart-item-qty')]" parameterized="true"/>
<element name="itemQuantityUpdate" type="button" selector="//a[text()='{{productName}}']/../..//span[text()='Update']" parameterized="true"/>
</section>
</sections>
4 changes: 4 additions & 0 deletions app/code/Magento/Checkout/etc/adminhtml/system.xml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,10 @@
<field id="number_items_to_display_pager" translate="label" type="text" sortOrder="2" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1">
<label>Number of Items to Display Pager</label>
</field>
<field id="crosssell_enabled" translate="label" type="select" sortOrder="3" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1">
<label>Show Cross-sell Items in the Shopping Cart</label>
<source_model>Magento\Config\Model\Config\Source\Yesno</source_model>
</field>
</group>
<group id="cart_link" translate="label" sortOrder="3" showInDefault="1" showInWebsite="1" showInStore="0">
<label>My Cart Link</label>
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Checkout/etc/config.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
<delete_quote_after>30</delete_quote_after>
<redirect_to_cart>0</redirect_to_cart>
<number_items_to_display_pager>20</number_items_to_display_pager>
<crosssell_enabled>1</crosssell_enabled>
</cart>
<cart_link>
<use_qty>1</use_qty>
Expand Down
1 change: 1 addition & 0 deletions app/code/Magento/Checkout/i18n/en_US.csv
Original file line number Diff line number Diff line change
Expand Up @@ -181,3 +181,4 @@ Payment,Payment
"Item in Cart","Item in Cart"
"Items in Cart","Items in Cart"
"Close","Close"
"Show Cross-sell Items in the Shopping Cart","Show Cross-sell Items in the Shopping Cart"
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@
</block>
<container name="checkout.cart.widget" as="checkout_cart_widget" label="Shopping Cart Items After"/>
</container>
<block class="Magento\Checkout\Block\Cart\Crosssell" name="checkout.cart.crosssell" template="Magento_Catalog::product/list/items.phtml" after="-">
<block class="Magento\Checkout\Block\Cart\Crosssell" name="checkout.cart.crosssell" template="Magento_Catalog::product/list/items.phtml" after="-" ifconfig="checkout/cart/crosssell_enabled">
<arguments>
<argument name="type" xsi:type="string">crosssell</argument>
</arguments>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
<actionGroup name="SetTaxClassForShipping">
<amOnPage url="{{AdminSalesTaxClassPage.url}}" stepKey="navigateToSalesTaxPage"/>
<waitForPageLoad stepKey="waitForPageLoad"/>
<conditionalClick selector="{{SalesConfigSection.TaxClassesTab}}" dependentSelector="{{SalesConfigSection.CheckIfTaxClassesTabExpand}}" visible="true" stepKey="expandTaxClassesTab"/>
<waitForElementVisible selector="{{SalesConfigSection.ShippingTaxClass}}" stepKey="seeShippingTaxClass"/>
<uncheckOption selector="{{SalesConfigSection.EnableTaxClassForShipping}}" stepKey="uncheckUseSystemValue"/>
<selectOption selector="{{SalesConfigSection.ShippingTaxClass}}" userInput="Taxable Goods" stepKey="setShippingTaxClass"/>
<click selector="{{SalesConfigSection.TaxClassesTab}}" stepKey="collapseTaxClassesTab"/>
<click selector="{{ContentManagementSection.Save}}" stepKey="saveConfig" />
</actionGroup>
<actionGroup name="ResetTaxClassForShipping">
<amOnPage url="{{AdminSalesTaxClassPage.url}}" stepKey="navigateToSalesTaxConfigPagetoReset"/>
<waitForPageLoad stepKey="waitForPageLoad2"/>
<conditionalClick selector="{{SalesConfigSection.TaxClassesTab}}" dependentSelector="{{SalesConfigSection.CheckIfTaxClassesTabExpand}}" visible="true" stepKey="openTaxClassTab"/>
<waitForElementVisible selector="{{SalesConfigSection.ShippingTaxClass}}" stepKey="seeShippingTaxClass2"/>
<selectOption selector="{{SalesConfigSection.ShippingTaxClass}}" userInput="None" stepKey="resetShippingTaxClass"/>
<checkOption selector="{{SalesConfigSection.EnableTaxClassForShipping}}" stepKey="useSystemValue"/>
<click selector="{{SalesConfigSection.TaxClassesTab}}" stepKey="collapseTaxClassesTab"/>
<click selector="{{ContentManagementSection.Save}}" stepKey="saveConfiguration"/>
</actionGroup>
</actionGroups>
3 changes: 3 additions & 0 deletions app/code/Magento/Config/Test/Mftf/Page/AdminConfigPage.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,7 @@
<page name="AdminContentManagementPage" url="admin/system_config/edit/section/cms/" area="admin" module="Magento_Config">
<section name="ContentManagementSection"/>
</page>
<page name="AdminSalesTaxClassPage" url="admin/system_config/edit/section/tax/" area="admin" module="Magento_Config">
<section name="SalesTaxClassSection"/>
</page>
</pages>
17 changes: 17 additions & 0 deletions app/code/Magento/Config/Test/Mftf/Section/SalesConfigSection.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
/**
* Copyright © Magento, Inc. All rights reserved.
* See COPYING.txt for license details.
*/
-->

<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
<section name="SalesConfigSection">
<element name="TaxClassesTab" type="button" selector="#tax_classes-head"/>
<element name="CheckIfTaxClassesTabExpand" type="button" selector="#tax_classes-head:not(.open)"/>
<element name="ShippingTaxClass" type="select" selector="#tax_classes_shipping_tax_class"/>
<element name="EnableTaxClassForShipping" type="checkbox" selector="#tax_classes_shipping_tax_class_inherit"/>
</section>
</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -31,11 +31,6 @@
<section name="AdminConfigurableProductSelectAttributesSlideOut">
<element name="grid" type="button" selector=".admin__data-grid-wrap tbody"/>
</section>
<section name="AdminConfigurableProductAssignSourcesSlideOut">
<element name="done" type="button" selector=".product_form_product_form_assign_sources_configurable_modal .action-primary" timeout="5"/>
<element name="assignSources" type="button" selector="(//button/span[contains(text(), 'Assign Sources')])[2]" timeout="5"/>
<element name="quantityPerSource" type="input" selector="input[name='quantity_resolver[dynamicRows][dynamicRows][0][quantity_per_source]']"/>
</section>
<section name="StorefrontConfigurableProductPage">
<element name="productAttributeDropDown" type="select" selector="select[id*='attribute']"/>
</section>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<system>
<section id="checkout">
<group id="cart">
<field id="configurable_product_image" translate="label" type="select" sortOrder="4" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1">
<field id="configurable_product_image" translate="label" type="select" sortOrder="5" showInDefault="1" showInWebsite="1" showInStore="1" canRestore="1">
<label>Configurable Product Image</label>
<source_model>Magento\Catalog\Model\Config\Source\Product\Thumbnail</source_model>
</field>
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Directory/etc/zip_codes.xml
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@
</zip>
<zip countryCode="IL">
<codes>
<code id="pattern_1" active="true" example="12345">^[0-9]{5}$</code>
<code id="pattern_1" active="true" example="6687865">^[0-9]{7}$</code>
</codes>
</zip>
<zip countryCode="IT">
Expand Down
2 changes: 1 addition & 1 deletion app/code/Magento/Eav/Block/Adminhtml/Attribute/Edit/Js.php
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ class Js extends \Magento\Backend\Block\Template
* @var string
*/

protected $_template = 'attribute/edit/js.phtml';
protected $_template = 'Magento_Eav::attribute/edit/js.phtml';

/**
* @var \Magento\Eav\Model\Adminhtml\System\Config\Source\Inputtype
Expand Down
6 changes: 5 additions & 1 deletion app/code/Magento/GraphQl/etc/schema.graphqls
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@
type Query {
}

type Mutation {
placeholderMutation: String @doc(description: "Mutation type cannot be declared without fields. The placeholder will be removed when at least one mutation field is declared.")
}

input FilterTypeInput @doc(description: "FilterTypeInput specifies which action will be performed in a query ") {
eq: String @doc(description: "Equals")
finset: [String] @doc(description: "Find in set. The value can contain a set of comma-separated values")
Expand All @@ -30,4 +34,4 @@ type SearchResultPageInfo @doc(description: "SearchResultPageInfo provides navig
enum SortEnum @doc(description: "This enumeration indicates whether to return results in ascending or descending order") {
ASC
DESC
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -43,4 +43,13 @@
<see selector="{{AdminProductGridSection.firstProductRow}}" userInput="{{product.name}}" stepKey="seeProductNameInGrid"/>
<click selector="{{AdminProductGridFilterSection.clearFilters}}" stepKey="clickClearFiltersAfter"/>
</actionGroup>

<!--Fill product min quantity in group products grid-->
<actionGroup name="fillDefaultQuantityForLinkedToGroupProductInGrid">
<arguments>
<argument name="productName" type="string"/>
<argument name="qty" type="string"/>
</arguments>
<fillField selector="{{AdminAddedProductsToGroupGrid.inputByProductName(productName)}}" userInput="{{qty}}" stepKey="fillDefaultQtyForLinkedProduct"/>
</actionGroup>
</actionGroups>
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,8 @@
<element name="firstCheckbox" type="input" selector="tr[data-repeat-index='0'] .admin__control-checkbox"/>
<element name="nThCheckbox" type="input" selector="tr[data-repeat-index='{{n}}'] .admin__control-checkbox" parameterized="true"/>
</section>

<section name="AdminAddedProductsToGroupGrid">
<element name="inputByProductName" type="input" selector="//div[@data-index='grouped']//table//tr[td[@data-index='name']//span[text()='{{productName}}']]//td[@data-index='qty']//input" parameterized="true"/>
</section>
</sections>
Loading

0 comments on commit c1a3261

Please sign in to comment.