Skip to content

Commit 881b75c

Browse files
committed
create AdminTaxRateGridOpenPageActionGroup
1 parent 735579d commit 881b75c

25 files changed

+61
-78
lines changed

app/code/Magento/Checkout/Test/Mftf/Test/StorefrontCustomerCheckoutTest/StorefrontCustomerCheckoutTestWithMultipleAddressesAndTaxRatesTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -57,8 +57,7 @@
5757
</actionGroup>
5858

5959
<!-- Go to the tax rate page -->
60-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRatesPage"/>
61-
<waitForPageLoad stepKey="waitForRatesPage"/>
60+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRatesPage"/>
6261
<!-- Delete the two tax rates that were created -->
6362
<actionGroup ref="deleteEntitySecondaryGrid" stepKey="deleteNYRate">
6463
<argument name="name" value="{{SimpleTaxNY.state}}-{{SimpleTaxNY.rate}}"/>

app/code/Magento/Customer/Test/Mftf/Test/StorefrontCheckTaxAddingValidVATIdTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -117,8 +117,7 @@
117117
</actionGroup>
118118

119119
<!-- Go to the tax rate page -->
120-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRatesPage"/>
121-
<waitForPageLoad stepKey="waitForRatesPage"/>
120+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRatesPage"/>
122121

123122
<!-- Delete the two tax rates that were created -->
124123
<actionGroup ref="deleteEntitySecondaryGrid" stepKey="deleteNYRate">

app/code/Magento/SalesRule/Test/Mftf/Test/StorefrontCartTotalValueWithFullDiscountUsingCartRuleTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,8 +69,7 @@
6969
<argument name="searchInput" value="{{AdminSecondaryGridSection.taxIdentifierSearch}}"/>
7070
</actionGroup>
7171
<!-- Delete the tax rate that were created -->
72-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRatesPage"/>
73-
<waitForPageLoad stepKey="waitForRatesPage"/>
72+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRatesPage"/>
7473
<actionGroup ref="deleteEntitySecondaryGrid" stepKey="deleteNYRate">
7574
<argument name="name" value="{{SimpleTaxNYRate.state}}-{{SimpleTaxNYRate.rate}}"/>
7675
<argument name="searchInput" value="{{AdminSecondaryGridSection.taxIdentifierSearch}}"/>
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
/**
4+
* Copyright © Magento, Inc. All rights reserved.
5+
* See COPYING.txt for license details.
6+
*/
7+
-->
8+
9+
<actionGroups xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
10+
xsi:noNamespaceSchemaLocation="urn:magento:mftf:Test/etc/actionGroupSchema.xsd">
11+
<actionGroup name="AdminTaxRateGridOpenPageActionGroup">
12+
<annotations>
13+
<description>Go to tax rate grid page.</description>
14+
</annotations>
15+
16+
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRatePage"/>
17+
<waitForPageLoad stepKey="waitForTaxRatePage"/>
18+
</actionGroup>
19+
</actionGroups>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateAllPostCodesTest.xml

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424
<after>
25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex"/>
2626
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
2727
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
2828
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch"/>
@@ -31,8 +31,7 @@
3131
<click selector="{{AdminTaxRateFormSection.ok}}" stepKey="clickOk"/>
3232
</after>
3333

34-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
35-
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
34+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
3635
<!-- Create a tax rate with * for postcodes -->
3736
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
3837
<fillField selector="{{AdminTaxRateFormSection.taxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillRuleName"/>
@@ -43,8 +42,7 @@
4342
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the tax rate." stepKey="seeSuccess"/>
4443

4544
<!-- Verify the tax rate grid page shows the tax rate we just created -->
46-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex2"/>
47-
<waitForPageLoad stepKey="waitForTaxRateIndex2"/>
45+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex2"/>
4846
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters1"/>
4947
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
5048
<selectOption selector="{{AdminTaxRateGridSection.filterByCountry}}" userInput="Australia" stepKey="fillCountryFilter"/>
@@ -55,8 +53,7 @@
5553
<see selector="{{AdminTaxRateGridSection.grid}}" userInput="*" stepKey="seePostCode"/>
5654

5755
<!-- Go to the tax rate edit page for our new tax rate -->
58-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex3"/>
59-
<waitForPageLoad stepKey="waitForTaxRateIndex3"/>
56+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex3"/>
6057
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
6158
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter2"/>
6259
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch2"/>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateInvalidPostcodeTestLengthTest.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424

25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
26-
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
2726
<!-- Create a tax rate for large postcodes -->
2827
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
2928
<fillField selector="{{AdminTaxRateFormSection.taxIdentifier}}" userInput="{{taxRateWithInvalidPostCodeLength.code}}" stepKey="fillRuleName"/>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateLargeRateTest.xml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424
<after>
25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex"/>
2626
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
2727
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
2828
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch"/>
@@ -31,8 +31,7 @@
3131
<click selector="{{AdminTaxRateFormSection.ok}}" stepKey="clickOk"/>
3232
</after>
3333

