Skip to content

Commit 9d73c65

Browse files
committed
MAGETWO-92775: Duplicate Tabs
- stabilize duplicate tabs tests
1 parent 51c6888 commit 9d73c65

File tree

5 files changed

+112
-95
lines changed

5 files changed

+112
-95
lines changed

app/code/Magento/PageBuilder/Test/Mftf/ActionGroup/TabsActionGroup.xml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,15 @@
4444
<argument name="index" defaultValue="1" type="string"/>
4545
</arguments>
4646
<waitForElementVisible time="10" selector="{{TabOnStage.tabHeader(index)}}" stepKey="waitForContentTypeInStageVisible" />
47-
<click stepKey="clickTabTitle" selector="{{TabOnStage.tabHeader(index)}}"/>
48-
<waitForElementVisible time="30" selector="{{TabOnStage.tabOptionsEdit}}" stepKey="seeTabOptionsEdit"/>
49-
<click selector="{{TabOnStage.tabOptionsDuplicate}}" stepKey="clickEditContentType"/>
47+
<click selector="{{TabOnStage.tabHeader(index)}}" stepKey="clickTabTitle"/>
48+
<waitForElementVisible time="30" selector="{{TabOnStage.tabOptionsByIndex(index)}}" stepKey="waitForTabOptionsPanel"/>
49+
<grabTextFrom selector="{{TabOnStage.tabHeader(index)}}" stepKey="grabNameFromInitialTab"/>
50+
<waitForElementVisible time="30" selector="{{TabOnStage.tabOptionsDuplicate}}" stepKey="seeTabOptionsDuplicate"/>
51+
<click selector="{{TabOnStage.tabOptionsDuplicate}}" stepKey="clickDuplicateTab"/>
52+
<executeJS function="return Math.round({{index}}+1)" stepKey="newTabIndex"/>
53+
<waitForElementVisible time="30" selector="{{TabOnStage.tabHeader('${newTabIndex}')}}" stepKey="waitForNewTabVisible" />
54+
<waitForElementVisible time="30" selector="{{TabOnStage.tabOptionsByIndex('${newTabIndex}')}}" stepKey="waitForNewTabOptionsPanel"/>
55+
<see userInput="{$grabNameFromInitialTab} copy" selector="{{TabOnStage.tabHeader('${newTabIndex}')}}" stepKey="seeDuplicatedTabName"/>
5056
</actionGroup>
5157
<actionGroup name="openTabOptionsByIndex">
5258
<arguments>

app/code/Magento/PageBuilder/Test/Mftf/Test/AdminPageBuilderTabConfigurationDefaults.xml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
1111
<test name="DefaultTabStateOnAddingNewTab">
1212
<annotations>
13-
<features value="PageBuilder"/>
14-
<stories value="Tabs: Tab Configuration"/>
13+
<features value="Pagebuilder"/>
14+
<stories value="Tabs"/>
1515
<useCaseId value="MAGETWO-71593"/>
1616
<title value="Empty Tabs Default State on Admin Preview and Storefront"/>
1717
<description value="As a Content Manager I want to see empty tab preview on the stage so that I see its position and can access settings"/>
@@ -159,8 +159,8 @@
159159
</test>
160160
<test name="TabAdvancedSectionDefaults">
161161
<annotations>
162-
<features value="PageBuilder"/>
163-
<stories value="Tabs: Tab Configuration"/>
162+
<features value="Pagebuilder"/>
163+
<stories value="Tabs"/>
164164
<useCaseId value="MAGETWO-71593"/>
165165
<title value="Tab advanced configuration has default properties"/>
166166
<description value="New tab has default values on Advanced section"/>

app/code/Magento/PageBuilder/Test/Mftf/Test/AdminPageBuilderTabConfigurationTest.xml

