Skip to content

Commit f30a14c

Browse files
committed
Merge remote-tracking branch 'origin/MAGETWO-82116' into 2.2-develop-pr30
2 parents b6f86db + 1d02973 commit f30a14c

14 files changed

+196
-1
lines changed

app/code/Magento/Ui/view/base/web/js/grid/filters/range.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,8 @@ define([
2727
},
2828
date: {
2929
component: 'Magento_Ui/js/form/element/date',
30-
dateFormat: 'MM/dd/YYYY'
30+
dateFormat: 'MM/dd/YYYY',
31+
shiftedValue: 'filter'
3132
},
3233
text: {
3334
component: 'Magento_Ui/js/form/element/abstract'
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/actionGroupSchema.xsd">
11+
<!--Filter the product grid by new from date filter-->
12+
<actionGroup name="filterProductGridBySetNewFromDate">
13+
<conditionalClick selector="{{AdminProductGridFilterSection.clearFilters}}" dependentSelector="{{AdminProductGridFilterSection.clearFilters}}" visible="true" stepKey="clickClearFilters"/>
14+
<click selector="{{AdminProductGridFilterSection.filters}}" stepKey="openProductFilters"/>
15+
<fillField selector="{{AdminProductGridFilterSection.newFromDateFilter}}" userInput="05/16/2018" stepKey="fillSetAsNewProductFilter"/>
16+
<click selector="{{AdminProductGridFilterSection.applyFilters}}" stepKey="clickApplyFilters"/>
17+
<waitForElementNotVisible selector="{{AdminProductGridSection.loadingMask}}" stepKey="waitForFilteredGridLoad" time="30"/>
18+
</actionGroup>
19+
</actionGroups>

dev/tests/acceptance/tests/functional/Magento/FunctionalTest/Catalog/Data/CustomAttributeData.xml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,4 +34,8 @@
3434
<data key="attribute_code">short_description</data>
3535
<data key="value" unique="suffix">API Product Short Description</data>
3636
</entity>
37+
<entity name="ApiProductNewsFromDate" type="custom_attribute">
38+
<data key="attribute_code">news_from_date</data>
39+
<data key="value">2018-05-17 00:00:00</data>
40+
</entity>
3741
</entities>

dev/tests/acceptance/tests/functional/Magento/FunctionalTest/Catalog/Data/ProductData.xml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -133,4 +133,18 @@
133133
<data key="status">1</data>
134134
<requiredEntity type="product_extension_attribute">EavStockItem</requiredEntity>
135135
</entity>
136+
<entity name="SimpleProductWithNewFromDate" type="product">
137+
<data key="sku" unique="suffix">SimpleProduct</data>
138+
<data key="type_id">simple</data>
139+
<data key="attribute_set_id">4</data>
140+
<data key="name" unique="suffix">SimpleProduct</data>
141+
<data key="price">125.00</data>
142+
<data key="visibility">4</data>
143+
<data key="status">1</data>
144+
<data key="quantity">1000</data>
145+
<data key="urlKey" unique="suffix">simpleproduct</data>
146+
<data key="weight">1</data>
147+
<requiredEntity type="product_extension_attribute">EavStockItem</requiredEntity>
148+
<requiredEntity type="custom_attribute_array">ApiProductNewsFromDate</requiredEntity>
149+
</entity>
136150
</entities>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
10+
<page name="ProductAttributePage" url="catalog/product_attribute/new/" area="admin" module="Catalog">
11+
<section name="AdminCreateProductAttributeSection"/>
12+
</page>
13+
</pages>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
<pages xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
9+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
10+
<page name="AdminProductAttributeGridPage" url="catalog/product_attribute" area="admin" module="Catalog">
11+
<section name="AdminProductAttributeGridSection"/>
12+
</page>
13+
</pages>

dev/tests/acceptance/tests/functional/Magento/FunctionalTest/Catalog/Page/AdminProductIndexPage.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/PageObject.xsd">
1111
<page name="AdminProductIndexPage" url="catalog/product/index" area="admin" module="Magento_Catalog">
1212
<section name="AdminProductGridActionSection" />
13+
<section name="AdminProductGridFilterSection" />
1314
<section name="AdminProductGridSection" />
1415
<section name="AdminMessagesSection" />
1516
<section name="AdminProductFiltersSection" />
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
9+
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
11+
<section name="AttributePropertiesSection">
12+
<element name="AdvancedProperties" type="button" selector="#advanced_fieldset-wrapper"/>
13+
<element name="Save" type="button" selector="#save"/>
14+
</section>
15+
</sections>
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
9+
<sections xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
11+
<section name="AdminProductAttributeGridSection">
12+
<element name="GridFilterFrontEndLabel" type="input" selector="#attributeGrid_filter_frontend_label"/>
13+
<element name="Search" type="button" selector="button[data-action=grid-filter-apply]" timeout="30"/>
14+
<element name="ResetFilter" type="button" selector="button[data-action='grid-filter-reset']" timeout="30"/>
15+
<element name="FirstRow" type="button" selector="//*[@id='attributeGrid_table']/tbody/tr[1]"/>
16+
</section>
17+
</sections>

dev/tests/acceptance/tests/functional/Magento/FunctionalTest/Catalog/Section/AdminProductFormActionSection.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Page/etc/SectionObject.xsd">
1111
<section name="AdminProductFormActionSection">
1212
<element name="saveButton" type="button" selector="#save-button" timeout="30"/>
13+
<element name="saveArrow" type="button" selector="button[data-ui-id='save-button-dropdown']" timeout="30"/>
14+
<element name="saveAndClose" type="button" selector="span[id='save_and_close']" timeout="30"/>
1315
<element name="changeStoreButton" type="button" selector="#store-change-button"/>
1416
<element name="selectStoreView" type="button" selector="//ul[@data-role='stores-list']/li/a[normalize-space(.)='{{var1}}']" timeout="10" parameterized="true"/>
1517
</section>

0 commit comments

Comments
 (0)