Skip to content

Commit b95d2a9

Browse files
author
Hwashiang Yu
committed
MC-5383: Option Menus, Heading Inline Editor & tinyMCE Inline Editor Are Cut Off on Full Screen View
- Corrected selector index for dropping and duplicating content types - Updated test steps fro consistency and stability - Fixed incorrect annotations
1 parent 682925b commit b95d2a9

File tree

2 files changed

+16
-14
lines changed

2 files changed

+16
-14
lines changed

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

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1305,7 +1305,7 @@
13051305
<test name="HeadingLiveEditToolbarNotCutOffInFullScreenMode">
13061306
<annotations>
13071307
<features value="PageBuilder"/>
1308-
<stories value="Panel"/>
1308+
<stories value="Heading"/>
13091309
<title value="Heading live edit toolbar should not overflow viewport bounds (get 'cut off') in full screen mode"/>
13101310
<description value="As a content creator I want live edit toolbar for heading content type to be always positioned within viewport bounds so that they are accessible to me within the UI"/>
13111311
<severity value="MAJOR"/>
@@ -1330,11 +1330,6 @@
13301330
<actionGroup ref="dragContentTypeToStage" stepKey="dragColumnIntoStage">
13311331
<argument name="contentType" value="PageBuilderColumnContentType"/>
13321332
</actionGroup>
1333-
<!-- Add Heading Content Type -->
1334-
<comment userInput="Add Heading Content Type" stepKey="commentAddInnerContentType"/>
1335-
<actionGroup ref="expandPageBuilderPanelGroup" stepKey="expandPageBuilderInnerContentTypePanelGroup">
1336-
<argument name="group" value="PageBuilderHeadingContentType"/>
1337-
</actionGroup>
13381333
<!-- Duplicate left column 3 times to create 1/12 column on the left configuration -->
13391334
<comment userInput="Duplicate left column 3 times to create 1/12 column on the left configuration" stepKey="commentInitialResize"/>
13401335
<actionGroup ref="duplicateContentType" stepKey="duplicateFirstColumn1Of3">
@@ -1349,7 +1344,12 @@
13491344
<argument name="contentType" value="PageBuilderColumnContentType"/>
13501345
<argument name="targetIndex" value="1"/>
13511346
</actionGroup>
1352-
<waitForElementVisible selector="{{ColumnOnBackend.displayLabel('1','1/12')}}" stepKey="validateFirstColumnWidth"/>
1347+
<seeElement selector="{{ColumnOnBackend.displayLabel('1','1/12')}}" stepKey="validateFirstColumnWidth"/>
1348+
<!-- Add Heading Content Type -->
1349+
<comment userInput="Add Heading Content Type" stepKey="commentAddInnerContentType"/>
1350+
<actionGroup ref="expandPageBuilderPanelGroup" stepKey="expandPageBuilderInnerContentTypePanelGroup">
1351+
<argument name="group" value="PageBuilderHeadingContentType"/>
1352+
</actionGroup>
13531353
<actionGroup ref="dragContentTypeToContainer" stepKey="dragInnerContentTypeIntoColumn">
13541354
<argument name="contentType" value="PageBuilderHeadingContentType"/>
13551355
<argument name="containerTargetType" value="PageBuilderColumnContentType"/>
@@ -1425,7 +1425,7 @@
14251425
<test name="HeadingOptionsMenuNotOverflowRight">
14261426
<annotations>
14271427
<features value="PageBuilder"/>
1428-
<stories value="Panel"/>
1428+
<stories value="Heading"/>
14291429
<title value="Heading options menu should not overflow viewport bounds (get 'cut off') on the right"/>
14301430
<description value="As a content creator I want heading options menus to be always positioned within viewport bounds so that they are accessible to me within the UI"/>
14311431
<severity value="MAJOR"/>
@@ -1454,13 +1454,13 @@
14541454
<comment userInput="Duplicate right column 2 times to create 1/12 column on the right configuration" stepKey="commentInitialResize"/>
14551455
<actionGroup ref="duplicateContentType" stepKey="duplicateLastColumn1Of2">
14561456
<argument name="contentType" value="PageBuilderColumnContentType"/>
1457-
<argument name="targetIndex" value="1"/>
1457+
<argument name="targetIndex" value="2"/>
14581458
</actionGroup>
14591459
<actionGroup ref="duplicateContentType" stepKey="duplicateLastColumn2Of2">
14601460
<argument name="contentType" value="PageBuilderColumnContentType"/>
1461-
<argument name="targetIndex" value="2"/>
1461+
<argument name="targetIndex" value="3"/>
14621462
</actionGroup>
1463-
<waitForElementVisible selector="{{ColumnOnBackend.displayLabel('3','1/12')}}" stepKey="validateLastColumnWidth"/>
1463+
<seeElement selector="{{ColumnOnBackend.displayLabel('4','1/12')}}" stepKey="validateLastColumnWidth"/>
14641464
<!-- Add Heading Content Type -->
14651465
<comment userInput="Add Heading Content Type" stepKey="commentAddHeadingContentType"/>
14661466
<actionGroup ref="expandPageBuilderPanelGroup" stepKey="expandHeadingPageBuilderPanelGroup">
@@ -1469,7 +1469,7 @@
14691469
<actionGroup ref="dragContentTypeToContainer" stepKey="dragHeadingContentTypeIntoColumn">
14701470
<argument name="contentType" value="PageBuilderHeadingContentType"/>
14711471
<argument name="containerTargetType" value="PageBuilderColumnContentType"/>
1472-
<argument name="containerTargetIndex" value="2"/>
1472+
<argument name="containerTargetIndex" value="4"/>
14731473
<argument name="contentTypeIndex" value="1"/>
14741474
</actionGroup>
14751475
<actionGroup ref="clickOutsideLiveEditHeading" stepKey="unFocusHeadingEditor">
@@ -1483,7 +1483,7 @@
14831483
<actionGroup ref="dragContentTypeToContainer" stepKey="dragInnerContentTypeIntoColumn">
14841484
<argument name="contentType" value="PageBuilderTextContentType"/>
14851485
<argument name="containerTargetType" value="PageBuilderColumnContentType"/>
1486-
<argument name="containerTargetIndex" value="2"/>
1486+
<argument name="containerTargetIndex" value="4"/>
14871487
<argument name="contentTypeIndex" value="1"/>
14881488
</actionGroup>
14891489
<actionGroup ref="unFocusOptionMenu" stepKey="unFocusTextEditor">

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

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2650,7 +2650,7 @@
26502650
<test name="TextTooltipMenusAreNotCutOffInFullScreenMode" extends="HeadingLiveEditToolbarNotCutOffInFullScreenMode">
26512651
<annotations>
26522652
<features value="PageBuilder"/>
2653-
<stories value="Panel"/>
2653+
<stories value="Text"/>
26542654
<title value="Text tooltip menus should not overflow viewport bounds (get 'cut off') in full screen mode"/>
26552655
<description value="As a content creator I want text tooltip menus to be always positioned within viewport bounds so that they are accessible to me within the UI"/>
26562656
<severity value="MAJOR"/>
@@ -2684,6 +2684,7 @@
26842684
<waitForElementVisible selector="{{TextOnStage.wysiwyg('1')}}" stepKey="waitForContentTypeToBeVisible"/>
26852685
<click selector="{{TextOnStage.wysiwyg('1')}}" stepKey="focusOnInnerContentType"/>
26862686
<waitForPageLoad after="focusOnInnerContentType" stepKey="waitForToolbarAnimationAfterOverflow"/>
2687+
<waitForElementVisible selector="{{PageBuilderStage.inlineWYSIWYGEditorPanel(PageBuilderTextContentType.role, '1')}}" after="waitForToolbarAnimationAfterOverflow" stepKey="waitForToolbarVisibleAfterOverflow"/>
26872688
<executeJS function="return document.evaluate(`{{PageBuilderStage.inlineWYSIWYGEditorPanel(PageBuilderTextContentType.role, '1')}}`, document.body).iterateNext().getBoundingClientRect().top" stepKey="toolbarTopPositionAfterOverflow"/>
26882689
<executeJS function="return document.evaluate(`{{TextOnStage.wysiwyg('1')}}`, document.body).iterateNext().getBoundingClientRect().bottom" stepKey="inputBoxBottomPositionAfterOverflow"/>
26892690
<executeJS function="return document.evaluate(`{{TextOnStage.wysiwyg('1')}}`, document.body).iterateNext().getBoundingClientRect().top" stepKey="inputBoxTopPositionAfterOverflow"/>
@@ -2692,6 +2693,7 @@
26922693
</actionGroup>
26932694
<click selector="{{TextOnStage.wysiwyg('1')}}" stepKey="focusOnInnerContentTypeAfterExitFullScreen"/>
26942695
<waitForPageLoad after="focusOnInnerContentTypeAfterExitFullScreen" stepKey="waitForToolbarAnimationAfterExitFullScreen"/>
2696+
<waitForElementVisible selector="{{PageBuilderStage.inlineWYSIWYGEditorPanel(PageBuilderTextContentType.role, '1')}}" after="waitForToolbarAnimationAfterExitFullScreen" stepKey="waitForToolbarVisibleAfterExitFullScreen"/>
26952697
<executeJS function="return document.evaluate(`{{TextOnStage.wysiwyg('1')}}`, document.body).iterateNext().getBoundingClientRect().top" stepKey="inputBoxTopPositionAfterExitFullScreen"/>
26962698
<executeJS function="return document.evaluate(`{{PageBuilderStage.inlineWYSIWYGEditorPanel(PageBuilderTextContentType.role, '1')}}`, document.body).iterateNext().getBoundingClientRect().top" stepKey="toolbarTopPositionAfterExitFullScreen"/>
26972699
<executeJS function="return document.evaluate(`{{PageBuilderStage.inlineWYSIWYGEditorPanel(PageBuilderTextContentType.role, '1')}}`, document.body).iterateNext().getBoundingClientRect().bottom" stepKey="toolbarBottomPositionAfterExitFullScreen"/>

0 commit comments

Comments
 (0)