Lines changed: 38 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -10,10 +10,10 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
1111
<test name="EditTabNameByClickingOnHeaderInStage">
1212
<annotations>
13-
<features value="PageBuilder"/>
14-
<stories value="Tabs: Tab Configuration"/>
13+
<features value="Pagebuilder"/>
14+
<stories value="Tabs"/>
1515
<useCaseId value="MAGETWO-71593"/>
16-
<title value="Ability to edit Tab Name inline on the stage by clicking on tab header"/>
16+
<title value="Tab Configuration: Ability to edit Tab Name inline on the stage by clicking on tab header"/>
1717
<description value="Ability to edit Tab Name inline on the stage by clicking on tab header"/>
1818
<severity value="CRITICAL"/>
1919
<testCaseId value="MAGETWO-90360"/>
@@ -66,10 +66,10 @@
6666
</test>
6767
<test name="AddTabsWithBackgroundColorAndMinHeight">
6868
<annotations>
69-
<features value="PageBuilder"/>
70-
<stories value="Tabs: Tab Configuration"/>
69+
<features value="Pagebuilder"/>
70+
<stories value="Tabs"/>
7171
<useCaseId value="MAGETWO-71593"/>
72-
<title value="Add new tabs from the stage with customized background color and min height then view on admin and storefront"/>
72+
<title value="Tab Configuration: Add new tabs from the stage with customized background color and min height"/>
7373
<description value="Customize Tab background color and min height and apply to admin preview and storefront"/>
7474
<severity value="CRITICAL"/>
7575
<testCaseId value="MAGETWO-90000"/>
@@ -200,10 +200,10 @@
200200
</test>
201201
<test name="AddTabsWithBackgroundJpgTopCoverScrollFixedNoBackgroundRepeat">
202202
<annotations>
203-
<features value="PageBuilder"/>
204-
<stories value="Tabs: Tab Configuration"/>
203+
<features value="Pagebuilder"/>
204+
<stories value="Tabs"/>
205205
<useCaseId value="MAGETWO-71593"/>
206-
<title value="Add tabs with background jpg, position top, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
206+
<title value="Tab Configuration: Add tabs with background jpg, position top, size cover, attachment scroll and fixed, no background repeat"/>
207207
<description value="Add tabs with background jpg, position top, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
208208
<severity value="CRITICAL"/>
209209
<testCaseId value="MAGETWO-90000"/>
@@ -321,10 +321,10 @@
321321
</test>
322322
<test name="AddTabsWithBackgroundJpgTopCoverScrollFixedYesBackgroundRepeat">
323323
<annotations>
324-
<features value="PageBuilder"/>
325-
<stories value="Tabs: Tab Configuration"/>
324+
<features value="Pagebuilder"/>
325+
<stories value="Tabs"/>
326326
<useCaseId value="MAGETWO-71593"/>
327-
<title value="Add tabs with background jpg, position top, size cover, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
327+
<title value="Tab Configuration: Add tabs with background jpg, position top, size cover, attachment scroll and fixed, yes background repeat"/>
328328
<description value="Add tabs with background jpg, position top, size cover, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
329329
<severity value="CRITICAL"/>
330330
<testCaseId value="MAGETWO-90000"/>
@@ -433,10 +433,10 @@
433433
</test>
434434
<test name="AddTabsWithBackgroundJpgCenterCoverScrollFixedYesBackgroundRepeat">
435435
<annotations>
436-
<features value="PageBuilder"/>
437-
<stories value="Tabs: Tab Configuration"/>
436+
<features value="Pagebuilder"/>
437+
<stories value="Tabs"/>
438438
<useCaseId value="MAGETWO-71593"/>
439-
<title value="Add tabs with background jpg, position center, size cover, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
439+
<title value="Tab Configuration: Add tabs with background jpg, position center, size cover, attachment scroll and fixed, yes background repeat"/>
440440
<description value="Add tabs with background jpg, position center, size cover, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
441441
<severity value="CRITICAL"/>
442442
<testCaseId value="MAGETWO-90000"/>
@@ -550,10 +550,10 @@
550550
</test>
551551
<test name="AddTabsWithBackgroundJpgCenterAutoContainScrollFixedNoBackgroundRepeat">
552552
<annotations>
553-
<features value="PageBuilder"/>
554-
<stories value="Tabs: Tab Configuration"/>
553+
<features value="Pagebuilder"/>
554+
<stories value="Tabs"/>
555555
<useCaseId value="MAGETWO-71593"/>
556-
<title value="Add tabs with background jpg, position center, size auto and contain, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
556+
<title value="Tab Configuration: Add tabs with background jpg, position center, size auto and contain, attachment scroll and fixed, no background repeat"/>
557557
<description value="Add tabs with background jpg, position center, size auto and contain, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
558558
<severity value="CRITICAL"/>
559559
<testCaseId value="MAGETWO-90000"/>
@@ -677,10 +677,10 @@
677677
</test>
678678
<test name="AddTabsWithBackgroundJpgCenterCoverScrollFixedNoBackgroundRepeat">
679679
<annotations>
680-
<features value="PageBuilder"/>
681-
<stories value="Tabs: Tab Configuration"/>
680+
<features value="Pagebuilder"/>
681+
<stories value="Tabs"/>
682682
<useCaseId value="MAGETWO-71593"/>
683-
<title value="Add tabs with background jpg, position center, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
683+
<title value="Tab Configuration: Add tabs with background jpg, position center, size cover, attachment scroll and fixed, no background repeat"/>
684684
<description value="Add tabs with background jpg, position center, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
685685
<severity value="CRITICAL"/>
686686
<testCaseId value="MAGETWO-90000"/>
@@ -814,10 +814,10 @@
814814
</test>
815815
<test name="AddTabsWithBackgroundJpgBottomCoverScrollFixedNoBackgroundRepeat">
816816
<annotations>
817-
<features value="PageBuilder"/>
818-
<stories value="Tabs: Tab Configuration"/>
817+
<features value="Pagebuilder"/>
818+
<stories value="Tabs"/>
819819
<useCaseId value="MAGETWO-71593"/>
820-
<title value="Add tabs with background jpg, position bottom, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
820+
<title value="Tab Configuration: Add tabs with background jpg, position bottom, size cover, attachment scroll and fixed, no background repeat"/>
821821
<description value="Add tabs with background jpg, position bottom, size cover, attachment scroll and fixed, no background repeat, then view on admin and storefront"/>
822822
<severity value="CRITICAL"/>
823823
<testCaseId value="MAGETWO-90000"/>
@@ -932,10 +932,10 @@
932932
</test>
933933
<test name="AddTabsWithBackgroundGifBottomAutoContainScrollFixedYesBackgroundRepeatAfterSave">
934934
<annotations>
935-
<features value="PageBuilder"/>
936-
<stories value="Tabs: Tab Configuration"/>
935+
<features value="Pagebuilder"/>
936+
<stories value="Tabs"/>
937937
<useCaseId value="MAGETWO-71593"/>
938-
<title value="Add tabs with background gif, position bottom, size auto and contain, attachment scroll and fixed, yes repeat, view on admin before and after save, view storefront"/>
938+
<title value="Tab Configuration: Add tabs with background gif, position bottom, size auto and contain, attachment scroll and fixed, yes repeat, view on admin before and after save"/>
939939
<description value="Add tabs with background gif, position bottom, size auto and contain, attachment scroll and fixed, yes repeat, view on admin before and after save, view storefront"/>
940940
<severity value="CRITICAL"/>
941941
<testCaseId value="MAGETWO-90000"/>
@@ -1084,10 +1084,10 @@
10841084
</test>
10851085
<test name="AddTabsWithBackgroundGifCenterAutoContainFixedNoBackgroundRepeat">
10861086
<annotations>
1087-
<features value="PageBuilder"/>
1088-
<stories value="Tabs: Tab Configuration"/>
1087+
<features value="Pagebuilder"/>
1088+
<stories value="Tabs"/>
10891089
<useCaseId value="MAGETWO-71593"/>
1090-
<title value="Add tabs with background gif, position center, size auto and contain, attachment fixed, no background repeat, then view on admin and storefront"/>
1090+
<title value="Tab Configuration: Add tabs with background gif, position center, size auto and contain, attachment fixed, no background repeat"/>
10911091
<description value="Add tabs with background gif, position center, size auto and contain, attachment fixed, no background repeat, then view on admin and storefront"/>
10921092
<severity value="CRITICAL"/>
10931093
<testCaseId value="MAGETWO-90000"/>
@@ -1206,14 +1206,12 @@
12061206
<seeElement selector="{{TabOnStorefront.tabContentBackgroundSize('2', PageBuilderTabBackgroundSizeContain.value)}}" stepKey="seeTab2BackgroundSize"/>
12071207
<seeElement selector="{{TabOnStorefront.tabContentBackgroundRepeat('2', PageBuilderTabBackgroundRepeatNo.style)}}" stepKey="seeTab2BackgroundRepeat"/>
12081208
</test>
1209-
1210-
12111209
<test name="AddTabsWithBackgroundPngBottomAutoContainScrollNoBackgroundRepeatAfterSave">
12121210
<annotations>
1213-
<features value="PageBuilder"/>
1214-
<stories value="Tabs: Tab Configuration"/>
1211+
<features value="Pagebuilder"/>
1212+
<stories value="Tabs"/>
12151213
<useCaseId value="MAGETWO-71593"/>
1216-
<title value="Add tabs with background png, position bottom, size auto and contain, scroll, no repeat, view on admin before and after save, view storefront"/>
1214+
<title value="Tab Configuration: Add tabs with background png, position bottom, size auto and contain, scroll, no repeat, view on admin before and after save"/>
12171215
<description value="Add tabs with background png, position bottom, size auto and contain, scroll, no repeat, view on admin before and after save, view storefront"/>
12181216
<severity value="CRITICAL"/>
12191217
<testCaseId value="MAGETWO-90000"/>
@@ -1374,10 +1372,10 @@
13741372
</test>
13751373
<test name="AddTabsWithBackgroundPngTopAutoContainScrollFixedYesBackgroundRepeat">
13761374
<annotations>
1377-
<features value="PageBuilder"/>
1378-
<stories value="Tabs: Tab Configuration"/>
1375+
<features value="Pagebuilder"/>
1376+
<stories value="Tabs"/>
13791377
<useCaseId value="MAGETWO-71593"/>
1380-
<title value="Add tabs with background png, position top, size auto and contain, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
1378+
<title value="Tab Configuration: Add tabs with background png, position top, size auto and contain, attachment scroll and fixed, yes background repeat"/>
13811379
<description value="Add tabs with background png, position top, size auto and contain, attachment scroll and fixed, yes background repeat, then view on admin and storefront"/>
13821380
<severity value="CRITICAL"/>
13831381
<testCaseId value="MAGETWO-90000"/>
@@ -1502,8 +1500,8 @@
15021500
</test>
15031501
<test name="TabCustomizedAdvancedSettingsApplyInAdminPreviewAndStorefront">
15041502
<annotations>
1505-
<features value="PageBuilder"/>
1506-
<stories value="Tabs: Tab Configuration"/>
1503+
<features value="Pagebuilder"/>
1504+
<stories value="Tabs"/>
15071505
<useCaseId value="MAGETWO-71593"/>
15081506
<title value="Tabs - Customized Tabs Advanced Settings apply to admin preview storefront"/>
15091507
<description value="Configure Tab advanced settings and apply to admin preview and storefront"/>

