|
18 | 18 | <testCaseId value="MC-29450"/> |
19 | 19 | <group value="pagebuilder"/> |
20 | 20 | <group value="pagebuilder-text"/> |
21 | | - <skip> |
22 | | - <issueId value="MQE-2288" /> |
23 | | - <issueId value="MQE-3208" /> |
24 | | - </skip> |
25 | 21 | <group value="pr_exclude"/> |
26 | 22 | </annotations> |
27 | 23 | <before> |
28 | | - <createData entity="_defaultCmsPage" stepKey="createCMSPage"/> |
| 24 | + <createData entity="_emptyCmsPage" stepKey="createCMSPage"/> |
29 | 25 | <actionGroup ref="CliEnableTinyMCEActionGroup" stepKey="enableTinyMCE" /> |
30 | 26 | <actionGroup ref="AdminLoginActionGroup" stepKey="loginAsAdmin"/> |
31 | 27 | </before> |
|
40 | 36 | <actionGroup ref="expandPageBuilderPanelMenuSection" stepKey="expandPageBuilderPanelMenuSection1"> |
41 | 37 | <argument name="contentType" value="PageBuilderTextContentType"/> |
42 | 38 | </actionGroup> |
43 | | - <actionGroup ref="dragContentTypeToDropZone" stepKey="dragTextIntoStage"> |
| 39 | + <actionGroup ref="dragContentTypeToStage" stepKey="dragRowToRootContainer"> |
| 40 | + <argument name="contentType" value="PageBuilderRowContentType"/> |
| 41 | + <argument name="containerTargetType" value="PageBuilderRootContainerContentType"/> |
| 42 | + </actionGroup> |
| 43 | + <actionGroup ref="dragContentTypeToContainer" stepKey="dragTextIntoStage"> |
44 | 44 | <argument name="contentType" value="PageBuilderTextContentType"/> |
45 | | - <argument name="containerTargetType" value="PageBuilderRowContentType"/> |
46 | | - <argument name="dropZoneIndex" value="2"/> |
47 | 45 | </actionGroup> |
48 | 46 | <actionGroup ref="focusTinyMCE" stepKey="focusTinyMCE"/> |
49 | 47 | <!-- Create new Heading 2 --> |
|
79 | 77 | <argument name="endY">{{TinyMCEPartialHeadingSelection.endY}}</argument> |
80 | 78 | </helper> |
81 | 79 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus"/> |
82 | | - <actionGroup ref="assertSelectedText" stepKey="assertSelection"> |
83 | | - <argument name="expectedSelectedText" value="TinyMCEPartialHeadingSelection"/> |
84 | | - </actionGroup> |
| 80 | + <executeJS function="return jQuery('.inline-wysiwyg h2').text().substring(1, 11);" stepKey="selectionString"/> |
| 81 | + <assertEquals stepKey="assertSelection"> |
| 82 | + <expectedResult type="string">{{TinyMCEPartialHeadingSelection.selection}}</expectedResult> |
| 83 | + <actualResult type="variable">selectionString</actualResult> |
| 84 | + </assertEquals> |
85 | 85 | <reloadPage stepKey="reloadPage"/> |
86 | 86 | <waitForPageLoad stepKey="waitForReload"/> |
87 | 87 | <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage2"/> |
88 | 88 | <actionGroup ref="scrollToTinyMCE" stepKey="scrollToTinyMCE2"/> |
89 | | - <!-- Select portion of paragraph text "es stri" --> |
| 89 | + <!-- Select portion of paragraph text "t strin" --> |
90 | 90 | <helper class="Magento\PageBuilder\Test\Mftf\Helper\SelectText" method="selectText" stepKey="selectTextInTinyMCE"> |
91 | 91 | <argument name="context">//div[contains(@class, 'inline-wysiwyg')]//p[2]</argument> |
92 | 92 | <argument name="startX">{{TinyMCEPartialTextSelection.startX}}</argument> |
|
95 | 95 | <argument name="endY">{{TinyMCEPartialTextSelection.endY}}</argument> |
96 | 96 | </helper> |
97 | 97 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus2"/> |
98 | | - <actionGroup ref="assertSelectedText" stepKey="assertSelection2"> |
99 | | - <argument name="expectedSelectedText" value="TinyMCEPartialTextSelection"/> |
100 | | - </actionGroup> |
| 98 | + <executeJS function="return jQuery('.inline-wysiwyg p:last-child').text().substring(3, 10);" stepKey="selectionString2"/> |
| 99 | + <assertEquals stepKey="assertSelection2"> |
| 100 | + <expectedResult type="string">{{TinyMCEPartialTextSelection.selection}}</expectedResult> |
| 101 | + <actualResult type="variable">selectionString2</actualResult> |
| 102 | + </assertEquals> |
101 | 103 | <reloadPage stepKey="reloadPage2"/> |
102 | 104 | <waitForPageLoad stepKey="waitForReload2"/> |
103 | 105 | <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage3"/> |
|
113 | 115 | </helper> |
114 | 116 |
|
115 | 117 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus3"/> |
116 | | - <actionGroup ref="assertSelectedText" stepKey="assertSelection3"> |
117 | | - <argument name="expectedSelectedText" value="TinyMCEHeadingVariableTextSelection"/> |
118 | | - </actionGroup> |
| 118 | + <executeJS function="return jQuery('.inline-wysiwyg').text().substring(1, 35);" stepKey="selectionString3"/> |
| 119 | + <assertEquals stepKey="assertSelection3"> |
| 120 | + <expectedResult type="string">{{TinyMCEHeadingVariableTextSelection.selection}}</expectedResult> |
| 121 | + <actualResult type="variable">selectionString3</actualResult> |
| 122 | + </assertEquals> |
119 | 123 | </test> |
120 | 124 | </tests> |
0 commit comments