|
18 | 18 | <testCaseId value="MC-29450"/>
|
19 | 19 | <group value="pagebuilder"/>
|
20 | 20 | <group value="pagebuilder-text"/>
|
21 |
| - <!-- skip due to MQE-1964 --> |
22 |
| - <group value="skip"/> |
23 | 21 | </annotations>
|
24 | 22 | <before>
|
25 | 23 | <createData entity="_defaultCmsPage" stepKey="createCMSPage"/>
|
|
64 | 62 | <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage"/>
|
65 | 63 | <actionGroup ref="scrollToTinyMCE" stepKey="scrollToTinyMCE"/>
|
66 | 64 | <!-- Select portion of Heading "his is a h" -->
|
67 |
| - <!--<executeInSelenium function="function ($webdriver) use ($I) {--> |
68 |
| - <!--$heading = $webdriver->findElement(\Facebook\WebDriver\WebDriverBy::xpath('//div[contains(@class, \'inline-wysiwyg\')]//h2'));--> |
69 |
| - <!--$actions = new \Facebook\WebDriver\Interactions\WebDriverActions($webdriver);--> |
70 |
| - <!--$actions->moveToElement($heading, {{TinyMCEPartialHeadingSelection.startX}}, {{TinyMCEPartialHeadingSelection.startY}})--> |
71 |
| - <!-- ->clickAndHold()--> |
72 |
| - <!-- ->moveToElement($heading, {{TinyMCEPartialHeadingSelection.endX}}, {{TinyMCEPartialHeadingSelection.endY}})--> |
73 |
| - <!-- ->release()--> |
74 |
| - <!-- ->perform();--> |
75 |
| - <!--}" stepKey="selectHeadingTextInTinyMCE"/>--> |
| 65 | + <helper class="\Magento\User\Test\Mftf\Helper\SelectText" method="selectText" stepKey="selectHeadingTextInTinyMCE"> |
| 66 | + <argument name="context">//div[contains(@class, 'inline-wysiwyg')]//h2</argument> |
| 67 | + <argument name="startX">{{TinyMCEPartialHeadingSelection.startX}}</argument> |
| 68 | + <argument name="startY">{{TinyMCEPartialHeadingSelection.startY}}</argument> |
| 69 | + <argument name="endX">{{TinyMCEPartialHeadingSelection.endX}}</argument> |
| 70 | + <argument name="endY">{{TinyMCEPartialHeadingSelection.endY}}</argument> |
| 71 | + </helper> |
76 | 72 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus"/>
|
77 | 73 | <actionGroup ref="assertSelectedText" stepKey="assertSelection">
|
78 | 74 | <argument name="expectedSelectedText" value="TinyMCEPartialHeadingSelection"/>
|
|
82 | 78 | <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage2"/>
|
83 | 79 | <actionGroup ref="scrollToTinyMCE" stepKey="scrollToTinyMCE2"/>
|
84 | 80 | <!-- Select portion of paragraph text "es stri" -->
|
85 |
| - <!--<executeInSelenium function="function ($webdriver) use ($I) {--> |
86 |
| - <!--$text = $webdriver->findElement(\Facebook\WebDriver\WebDriverBy::xpath('//div[contains(@class, \'inline-wysiwyg\')]//p[2]'));--> |
87 |
| - <!--$actions = new \Facebook\WebDriver\Interactions\WebDriverActions($webdriver);--> |
88 |
| - <!--$actions->moveToElement($text, {{TinyMCEPartialTextSelection.startX}}, {{TinyMCEPartialTextSelection.startY}})--> |
89 |
| - <!-- ->clickAndHold()--> |
90 |
| - <!-- ->moveToElement($text, {{TinyMCEPartialTextSelection.endX}}, {{TinyMCEPartialTextSelection.endY}})--> |
91 |
| - <!-- ->release()--> |
92 |
| - <!-- ->perform();--> |
93 |
| - <!--}" stepKey="selectTextInTinyMCE"/>--> |
| 81 | + <helper class="\Magento\User\Test\Mftf\Helper\SelectText" method="selectText" stepKey="selectTextInTinyMCE"> |
| 82 | + <argument name="context">//div[contains(@class, 'inline-wysiwyg')]//p[2]</argument> |
| 83 | + <argument name="startX">{{TinyMCEPartialTextSelection.startX}}</argument> |
| 84 | + <argument name="startY">{{TinyMCEPartialTextSelection.startY}}</argument> |
| 85 | + <argument name="endX">{{TinyMCEPartialTextSelection.endX}}</argument> |
| 86 | + <argument name="endY">{{TinyMCEPartialTextSelection.endY}}</argument> |
| 87 | + </helper> |
94 | 88 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus2"/>
|
95 | 89 | <actionGroup ref="assertSelectedText" stepKey="assertSelection2">
|
96 | 90 | <argument name="expectedSelectedText" value="TinyMCEPartialTextSelection"/>
|
|
100 | 94 | <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage3"/>
|
101 | 95 | <actionGroup ref="scrollToTinyMCE" stepKey="scrollToTinyMCE3"/>
|
102 | 96 | <!-- Select from part of the heading, over the variable, to part of the text string -->
|
103 |
| - <!--<executeInSelenium function="function ($webdriver) use ($I) {--> |
104 |
| - <!--$heading = $webdriver->findElement(\Facebook\WebDriver\WebDriverBy::xpath('//div[contains(@class, \'inline-wysiwyg\')]//h2'));--> |
105 |
| - <!--$text = $webdriver->findElement(\Facebook\WebDriver\WebDriverBy::xpath('//div[contains(@class, \'inline-wysiwyg\')]//p[2]'));--> |
106 |
| - <!--$actions = new \Facebook\WebDriver\Interactions\WebDriverActions($webdriver);--> |
107 |
| - <!--$actions->moveToElement($heading, {{TinyMCEPartialHeadingSelection.startX}}, {{TinyMCEPartialHeadingSelection.startY}})--> |
108 |
| - <!-- ->clickAndHold()--> |
109 |
| - <!-- ->moveToElement($text, {{TinyMCEPartialTextSelection.endX}}, {{TinyMCEPartialTextSelection.endY}})--> |
110 |
| - <!-- ->release()--> |
111 |
| - <!-- ->perform();--> |
112 |
| - <!--}" stepKey="selectHeadingTextAndVariableTinyMCE"/>--> |
| 97 | + <helper class="\Magento\User\Test\Mftf\Helper\SelectText" method="selectHeadingTextAndVariableTinyMCE" stepKey="selectHeadingTextAndVariableTinyMCE"> |
| 98 | + <argument name="firstContext">//div[contains(@class, 'inline-wysiwyg')]//h[2]</argument> |
| 99 | + <argument name="secondContext">//div[contains(@class, 'inline-wysiwyg')]//p[2]</argument> |
| 100 | + <argument name="startX">{{TinyMCEPartialHeadingSelection.startX}}</argument> |
| 101 | + <argument name="startY">{{TinyMCEPartialHeadingSelection.startY}}</argument> |
| 102 | + <argument name="endX">{{TinyMCEPartialTextSelection.endX}}</argument> |
| 103 | + <argument name="endY">{{TinyMCEPartialTextSelection.endY}}</argument> |
| 104 | + </helper> |
| 105 | + |
113 | 106 | <actionGroup ref="waitForTinyMCEInFocus" stepKey="waitForTinyMCEInFocus3"/>
|
114 | 107 | <actionGroup ref="assertSelectedText" stepKey="assertSelection3">
|
115 | 108 | <argument name="expectedSelectedText" value="TinyMCEHeadingVariableTextSelection"/>
|
|
0 commit comments