app/code/Magento/PageBuilder/Test/Mftf/Test/AdminPageBuilderTabsDeleteTest.xml

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
xsi:noNamespaceSchemaLocation="../../../../../../../dev/tests/acceptance/vendor/magento/magento2-functional-testing-framework/src/Magento/FunctionalTestingFramework/Test/etc/testSchema.xsd">
1111
<test name="TabsRemoveLastTabByDeletingTabsContentType">
1212
<annotations>
13-
<features value="PageBuilder"/>
14-
<stories value="Tabs: Delete Tab From Tabs"/>
13+
<features value="Pagebuilder"/>
14+
<stories value="Tabs"/>
1515
<useCaseId value="MAGETWO-87052"/>
1616
<title value="Tabs Remove Last Tab Only By Deleting Tabs content type"/>
1717
<description value="A user should be able to remove tabs content type from a row with confirmation."/>
@@ -66,8 +66,8 @@
6666
</test>
6767
<test name="TabsRemoveSecondTabDefaultState">
6868
<annotations>
69-
<features value="PageBuilder"/>
70-
<stories value="Tabs: Delete Tab From Tabs"/>
69+
<features value="Pagebuilder"/>
70+
<stories value="Tabs"/>
7171
<useCaseId value="MAGETWO-87052"/>
7272
<testCaseId value="MAGETWO-90672"/>
7373
<title value="Tabs Remove Individual Default State Second Tab"/>
@@ -111,8 +111,8 @@
111111
<!-- Remove second tab -->
112112
<click selector="{{TabOnStage.tabOptionsRemove}}" stepKey="clickRemoveOption"/>
113113
<comment userInput="Removal confirmation modal not displayed when removing default state individual Tab" stepKey="AC3"/>
114-
<dontSee selector="{{PageBuilderActionsSection.modal}}" stepKey="dontSeeModalHeader"/>
115-
<dontSee selector="{{PageBuilderActionsSection.modalOk}}" stepKey="dontSeeModalOkHeader" />
114+
<waitForElementNotVisible time="30" selector="{{PageBuilderActionsSection.modal}}" stepKey="dontSeeModalHeader"/>
115+
<waitForElementNotVisible time="30" selector="{{PageBuilderActionsSection.modalOk}}" stepKey="dontSeeModalOkHeader"/>
116116
<comment userInput="Tabs with single Tab shown on the stage after save and on the storefront" stepKey="AC4"/>
117117
<actionGroup ref="saveAndContinueEditCmsPage" stepKey="saveAndContinueEditCmsPage"/>
118118
<actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage2"/>
@@ -126,8 +126,8 @@
126126
</test>
127127
<test name="TabsRemoveConfiguredSecondTabWithConfirmation">
128128
<annotations>
129-
<features value="PageBuilder"/>
130-
<stories value="Tabs: Delete Tab From Tabs"/>
129+
<features value="Pagebuilder"/>
130+
<stories value="Tabs"/>
131131
<useCaseId value="MAGETWO-87052"/>
132132
<testCaseId value="MAGETWO-90673"/>
133133
<title value="Tabs Remove Individual Configured Second Tab with Confirmation"/>
@@ -182,8 +182,8 @@
182182
</test>
183183
<test name="TabsRemoveSecondTabContainingTextWithConfirmation">
184184
<annotations>
185-
<features value="PageBuilder"/>
186-
<stories value="Tabs: Delete Tab From Tabs"/>
185+
<features value="Pagebuilder"/>
186+
<stories value="Tabs"/>
187187
<useCaseId value="MAGETWO-87052"/>
188188
<testCaseId value="MAGETWO-90674"/>
189189
<title value="Tabs Remove Second Tab Containing Content with Confirmation"/>
@@ -241,8 +241,8 @@
241241
</test>
242242
<test name="TabsRemoveConfiguredTabsContainerWithConfirmation">
243243
<annotations>
244-
<features value="PageBuilder"/>
245-
<stories value="Tabs: Delete Tab From Tabs"/>
244+
<features value="Pagebuilder"/>
245+
<stories value="Tabs"/>
246246
<useCaseId value="MAGETWO-87052"/>
247247
<testCaseId value="MAGETWO-90675"/>
248248
<title value="Tabs Remove Configured Tabs Container with Confirmation"/>
@@ -283,8 +283,8 @@
283283
</test>
284284
<test name="TabsOnDeleteCorrectTabBecomesActiveAndFocused">
285285
<annotations>
286-
<features value="PageBuilder"/>
287-
<stories value="Tabs: Delete Tab From Tabs"/>
286+
<features value="Pagebuilder"/>
287+
<stories value="Tabs"/>
288288
<useCaseId value="MAGETWO-87052"/>
289289
<testCaseId value="MAGETWO-90677"/>
290290
<title value="Tabs Remove Third Tab And Second Becomes Active And Focused"/>
@@ -326,8 +326,8 @@
326326
</test>
327327
<test name="TabsDismissedCustomizedTabRemovalConfirmationPersistsSession">
328328
<annotations>
329-
<features value="PageBuilder"/>
330-
<stories value="Tabs: Delete Tab From Tabs"/>
329+
<features value="Pagebuilder"/>
330+
<stories value="Tabs"/>
331331
<useCaseId value="MAGETWO-87052"/>
332332
<testCaseId value="MAGETWO-90671"/>
333333
<title value="Tabs Dismissed Customized Tab Removal Confirmation Persists Session"/>

0 commit comments

Comments
 (0)