Skip to content

Commit a5a1df9

Browse files
committed
MC-3228: Add Missing P0-P1 MFTF Tests For Slider
- Fixing SliderCanManageSlides test
1 parent eae143d commit a5a1df9

File tree

1 file changed

+44
-55
lines changed

1 file changed

+44
-55
lines changed

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

Lines changed: 44 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -1411,15 +1411,14 @@
14111411
</actionGroup>
14121412
</test>
14131413
<test name="SliderCanManageSlides">
1414-
<!--todo-->
14151414
<annotations>
14161415
<features value="PageBuilder"/>
14171416
<stories value="Slider"/>
1418-
<title value="Slider - Can add slides and see tooltip and slide name when clicking navigation dots"/>
1417+
<title value="Slider - Validate Active Navigation Dots And Tooltips"/>
14191418
<description value="A user should be able to manage slides by using the navigation dots in admin preview"/>
14201419
<severity value="CRITICAL"/>
14211420
<useCaseId value="MAGETWO-83933"/>
1422-
<testCaseId value="MAGETWO-87949"/>
1421+
<testCaseId value="MC-2562"/>
14231422
<group value="pagebuilder"/>
14241423
<group value="pagebuilder-slide"/>
14251424
<group value="pagebuilder-sliderCommon"/>
@@ -1435,83 +1434,73 @@
14351434
<actionGroup ref="expandPageBuilderPanelGroup" stepKey="expandPageBuilderPanelGroup">
14361435
<argument name="group" value="PageBuilderSliderContentType"/>
14371436
</actionGroup>
1438-
<comment userInput="User adds Slider into the content, user sees first Slide to be displayed inside the slider" stepKey="AC1"/>
1439-
<actionGroup ref="dragContentTypeToStageAndExpectEditPanel" stepKey="dragSliderIntoStage">
1437+
<actionGroup ref="dragContentTypeToStageAndExpectEditPanel" stepKey="dragIntoStage">
14401438
<argument name="contentType" value="PageBuilderSliderContentType"/>
14411439
</actionGroup>
1442-
<comment userInput="User sees Slide configuration opened with a delay." stepKey="AC2"/>
14431440
<actionGroup ref="closeEditPanelSettings" stepKey="closeSlideEditPanel"/>
1441+
<!-- Validate Slide 1 Is Shown -->
1442+
<comment userInput="Validate Slide 1 Is Shown" stepKey="commentValidateStage1"/>
14441443
<seeElement selector="{{SlideOnBackend.emptySlide('1')}}" stepKey="seeFirstSlideOnStage"/>
1445-
1446-
<comment userInput="Slide is focused, its option panel is displayed on top of the slider dot." stepKey="AC3"/>
1447-
<assertElementContainsAttribute selector="{{SliderOnStage.slideNavigationDot('1', '1')}}" attribute="class" expectedValue="active" stepKey="assertFirstDotActive"/>
1448-
<seeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsPanel"/>
1449-
1450-
<comment userInput="User sees Slide 1 default name in the Slide Option Panel." stepKey="AC4"/>
1451-
<see userInput="Slide 1" selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsAppearWithSlide1DefaultTitle"/>
1452-
1453-
<comment userInput="User updates settings of first slide and saves configuration." stepKey="AC5"/>
1444+
<seeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsMenu"/>
1445+
<assertElementContainsAttribute selector="{{SliderOnStage.slideNavigationDot('1', '1')}}" attribute="class" stepKey="assertFirstDotActive">
1446+
<expectedResult type="string">active</expectedResult>
1447+
</assertElementContainsAttribute>
1448+
<see selector="{{SlideOnBackend.optionsMenu('1')}}" userInput="Slide 1" stepKey="seeSlideOptionsAppearWithSlide1DefaultTitle"/>
1449+
<!-- Update Slide 1 -->
1450+
<comment userInput="Update Slide 1" stepKey="commentUpdateSlide1"/>
14541451
<actionGroup ref="openPageBuilderEditPanelSmallByIndex" stepKey="openEditPanel1">
14551452
<argument name="section" value="SlideOnBackend"/>
14561453
</actionGroup>
14571454
<actionGroup ref="fillSlideOutPanelFieldGeneral" stepKey="enterSlideNameText1">
14581455
<argument name="property" value="PageBuilderSlideItemSlideName_Slide1"/>
14591456
</actionGroup>
14601457
<actionGroup ref="saveEditPanelSettings" stepKey="saveEditPanel1Settings"/>
1461-
1462-
<comment userInput="Slide option panel is displayed" stepKey="AC6"/>
1463-
<waitForElementVisible time="5" selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="SeeSlideOptionsAfterSaveSlide"/>
1464-
1465-
<comment userInput="User hovers Slider, user sees Slider option panel" stepKey="AC7"/>
1466-
<scrollTo selector="{{CmsNewPagePageActionsSection.content}}" stepKey="scrollToContent"/>
1467-
<moveMouseOver selector="{{PageBuilderStage.contentTypeInStage(PageBuilderSliderContentType.role)}}" stepKey="onMouseOverContentTypeStage1"/>
1468-
<wait time="0.5" stepKey="waitForMouseOverAnimation" />
1458+
<!-- User Still Sees Slide Item Option Menu If Hovering Over Slider -->
1459+
<comment userInput="User Still Sees Slide Item Option Menu If Hovering Over Slider" stepKey="commentHoverSlider"/>
1460+
<seeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsMenu2"/>
1461+
<moveMouseOver selector="{{PageBuilderStage.contentTypeInStageByIndex(PageBuilderSliderContentType.role, '1')}}" stepKey="mouseOverSlider"/>
1462+
<waitForPageLoad stepKey="waitForPageLoad"/>
1463+
<seeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsMenu3"/>
1464+
<dontSeeElement selector="{{PageBuilderContentTypeOptionsMenu.contentTypeOptionsMenuByIndex(PageBuilderSliderContentType.role, '1')}}" stepKey="dontSeeSliderOptionsMenu"/>
1465+
<!-- User Sees Slider Option Menu After Unfocusing Slide Item -->
1466+
<comment userInput="User Sees Slider Option Menu After Unfocusing Slide Item" stepKey="commentHoverSlider2"/>
14691467
<click selector="{{PageBuilderPanel.searchPanel}}" stepKey="unFocusSlide"/>
1470-
<moveMouseOver selector="{{PageBuilderStage.contentTypeInStage(PageBuilderSliderContentType.role)}}" stepKey="onMouseOverContentTypeStage2"/>
1471-
1472-
<waitForElementVisible time="5" selector="{{PageBuilderContentTypeOptionsMenu.contentTypeOptionsMenu(PageBuilderSliderContentType.role)}}" stepKey="seeContentTypeOptionsMenu"/>
1473-
<moveMouseOver selector="{{PageBuilderContentTypeOptionsMenu.contentTypeOptionsMenu(PageBuilderSliderContentType.role)}}" stepKey="onMouseOverOptionsMenu"/>
1474-
1475-
<comment userInput="User doesn't see Slide Option panel, both option panels not displayed at once." stepKey="AC8"/>
1476-
<waitForElementNotVisible time="5" selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="waitForSlideOptionsPanelNotVisible" />
1477-
<dontSeeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="seeSlideOptionsPanelStillHidden"/>
1478-
1479-
<comment userInput="User sees button (+) inside the Slider Option Panel. Tooltip shows Add New Slide" stepKey="AC9"/>
1480-
<seeElement selector="{{PageBuilderContentTypeOptionsMenu.contentTypeAdd(PageBuilderSliderContentType.role)}}" stepKey="seeAddNewSlideChild"/>
1481-
<assertElementContainsAttribute selector="{{PageBuilderContentTypeOptionsMenu.contentTypeAdd(PageBuilderSliderContentType.role)}}" attribute="title" expectedValue="Add" stepKey="assertAddSlideName"/>
1482-
1483-
<comment userInput="User clicks (+) icon, sees new slide added to to the right." stepKey="AC10"/>
1468+
<moveMouseOver selector="{{PageBuilderStage.contentTypeInStageByIndex(PageBuilderSliderContentType.role, '1')}}" stepKey="mouseOverSlider2"/>
1469+
<waitForPageLoad stepKey="waitForPageLoad2"/>
1470+
<waitForElementVisible selector="{{PageBuilderContentTypeOptionsMenu.contentTypeOptionsMenuByIndex(PageBuilderSliderContentType.role, '1')}}" stepKey="waitForContentTypeOptionsMenu"/>
1471+
<seeElement selector="{{PageBuilderContentTypeOptionsMenu.contentTypeOptionsMenuByIndex(PageBuilderSliderContentType.role, '1')}}" stepKey="seeOptionsMenu"/>
1472+
<dontSeeElement selector="{{SlideOnBackend.optionsMenu('1')}}" stepKey="dontSeeSlideOptionsMenu"/>
1473+
<!-- Add 2nd Slide -->
1474+
<comment userInput="Add 2nd Slide" stepKey="commentAddSlide"/>
14841475
<actionGroup ref="addSlide" stepKey="addSecondSlide"/>
1485-
1486-
<comment userInput="User sees slide configuration opened with a delay." stepKey="AC11"/>
1487-
<waitForLoadingMaskToDisappear stepKey="waitForSlideAnimation2" />
1488-
<waitForElementVisible stepKey="waitForNewSlide2" selector="{{EditPanelForm.editFormClose}}" time="10"/>
1489-
<see userInput="Edit Slide" selector="{{EditPanelForm.editFormTitle}}" stepKey="seeEditSlide2"/>
14901476
<actionGroup ref="closeEditPanelSettings" stepKey="closeSlideEditPanel2"/>
1491-
1492-
<comment userInput="New slide is focused, its option panel is displayed on top of the slider dot" stepKey="AC12"/>
1493-
<waitForElementVisible selector="{{SliderOnStage.slideNavigationDot('1', '2')}}" stepKey="assertSecondDotAdded"/>
1494-
<assertElementContainsAttribute selector="{{SliderOnStage.slideNavigationDot('1', '2')}}" attribute="class" expectedValue="active" stepKey="assertSecondDotActive"/>
1495-
<seeElement selector="{{SlideOnBackend.optionsMenu('2')}}" stepKey="seeSlideOptionsPanel2"/>
1496-
1497-
<comment userInput="Slide has default title Title N that reflects the order of the slide in the Slider." stepKey="AC13"/>
1477+
<!-- Validate Slide 2 Is Shown -->
1478+
<comment userInput="Validate Slide 2 Is Shown" stepKey="commentValidateStage2"/>
1479+
<seeElement selector="{{SliderOnStage.slideNavigationDot('1', '2')}}" stepKey="seeSecondDot"/>
1480+
<seeElement selector="{{SlideOnBackend.optionsMenu('2')}}" stepKey="seeSlideOptionsMenu4"/>
1481+
<assertElementContainsAttribute selector="{{SliderOnStage.slideNavigationDot('1', '2')}}" attribute="class" stepKey="assertSecondDotActive">
1482+
<expectedResult type="string">active</expectedResult>
1483+
</assertElementContainsAttribute>
14981484
<see userInput="Slide 2" selector="{{SlideOnBackend.optionsMenu('2')}}" stepKey="seeSlideOptionsAppearWithSlide2DefaultTitle"/>
1499-
<click stepKey="focusOutsideStage" selector="{{PageBuilderPanel.searchPanel}}"/>
1500-
<comment userInput="User updates settings of second slide and saves configuration." stepKey="AC14"/>
1485+
<click selector="{{PageBuilderPanel.searchPanel}}" stepKey="unFocusSlide2"/>
1486+
<!-- Update Slide 2 -->
1487+
<comment userInput="Update Slide 2" stepKey="commentUpdateSlide2"/>
15011488
<actionGroup ref="openPageBuilderEditPanelSmallByIndex" stepKey="openEditPanel2">
15021489
<argument name="section" value="SlideOnBackend"/>
15031490
<argument name="targetIndex" value="2"/>
15041491
</actionGroup>
15051492
<actionGroup ref="fillSlideOutPanelFieldGeneral" stepKey="enterSlideNameText2">
15061493
<argument name="property" value="PageBuilderSlideItemSlideName_Slide2"/>
15071494
</actionGroup>
1508-
<actionGroup ref="saveEditPanelSettings" stepKey="saveEditPanel2Settings"/>
1509-
1510-
<comment userInput="User hovers each slide dot, user sees tooltip displayed with Slide name" stepKey="AC15"/>
1511-
<click selector="{{PageBuilderPanel.searchPanel}}" stepKey="unFocusSlide2"/>
1495+
<actionGroup ref="saveEditPanelSettings" stepKey="saveEditPanelSettings2"/>
1496+
<!-- Validate On Hover Tooltips -->
1497+
<comment userInput="Validate On Hover Tooltips" stepKey="commentValidateTooltips"/>
1498+
<click selector="{{PageBuilderPanel.searchPanel}}" stepKey="unFocusSlide3"/>
15121499
<moveMouseOver selector="{{SliderOnStage.activeSlideNavigationDot}}" stepKey="mouseOverActiveSlide2"/>
1500+
<waitForPageLoad stepKey="waitForPageLoad3"/>
15131501
<see userInput="{{PageBuilderSlideItemSlideName_Slide2.value}}" selector="{{SliderOnStage.slideNavigationDotNameTooltip('1')}}" stepKey="seeSlideName2InTooltip"/>
15141502
<moveMouseOver selector="{{SliderOnStage.slideNavigationDot('1', '1')}}" stepKey="moveMouseOverFirstSlideNavigationDot"/>
1503+
<waitForPageLoad stepKey="waitForPageLoad4"/>
15151504
<see userInput="{{PageBuilderSlideItemSlideName_Slide1.value}}" selector="{{SliderOnStage.slideNavigationDotNameTooltip('1')}}" stepKey="seeSlideName1InTooltip"/>
15161505
</test>
15171506
<test name="SliderCanBeNavigatedQuickly">

0 commit comments

Comments
 (0)