Skip to content

Commit b4db970

Browse files
committed
- refactoring the test
1 parent c9242e8 commit b4db970

File tree

1 file changed

+29
-7
lines changed

1 file changed

+29
-7
lines changed

app/code/Magento/ConfigurableProduct/Test/Mftf/Test/StorefrontConfigurableProductDetailsTest/StorefrontConfigurableProductBasicInfoTest.xml

Lines changed: 29 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,14 +38,36 @@
3838
</after>
3939

4040
<!-- Verify configurable product details in storefront product view -->
41-
<amOnPage url="{{_defaultProduct.urlKey}}.html" stepKey="amOnConfigurableProductPage"/>
42-
<waitForPageLoad stepKey="wait"/>
43-
<see userInput="{{_defaultProduct.name}}" selector="{{StorefrontProductInfoMainSection.productName}}" stepKey="seeProductName"/>
44-
<see userInput="{{_defaultProduct.sku}}" selector="{{StorefrontProductInfoMainSection.productSku}}" stepKey="seeProductSku"/>
41+
<!--<amOnPage url="{{_defaultProduct.urlKey}}.html" stepKey="amOnConfigurableProductPage"/>-->
42+
<!--<waitForPageLoad stepKey="wait"/>-->
43+
<actionGroup ref="StorefrontOpenProductPageActionGroup" stepKey="openStorefrontProductPage">
44+
<argument name="productUrl" value="{{_defaultProduct.urlKey}}"/>
45+
</actionGroup>
46+
<comment userInput="Comment is added to preserve the step key for backward compatibility" stepKey="wait"/>
47+
48+
<!--<see userInput="{{_defaultProduct.name}}" selector="{{StorefrontProductInfoMainSection.productName}}" stepKey="seeProductName"/>-->
49+
<actionGroup ref="StorefrontAssertProductNameOnProductPageActionGroup" stepKey="seeProductName">
50+
<argument name="productName" value="{{_defaultProduct.name}}"/>
51+
</actionGroup>
52+
53+
<!--<see userInput="{{_defaultProduct.sku}}" selector="{{StorefrontProductInfoMainSection.productSku}}" stepKey="seeProductSku"/>-->
54+
<actionGroup ref="StorefrontAssertProductSkuOnProductPageActionGroup" stepKey="seeProductSku">
55+
<argument name="productSku" value="{{_defaultProduct.sku}}"/>
56+
</actionGroup>
57+
4558
<see userInput="As low as" selector="{{StorefrontProductInfoMainSection.productPriceLabel}}" stepKey="seeProductPriceLabel"/>
46-
<see userInput="IN STOCK" selector="{{StorefrontProductInfoMainSection.productStockStatus}}" stepKey="seeProductStockStatus"/>
47-
<see userInput="1.00" selector="{{StorefrontProductInfoMainSection.productPrice}}" stepKey="seeProductPrice"/>
48-
<see userInput="{{colorProductAttribute.default_label}}" selector="{{StorefrontProductInfoMainSection.productAttributeTitle1}}" stepKey="seeProductAttributeTitle"/>
59+
<!--<see userInput="IN STOCK" selector="{{StorefrontProductInfoMainSection.productStockStatus}}" stepKey="seeProductStockStatus"/>-->
60+
<actionGroup ref="AssertStorefrontProductStockStatusOnProductPageActionGroup" stepKey="seeProductStatusInStoreFront">
61+
<argument name="productStockStatus" value="In Stock"/>
62+
</actionGroup>
63+
<!--<see userInput="1.00" selector="{{StorefrontProductInfoMainSection.productPrice}}" stepKey="seeProductPrice"/>-->
64+
<actionGroup ref="StorefrontAssertProductPriceOnProductPageActionGroup" stepKey="seeProductPrice">
65+
<argument name="productPrice" value="1.00"/>
66+
</actionGroup>
67+
<!--<see userInput="{{colorProductAttribute.default_label}}" selector="{{StorefrontProductInfoMainSection.productAttributeTitle1}}" stepKey="seeProductAttributeTitle"/>-->
68+
<actionGroup ref="AssertStorefrontProductAttributeLabelVisibleActionGroup" stepKey="seeProductAttributeTitle">
69+
<argument name="productAttributeLabel" value="{{colorProductAttribute.default_label}}"/>
70+
</actionGroup>
4971
<see selector="{{StorefrontProductInfoMainSection.productAttributeTitle1}}" userInput="{{colorProductAttribute.default_label}}" stepKey="seeColorAttributeName1"/>
5072
<see userInput="{{colorProductAttribute1.name}}" selector="{{StorefrontProductInfoMainSection.productAttributeOptions1}}" stepKey="seeInDropDown1"/>
5173
<see userInput="{{colorProductAttribute2.name}}" selector="{{StorefrontProductInfoMainSection.productAttributeOptions1}}" stepKey="seeInDropDown2"/>

0 commit comments

Comments
 (0)