Skip to content

Commit 2b153ee

Browse files
committed
Merge remote-tracking branch 'origin/MAGETWO-97216' into 2.3-develop-mftf-pr20
2 parents d7883bb + ec0e89f commit 2b153ee

File tree

2 files changed

+30
-18
lines changed

2 files changed

+30
-18
lines changed

app/code/Magento/Store/Test/Mftf/ActionGroup/DeleteCustomStoreActionGroup.xml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@
2222
<click selector="{{AdminStoresMainActionsSection.deleteButton}}" stepKey="clickDeleteStoreGroupButtonOnEditStorePage"/>
2323
<selectOption userInput="No" selector="{{AdminStoresDeleteStoreGroupSection.createDbBackup}}" stepKey="setCreateDbBackupToNo"/>
2424
<click selector="{{AdminStoresDeleteStoreGroupSection.deleteStoreGroupButton}}" stepKey="clickDeleteStoreGroupButtonOnDeleteStorePage"/>
25+
<waitForElementVisible selector="{{AdminMessagesSection.successMessage}}" stepKey="waitForSuccessMessage"/>
26+
<see selector="{{AdminMessagesSection.successMessage}}" userInput="You deleted the store." stepKey="seeSuccessMessage"/>
2527
</actionGroup>
2628
<actionGroup name="DeleteCustomStoreBackupEnabledYesActionGroup">
2729
<arguments>
@@ -52,4 +54,4 @@
5254
<waitForPageLoad stepKey="waitForStoreToLoad"/>
5355
<see selector="{{AdminStoresGridSection.emptyText}}" userInput="We couldn't find any records." stepKey="seeAssertStoreGroupNotInGridMessage"/>
5456
</actionGroup>
55-
</actionGroups>
57+
</actionGroups>

app/code/Magento/Wishlist/Test/Mftf/Test/StorefrontAddMultipleStoreProductsToWishlistTest.xml

