Skip to content

Commit

Permalink
Merge pull request #53 from magento-epam/MAGETWO-66666
Browse files Browse the repository at this point in the history
MAGETWO-66666: Adding a product to cart from category page with an ex…
  • Loading branch information
nikshostko authored Aug 16, 2018
2 parents 830007d + 4ec730c commit 80abb23
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,13 @@
<see userInput="Shipping Address" stepKey="seeShippingAddress"/>
</actionGroup>

<actionGroup name="DeleteCreatedProduct">
<fillField stepKey="searchToKeyword" selector="{{DeleteCreatedProduct.searchToKeyword}}" userInput="{{SimpleProductOne.name}}"/>
<click stepKey="clickSearchButton" selector="{{DeleteCreatedProduct.searchButton}}"/>
<wait stepKey="waitForFiltering" time="2"/>
<actionGroup name="DeleteCreatedProductActionGroup">
<conditionalClick selector="{{DeleteCreatedProduct.clearAll}}" dependentSelector="{{DeleteCreatedProduct.clearAll}}" visible="1" stepKey="clickClearAllIfThereIsAnyValue"/>
<click stepKey="clickFilterButton" selector="{{DeleteCreatedProduct.filterButton}}"/>
<waitForElementVisible selector="{{DeleteCreatedProduct.filterSKUField}}" stepKey="waitForFilterDataLoaded"/>
<fillField stepKey="searchProductUsingSKUField" selector="{{DeleteCreatedProduct.filterSKUField}}" userInput="{{SimpleProductOne.sku}}"/>
<click stepKey="clickFiltersApplyButton" selector="{{DeleteCreatedProduct.filtersApplyButton}}"/>
<waitForElementNotVisible selector="{{DeleteCreatedProduct.filterSKUField}}" stepKey="waitForFilterBecomeNotVisible"/>
<click selector="{{DeleteCreatedProduct.createdProductID}}" stepKey="selectCreatedProduct"/>
<wait stepKey="waitSelectCreatedProduct" time="2"/>
<waitForElementVisible selector="{{DeleteCreatedProduct.actionSelectBox}}" stepKey="waitToSelectActionVisible" time="50"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@
<element name="deleteButton" type="button" selector="//div[@class='col-xs-2']//*[text()='Delete']"/>
<element name="okButton" type="button" selector=".action-primary.action-accept"/>
<element name="clearAll" type="button" selector="//*[@class='admin__data-grid-outer-wrap']/*[@class='admin__data-grid-header']//*[contains(text(), 'Clear all')]"/>
<element name="filterButton" type="button" selector="//*[@class='admin__data-grid-outer-wrap']/*[@class='admin__data-grid-header']//*[@class='data-grid-filters-action-wrap']/button"/>
<element name="filterSKUField" type="input" selector="//*[@name='sku']"/>
<element name="filtersApplyButton" type="button" selector="//*[contains(text(),'Apply Filters')]"/>
</section>

</sections>
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@
<!--Delete created product-->
<amOnPage url="/admin" stepKey="GoToDashboard"/>
<actionGroup ref="GoToProductPage" stepKey="againGoToProductPage"/>
<actionGroup ref="DeleteCreatedProduct" stepKey="deleteCreatedProduct"/>
<actionGroup ref="DeleteCreatedProductActionGroup" stepKey="deleteCreatedProduct"/>
</after>

</test>
Expand Down

0 comments on commit 80abb23

Please sign in to comment.