Skip to content
This repository was archived by the owner on Apr 29, 2019. It is now read-only.

Commit c01370d

Browse files
MAGETWO-91701: Newsletter subscription is not correctly updated when user is registered on 2 stores
- Updated automated test. Using Search Filter for deleting created customer.
1 parent 2cd1faf commit c01370d

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

app/code/Magento/Newsletter/Test/Mftf/ActionGroup/VerifySubscribedNewsletterDisplayedActionGroup.xml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -143,9 +143,12 @@
143143
<wait stepKey="WaitForCustomerViewOpened" time="2"/>
144144
<click stepKey="clickCustomerAllCustomerItem" selector="{{Dashboard.customerAllCustomer}}"/>
145145
<waitForPageLoad stepKey="WaitForCustomerPageIsLoaded"/>
146-
<fillField stepKey="searchToKeyword" selector="{{AdminCustomerAccountInformationSection.searchToKeyword}}" userInput="{{CreateUserData.firstName}}"/>
147-
<click stepKey="clickSearchButton" selector="{{AdminCustomerAccountInformationSection.searchButton}}"/>
148-
<waitForElementVisible stepKey="waitForFiltering" selector="{{AdminCustomerAccountInformationSection.selectCustomer}}"/>
146+
<conditionalClick selector="{{AdminCustomerAccountInformationSection.clearAll}}" dependentSelector="{{AdminCustomerAccountInformationSection.clearAll}}" visible="1" stepKey="clickClearAllIfThereIsAnyValue"/>
147+
<click stepKey="clickFilterButton" selector="{{AdminCustomerAccountInformationSection.filterButton}}"/>
148+
<waitForElementVisible selector="{{AdminCustomerAccountInformationSection.filterNameField}}" stepKey="waitForFilterDataLoaded"/>
149+
<fillField stepKey="searchProductUsingNameField" selector="{{AdminCustomerAccountInformationSection.filterNameField}}" userInput="{{CreateUserData.firstName}}"/>
150+
<click stepKey="clickFiltersApplyButton" selector="{{AdminCustomerAccountInformationSection.filtersApplyButton}}"/>
151+
<waitForElementNotVisible selector="{{AdminCustomerAccountInformationSection.filterNameField}}" stepKey="waitForFilterBecomeNotVisible"/>
149152
<click selector="{{AdminCustomerAccountInformationSection.selectCustomer}}" stepKey="ClickOnCustomer"/>
150153
<click selector="{{AdminCustomerAccountInformationSection.actions}}" stepKey="ClickOnActions"/>
151154
<waitForElementVisible selector="{{AdminCustomerAccountInformationSection.delete}}" stepKey="waitForDeleteButtonAppeared"/>

app/code/Magento/Newsletter/Test/Mftf/Section/VerifySubscribedNewsLetterDisplayedSection.xml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@
7575
<element name="delete" type="button" selector="//div[@class='col-xs-2']//span[text()='Delete']"/>
7676
<element name="confirm" type="button" selector=".action-primary.action-accept"/>
7777
<element name="clearAll" type="button" selector="//*[@class='admin__data-grid-outer-wrap']/*[@class='admin__data-grid-header']//*[contains(text(), 'Clear all')]"/>
78+
<element name="filterButton" type="button" selector="//*[@class='admin__data-grid-outer-wrap']/*[@class='admin__data-grid-header']//*[@class='data-grid-filters-action-wrap']/button"/>
79+
<element name="filterNameField" type="input" selector="//*[@name='name']"/>
80+
<element name="filtersApplyButton" type="button" selector="//*[contains(text(),'Apply Filters')]"/>
7881
</section>
7982

8083
</sections>

0 commit comments

Comments
 (0)