34-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
35-
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
34+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
3635
<!-- Create a tax rate for large postcodes -->
3736
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
3837
<fillField selector="{{AdminTaxRateFormSection.taxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillRuleName"/>
@@ -43,8 +42,7 @@
4342
<click selector="{{AdminTaxRateFormSection.save}}" stepKey="clickSave"/>
4443
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the tax rate." stepKey="seeSuccess"/>
4544

46-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex2"/>
47-
<waitForPageLoad stepKey="waitForTaxRateIndex3"/>
45+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex2"/>
4846
<!-- Create a tax rate for large postcodes and verify we see expected values on the tax rate grid page -->
4947
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
5048
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillTaxIdentifierField2"/>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateSpecificPostcodeTest.xml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424
<after>
25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex"/>
2626
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
2727
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
2828
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch"/>
@@ -31,7 +31,7 @@
3131
<click selector="{{AdminTaxRateFormSection.ok}}" stepKey="clickOk"/>
3232
</after>
3333

34-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
34+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
3535
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
3636
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
3737
<!-- Create a tax rate with specific postcode -->
@@ -43,8 +43,7 @@
4343
<click selector="{{AdminTaxRateFormSection.save}}" stepKey="clickSave"/>
4444
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the tax rate." stepKey="seeSuccess"/>
4545

46-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex2"/>
47-
<waitForPageLoad stepKey="waitForTaxRateIndex2"/>
46+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex2"/>
4847
<!-- Verify the tax rate grid page shows the specific postcode we just created -->
4948
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters1"/>
5049
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillTaxIdentifierField2"/>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateWiderZipCodeRangeTest.xml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424
<after>
25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex"/>
2626
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
2727
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
2828
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch"/>
@@ -31,8 +31,7 @@
3131
<click selector="{{AdminTaxRateFormSection.ok}}" stepKey="clickOk"/>
3232
</after>
3333

34-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
35-
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
34+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
3635
<!-- Create a tax rate with range from 1-7800935 for zipCodes -->
3736
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
3837
<fillField selector="{{AdminTaxRateFormSection.taxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillRuleName"/>
@@ -44,8 +43,7 @@
4443
<click selector="{{AdminTaxRateFormSection.save}}" stepKey="clickSave"/>
4544
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the tax rate." stepKey="seeSuccess"/>
4645

47-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex2"/>
48-
<waitForPageLoad stepKey="waitForTaxRateIndex3"/>
46+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex2"/>
4947
<!-- Create a tax rate for zipCodeRange and verify we see expected values on the tax rate grid page -->
5048
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
5149
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillTaxIdentifierField2"/>

app/code/Magento/Tax/Test/Mftf/Test/AdminCreateTaxRateZipCodeRangeTest.xml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
<actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/>
2323
</before>
2424
<after>
25-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex"/>
25+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex"/>
2626
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
2727
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillNameFilter"/>
2828
<click selector="{{AdminTaxRateGridSection.search}}" stepKey="clickSearch"/>
@@ -31,8 +31,7 @@
3131
<click selector="{{AdminTaxRateFormSection.ok}}" stepKey="clickOk"/>
3232
</after>
3333

34-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex1"/>
35-
<waitForPageLoad stepKey="waitForTaxRateIndex1"/>
34+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex1"/>
3635
<!-- Create a tax rate with range from 90001-96162 for zipCodes -->
3736
<click selector="{{AdminTaxRateGridSection.add}}" stepKey="clickAddNewTaxRateButton"/>
3837
<fillField selector="{{AdminTaxRateFormSection.taxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillRuleName"/>
@@ -45,8 +44,7 @@
4544
<click selector="{{AdminTaxRateFormSection.save}}" stepKey="clickSave"/>
4645
<see selector="{{AdminMessagesSection.success}}" userInput="You saved the tax rate." stepKey="seeSuccess"/>
4746

48-
<amOnPage url="{{AdminTaxRateGridPage.url}}" stepKey="goToTaxRateIndex2"/>
49-
<waitForPageLoad stepKey="waitForTaxRateIndex3"/>
47+
<actionGroup ref="AdminTaxRateGridOpenPageActionGroup" stepKey="goToTaxRateIndex2"/>
5048
<!-- Create a tax rate for zipCodeRange and verify we see expected values on the tax rate grid page -->
5149
<click selector="{{AdminDataGridHeaderSection.clearFilters}}" stepKey="clickClearFilters2"/>
5250
<fillField selector="{{AdminTaxRateGridSection.filterByTaxIdentifier}}" userInput="{{SimpleTaxRate.code}}" stepKey="fillTaxIdentifierField2"/>

0 commit comments

Comments
 (0)