Skip to content

Commit ef7b93b

Browse files
committed
v6 add AdminOpenGeneralConfigurationPageActionGroup
1 parent 8b7d949 commit ef7b93b

File tree

3 files changed

+25
-12
lines changed

3 files changed

+25
-12
lines changed
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="AdminOpenGeneralConfigurationPageActionGroup">
12+
<annotations>
13+
<description>Open general configuration page.</description>
14+
</annotations>
15+
16+
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="openGeneralConfigurationPage"/>
17+
<waitForPageLoad stepKey="waitForPageLoad"/>
18+
</actionGroup>
19+
</actionGroups>

app/code/Magento/Catalog/Test/Mftf/Test/StorefrontSpecialPriceForDifferentTimezonesForWebsitesTest.xml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,14 @@
3737
</after>
3838

3939
<!--Set timezone for default config-->
40-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfig"/>
41-
<waitForPageLoad stepKey="waitForConfigPage"/>
40+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfig"/>
4241
<conditionalClick selector="{{LocaleOptionsSection.sectionHeader}}" dependentSelector="{{LocaleOptionsSection.timezone}}" visible="false" stepKey="openLocaleSection"/>
4342
<grabValueFrom selector="{{LocaleOptionsSection.timezone}}" stepKey="originalTimezone"/>
4443
<selectOption selector="{{LocaleOptionsSection.timezone}}" userInput="Central European Standard Time (Europe/Paris)" stepKey="setTimezone"/>
4544
<click selector="{{AdminMainActionsSection.save}}" stepKey="saveConfig"/>
4645

4746
<!--Set timezone for Main Website-->
48-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfig1"/>
49-
<waitForPageLoad stepKey="waitForConfigPage1"/>
47+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfig1"/>
5048
<actionGroup ref="AdminSwitchWebsiteActionGroup" stepKey="AdminSwitchStoreViewActionGroup">
5149
<argument name="website" value="_defaultWebsite"/>
5250
</actionGroup>
@@ -80,15 +78,13 @@
8078
</assertEquals>
8179

8280
<!--Reset timezone-->
83-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfigReset"/>
84-
<waitForPageLoad stepKey="waitForConfigPageReset"/>
81+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfigReset"/>
8582
<conditionalClick selector="{{LocaleOptionsSection.sectionHeader}}" dependentSelector="{{LocaleOptionsSection.timezone}}" visible="false" stepKey="openLocaleSectionReset"/>
8683
<selectOption selector="{{LocaleOptionsSection.timezone}}" userInput="$originalTimezone" stepKey="resetTimezone"/>
8784
<click selector="{{AdminMainActionsSection.save}}" stepKey="saveConfigReset"/>
8885

8986
<!--Reset timezone-->
90-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfigReset1"/>
91-
<waitForPageLoad stepKey="waitForConfigPageReset1"/>
87+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfigReset1"/>
9288
<actionGroup ref="AdminSwitchWebsiteActionGroup" stepKey="AdminSwitchStoreViewActionGroup1">
9389
<argument name="website" value="_defaultWebsite"/>
9490
</actionGroup>

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

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,7 @@
3939

4040
<!--Set timezone-->
4141
<!--Set timezone so we need compare with the same timezone used in "generateDate" action-->
42-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfig"/>
43-
<waitForPageLoad stepKey="waitForConfigPage"/>
42+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfig"/>
4443
<wait stepKey="wait" time="10"/>
4544
<conditionalClick selector="{{LocaleOptionsSection.sectionHeader}}" dependentSelector="{{LocaleOptionsSection.timezone}}" visible="false" stepKey="openLocaleSection"/>
4645
<grabValueFrom selector="{{LocaleOptionsSection.timezone}}" stepKey="originalTimezone"/>
@@ -93,8 +92,7 @@
9392
<see selector="{{CheckoutCartSummarySection.discountAmount}}" userInput="-$5.00" stepKey="seeDiscountTotal"/>
9493

9594
<!--Reset timezone-->
96-
<amOnPage url="{{GeneralConfigurationPage.url}}" stepKey="goToGeneralConfigReset"/>
97-
<waitForPageLoad stepKey="waitForConfigPageReset"/>
95+
<actionGroup ref="AdminOpenGeneralConfigurationPageActionGroup" stepKey="goToGeneralConfigReset"/>
9896
<conditionalClick selector="{{LocaleOptionsSection.sectionHeader}}" dependentSelector="{{LocaleOptionsSection.timezone}}" visible="false" stepKey="openLocaleSectionReset"/>
9997
<selectOption selector="{{LocaleOptionsSection.timezone}}" userInput="$originalTimezone" stepKey="resetTimezone"/>
10098
<click selector="{{AdminMainActionsSection.save}}" stepKey="saveConfigReset"/>

0 commit comments

Comments
 (0)