Skip to content

Commit

Permalink
adding AdminSetStockStatusActionGroup
Browse files Browse the repository at this point in the history
  • Loading branch information
AnnaAPak committed Nov 23, 2020
1 parent f55f411 commit 3adff7a
Show file tree
Hide file tree
Showing 6 changed files with 16 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@

<scrollTo selector="{{AdminProductFormSection.productQuantity}}" stepKey="scrollToProductQuantity" after="waitForProductPageToLoad"/>
<remove keyForRemoval="disableProduct"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="Out of Stock" stepKey="selectOutOfStock" after="scrollToProductQuantity"/>
<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="selectOutOfStock" after="scrollToProductQuantity">
<argument name="stockStatus" value="Out of Stock"/>
</actionGroup>

</test>
</tests>
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
<waitForPageLoad stepKey="waitForProductToLoad"/>

<fillField selector="{{AdminProductFormSection.productQuantity}}" userInput="100" stepKey="fillProductQty"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="In Stock" stepKey="selectStockStatus"/>
<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="selectStockStatus"/>

<!-- Create New Product Attribute -->
<click selector="{{AdminProductFormSection.addAttributeBtn}}" stepKey="clickOnAddAttribute"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,8 @@
<waitForPageLoad stepKey="waitForProductToLoad"/>

<fillField selector="{{AdminProductFormSection.productQuantity}}" userInput="100" stepKey="fillProductQty"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="In Stock" stepKey="selectStockStatus"/>
<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="selectStockStatus"/>
<!-- <selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="In Stock" stepKey="selectStockStatus"/> -->

<!-- Create Product Attribute -->
<click selector="{{AdminProductFormSection.addAttributeBtn}}" stepKey="clickOnAddAttribute"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,11 @@
<argument name="productId" value="$$createConfigChildProduct2.id$$"/>
</actionGroup>
<waitForPageLoad stepKey="waitForSecondChildProductPageLoad"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="Out of Stock" stepKey="outOfStockStatus"/>

<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="outOfStockStatus">
<argument name="stockStatus" value="Out of Stock"/>
</actionGroup>

<actionGroup ref="SaveProductFormActionGroup" stepKey="saveSecondProductForm"/>
<!-- Go to created customer page -->
<comment userInput="Go to created customer page" stepKey="goToCreatedCustomerPage"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,9 @@
<click selector="{{AdminProductGridFilterSection.nthRow('1')}}" stepKey="selectFirstRow"/>
<waitForPageLoad stepKey="waitForProductPageToLoad"/>
<scrollTo selector="{{AdminProductFormSection.productQuantity}}" stepKey="scrollToProductQuantity"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="Out of Stock" stepKey="disableProduct"/>
<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="disableProduct">
<argument name="stockStatus" value="Out of Stock"/>
</actionGroup>
<actionGroup ref="AdminProductFormSaveActionGroup" stepKey="clickOnSaveButton"/>
<see selector="{{AdminCategoryMessagesSection.SuccessMessage}}" userInput="You saved the product." stepKey="messageYouSavedTheProductIsShown"/>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@
<actionGroup ref="AdminFormSaveAndDuplicateActionGroup" stepKey="saveAndDuplicateProductForm"/>
<click selector="{{AdminProductFormSection.enableProductLabel}}" stepKey="clickEnableProduct"/>
<fillField selector="{{AdminProductFormSection.productName}}" userInput="$$createConfigProduct.name$$-Updated" stepKey="fillProductName"/>
<selectOption selector="{{AdminProductFormSection.productStockStatus}}" userInput="1" stepKey="selectInStock"/>
<actionGroup ref="AdminSetStockStatusActionGroup" stepKey="selectInStock"/>
<!--Change product image-->
<comment userInput="Change product image" stepKey="commentChangeProductImage"/>
<actionGroup ref="RemoveProductImageActionGroup" stepKey="removeProductImage"/>
Expand Down

0 comments on commit 3adff7a

Please sign in to comment.