-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3648 from magento-tsg/2.2-develop-mftf-pr13
[TSG] MFTF for 2.2 (pr13) (2.2-develop)
- Loading branch information
Showing
16 changed files
with
277 additions
and
14 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
54 changes: 54 additions & 0 deletions
54
...ftf/Test/StorefrontShoppingCartCheckCustomerDefaultShippingAddressForVirtualQuoteTest.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,54 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!-- | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
--> | ||
|
||
<tests xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/testSchema.xsd"> | ||
<test name="StorefrontShoppingCartCheckCustomerDefaultShippingAddressForVirtualQuoteTest"> | ||
<annotations> | ||
<features value="Checkout"/> | ||
<stories value="Checkout via the Storefront"/> | ||
<title value="Estimator in Shopping cart must be pre-filled by Customer default shipping address for virtual quote"/> | ||
<description value="Estimator in Shopping cart must be pre-filled by Customer default shipping address for virtual quote"/> | ||
<severity value="CRITICAL"/> | ||
<testCaseId value="MAGETWO-78596"/> | ||
<group value="checkout"/> | ||
</annotations> | ||
<before> | ||
<createData entity="VirtualProduct" stepKey="createVirtualProduct"/> | ||
<createData entity="Customer_With_Different_Default_Billing_Shipping_Addresses" stepKey="createCustomer"/> | ||
</before> | ||
<after> | ||
<actionGroup ref="CustomerLogoutStorefrontActionGroup" stepKey="customerLogout"/> | ||
<deleteData createDataKey="createVirtualProduct" stepKey="deleteVirtualProduct"/> | ||
<deleteData createDataKey="createCustomer" stepKey="deleteCustomer"/> | ||
</after> | ||
<!-- Steps --> | ||
<!-- Step 1: Go to Storefront as Customer --> | ||
<actionGroup ref="CustomerLoginOnStorefront" stepKey="customerLogin"> | ||
<argument name="customer" value="$$createCustomer$$" /> | ||
</actionGroup> | ||
<!-- Step 2: Add virtual product to cart --> | ||
<amOnPage url="{{StorefrontProductPage.url($$createVirtualProduct.custom_attributes[url_key]$)}}" stepKey="amOnPage"/> | ||
<actionGroup ref="StorefrontAddProductToCartActionGroup" stepKey="addProductToCart"> | ||
<argument name="product" value="$$createVirtualProduct$$"/> | ||
<argument name="productCount" value="1"/> | ||
</actionGroup> | ||
<!-- Step 3: Go to Shopping Cart --> | ||
<actionGroup ref="StorefrontViewAndEditCartFromMiniCartActionGroup" stepKey="goToShoppingcart"/> | ||
<!-- Step 4: Open Estimate Tax section --> | ||
<click selector="{{StorefrontCheckoutCartSummarySection.estimateShippingAndTax}}" stepKey="openEstimateTaxSection"/> | ||
<seeOptionIsSelected selector="{{StorefrontCheckoutCartSummarySection.country}}" userInput="{{US_Address_CA.country}}" stepKey="checkCountry"/> | ||
<seeOptionIsSelected selector="{{StorefrontCheckoutCartSummarySection.region}}" userInput="{{US_Address_CA.state}}" stepKey="checkState"/> | ||
<scrollTo selector="{{StorefrontCheckoutCartSummarySection.postcode}}" stepKey="scrollToPostCodeField"/> | ||
<grabValueFrom selector="{{StorefrontCheckoutCartSummarySection.postcode}}" stepKey="grabTextPostCode"/> | ||
<assertEquals message="Customer postcode is invalid" stepKey="checkCustomerPostcode"> | ||
<expectedResult type="string">{{US_Address_CA.postcode}}</expectedResult> | ||
<actualResult type="variable">grabTextPostCode</actualResult> | ||
</assertEquals> | ||
</test> | ||
</tests> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
app/code/Magento/SalesRule/Test/Mftf/ActionGroup/AdminFilterCartPriceRuleActionGroup.xml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
<?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="urn:magento:mftf:Test/etc/actionGroupSchema.xsd"> | ||
<!--Search grid with keyword search--> | ||
<actionGroup name="AdminFilterCartPriceRuleActionGroup"> | ||
<arguments> | ||
<argument name="ruleName"/> | ||
</arguments> | ||
<conditionalClick selector="{{AdminDataGridHeaderSection.clearFilters}}" dependentSelector="{{AdminDataGridHeaderSection.clearFilters}}" visible="true" stepKey="clickClearFilters"/> | ||
<fillField selector="{{AdminCartPriceRulesSection.filterByNameInput}}" userInput="{{ruleName}}" stepKey="filterByName"/> | ||
<click selector="{{AdminCartPriceRulesSection.searchButton}}" stepKey="doFilter"/> | ||
</actionGroup> | ||
</actionGroups> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.