Lines changed: 27 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -10,16 +10,14 @@
1010
<test name="StorefrontAddMultipleStoreProductsToWishlistTest">
1111
<annotations>
1212
<features value="Wishlist"/>
13-
<stories value="Adding to wishlist"/>
13+
<stories value="Add product to wishlist"/>
1414
<title value="Customer should be able to add products to wishlist from different stores"/>
1515
<description value="All products added to wishlist should be visible on any store. Even if product visibility was set to 'Not Visible Individually' for this store"/>
1616
<group value="wishlist"/>
1717
<severity value="AVERAGE"/>
18-
<testCaseId value="MAGETWO-95678"/>
19-
<skip>
20-
<issueId value="MC-13867"/>
21-
</skip>
18+
<testCaseId value="MC-6243"/>
2219
</annotations>
20+
2321
<before>
2422
<createData entity="customStoreGroup" stepKey="storeGroup"/>
2523
<createData entity="SimpleSubCategory" stepKey="categoryHandle"/>
@@ -36,23 +34,34 @@
3634
<argument name="storeGroupName" value="$$storeGroup.group[name]$$"/>
3735
</actionGroup>
3836
</before>
37+
3938
<after>
4039
<deleteData createDataKey="product" stepKey="deleteFirstProduct"/>
4140
<deleteData createDataKey="secondProduct" stepKey="deleteSecondProduct"/>
4241
<deleteData createDataKey="customer" stepKey="deleteCustomer"/>
4342
<actionGroup ref="DeleteCustomStoreActionGroup" stepKey="deleteCustomStoreGroup">
4443
<argument name="storeGroupName" value="$$storeGroup.group[name]$$"/>
4544
</actionGroup>
46-
<amOnPage url="admin/admin/auth/logout/" stepKey="amOnLogoutPage"/>
45+
<actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearWebsitesGridFilter"/>
46+
47+
<!--Clear products filter-->
48+
<amOnPage url="{{AdminProductIndexPage.url}}" stepKey="navigateToProductIndex"/>
49+
<actionGroup ref="clearFiltersAdminDataGrid" stepKey="clearProductsFilters"/>
50+
<!--Logout everywhere-->
51+
<actionGroup ref="logout" stepKey="logoutFromAdmin"/>
52+
<actionGroup ref="StorefrontCustomerLogoutActionGroup" stepKey="customerLogout"/>
4753
</after>
54+
4855
<!-- Change products visibility on store-view level -->
4956
<actionGroup ref="SearchForProductOnBackendActionGroup" stepKey="searchForProduct1">
5057
<argument name="product" value="$$product$$"/>
5158
</actionGroup>
5259
<actionGroup ref="OpenEditProductOnBackendActionGroup" stepKey="openEditProduct1">
5360
<argument name="product" value="$$product$$"/>
5461
</actionGroup>
62+
<scrollToTopOfPage stepKey="scrollToTopToChangeStore"/>
5563
<click selector="{{AdminProductFormActionSection.changeStoreButton}}" stepKey="clickSwitchStoreMenuForProduct1"/>
64+
<waitForElementVisible selector="{{AdminProductFormChangeStoreSection.storeSelector(customStore.name)}}" stepKey="waitCustomStoreItemAppers"/>
5665
<click selector="{{AdminProductFormChangeStoreSection.storeSelector(customStore.name)}}" stepKey="clickOnStoreNameItemForProduct1"/>
5766
<waitForElementVisible selector="{{AdminProductFormChangeStoreSection.acceptButton}}" stepKey="waitAcceptStoreSwitchingForProduct1n"/>
5867
<click selector="{{AdminProductFormChangeStoreSection.acceptButton}}" stepKey="acceptStoreSwitchingForProduct1"/>
@@ -65,36 +74,37 @@
6574
<actionGroup ref="OpenEditProductOnBackendActionGroup" stepKey="openEditProduct2">
6675
<argument name="product" value="$$secondProduct$$"/>
6776
</actionGroup>
77+
<scrollToTopOfPage stepKey="scrollToTopToChangeStoreAgain"/>
6878
<click selector="{{AdminProductFormActionSection.changeStoreButton}}" stepKey="clickSwitchStoreMenuForProduct2"/>
79+
<waitForElementVisible selector="{{AdminProductFormChangeStoreSection.storeSelector(customStore.name)}}" stepKey="waitDefaultStoreItemAppers"/>
6980
<click selector="{{AdminProductFormChangeStoreSection.storeSelector('Default Store View')}}" stepKey="clickOnStoreNameItemForProduct2"/>
7081
<waitForElementVisible selector="{{AdminProductFormChangeStoreSection.acceptButton}}" stepKey="waitAcceptStoreSwitchingForProduct2"/>
7182
<click selector="{{AdminProductFormChangeStoreSection.acceptButton}}" stepKey="acceptStoreSwitchingForProduct2"/>
7283
<click selector="{{AdminProductFormSection.visibilityUseDefault}}" stepKey="uncheckVisibilityUseDefaultValueForProduct2"/>
7384
<selectOption userInput="Not Visible Individually" selector="{{AdminProductFormSection.visibility}}" stepKey="makeProductNotVisibleOnDefaultStoreView"/>
7485
<click selector="{{AdminProductFormActionSection.saveButton}}" stepKey="saveEditedProductForProduct2"/>
86+
7587
<!-- Sign in as customer -->
76-
<amOnPage url="{{StorefrontCustomerSignInPage.url}}" stepKey="amOnSignInPage"/>
77-
<fillField userInput="$$customer.email$$" selector="{{StorefrontCustomerSignInFormSection.emailField}}" stepKey="fillEmail"/>
78-
<fillField userInput="$$customer.password$$" selector="{{StorefrontCustomerSignInFormSection.passwordField}}" stepKey="fillPassword"/>
79-
<waitForElementVisible selector="{{StorefrontCustomerSignInFormSection.signInAccountButton}}" stepKey="waitForButton"/>
80-
<click selector="{{StorefrontCustomerSignInFormSection.signInAccountButton}}" stepKey="clickSignInAccountButton"/>
88+
<actionGroup ref="LoginToStorefrontActionGroup" stepKey="customerLogin">
89+
<argument name="Customer" value="$$customer$$" />
90+
</actionGroup>
8191
<see userInput="$$customer.firstname$$" selector="{{StorefrontCustomerDashboardAccountInformationSection.ContactInformation}}" stepKey="seeFirstName"/>
8292
<see userInput="$$customer.lastname$$" selector="{{StorefrontCustomerDashboardAccountInformationSection.ContactInformation}}" stepKey="seeLastName"/>
8393
<see userInput="$$customer.email$$" selector="{{StorefrontCustomerDashboardAccountInformationSection.ContactInformation}}" stepKey="seeEmail"/>
8494
<!-- Add product visible on default store to wishlist -->
85-
<amOnPage url="$$product.name$$.html" stepKey="navigateToProductPageOnDefaultStore"/>
95+
<amOnPage url="{{StorefrontProductPage.url($$product.custom_attributes[url_key]$$)}}" stepKey="navigateToProductPageOnDefaultStore"/>
8696
<see userInput="$$product.name$$" selector="{{StorefrontProductInfoMainSection.productName}}" stepKey="assertFirstProductNameTitle"/>
8797
<click selector="{{StorefrontProductPageSection.addToWishlist}}" stepKey="addFirstProductToWishlist"/>
8898
<!-- Switch to second store and add second product (visible on second store) to wishlist -->
89-
<click selector="{{StorefrontFooterSection.switchStoreButton}}" stepKey="ClickSwitchStoreButtonOnDefaultStore"/>
90-
<click selector="{{StorefrontFooterSection.storeLink($$storeGroup.group[name]$$)}}" stepKey="SelectSecondStoreToSwitchOn"/>
99+
<click selector="{{StorefrontFooterSection.switchStoreButton}}" stepKey="clickSwitchStoreButtonOnDefaultStore"/>
100+
<click selector="{{StorefrontFooterSection.storeLink($$storeGroup.group[name]$$)}}" stepKey="selectSecondStoreToSwitchOn"/>
91101
<!-- Verify that both products are visible in wishlist on both stores -->
92-
<amOnPage url="$$secondProduct.name$$.html" stepKey="navigateToProductPageOnSecondStore"/>
102+
<amOnPage url="{{StorefrontProductPage.url($$secondProduct.custom_attributes[url_key]$$)}}" stepKey="navigateToProductPageOnSecondStore"/>
93103
<see userInput="$$secondProduct.name$$" selector="{{StorefrontProductInfoMainSection.productName}}" stepKey="assertSecondProductNameTitle"/>
94104
<click selector="{{StorefrontProductPageSection.addToWishlist}}" stepKey="addSecondProductToWishlist"/>
95105
<see userInput="$$secondProduct.name$$" selector="{{StorefrontCustomerWishlistSection.productItemNameText}}" stepKey="seeProduct2InWishlistOnSecondStore"/>
96-
<click selector="{{StorefrontFooterSection.switchStoreButton}}" stepKey="ClickSwitchStoreButtonOnSecondStore"/>
97-
<click selector="{{StorefrontFooterSection.storeLink('Main Website Store')}}" stepKey="SelectDefaultStoreToSwitchOn"/>
106+
<click selector="{{StorefrontFooterSection.switchStoreButton}}" stepKey="clickSwitchStoreButtonOnSecondStore"/>
107+
<click selector="{{StorefrontFooterSection.storeLink('Main Website Store')}}" stepKey="selectDefaultStoreToSwitchOn"/>
98108
<see userInput="$$product.name$$" selector="{{StorefrontCustomerWishlistSection.productItemNameText}}" stepKey="seeProduct1InWishlistOnDefaultStore"/>
99109
</test>
100110
</tests>

0 commit comments

Comments
 (0)