|
16 | 16 | <description value="Admin should be able to add image to WYSIWYG Editor on Product Page"/>
|
17 | 17 | <severity value="CRITICAL"/>
|
18 | 18 | <testCaseId value="MAGETWO-84375"/>
|
19 |
| - <skip> |
20 |
| - <issueId value="MAGETWO-94438"/> |
21 |
| - </skip> |
22 | 19 | </annotations>
|
23 | 20 | <before>
|
24 | 21 | <actionGroup ref="LoginActionGroup" stepKey="login"/>
|
25 | 22 | <actionGroup ref="EnabledWYSIWYG" stepKey="enableWYSIWYG"/>
|
26 | 23 | <actionGroup ref="SwitchToVersion4ActionGroup" stepKey="switchToTinyMCE4" />
|
27 | 24 | </before>
|
| 25 | + <after> |
| 26 | + <actionGroup ref="DisabledWYSIWYG" stepKey="disableWYSIWYG"/> |
| 27 | + <actionGroup ref="logout" stepKey="logout"/> |
| 28 | + </after> |
| 29 | + |
28 | 30 | <amOnPage url="{{AdminProductCreatePage.url(AddToDefaultSet.attributeSetId, 'simple')}}" stepKey="navigateToNewProduct"/>
|
29 |
| - <waitForPageLoad stepKey="waitForPageLoad"/> |
30 |
| - <fillField userInput="{{_defaultProduct.name}}" selector="{{AdminProductFormSection.productName}}" stepKey="fillName"/> |
31 |
| - <fillField userInput="{{_defaultProduct.price}}" selector="{{AdminProductFormSection.productPrice}}" stepKey="fillPrice"/> |
32 |
| - <fillField userInput="{{_defaultProduct.sku}}" selector="{{AdminProductFormSection.productSku}}" stepKey="fillSKU"/> |
33 |
| - <fillField userInput="{{_defaultProduct.quantity}}" selector="{{AdminProductFormSection.productQuantity}}" stepKey="fillQuantity"/> |
34 |
| - <scrollTo selector="{{AdminProductFormSection.productQuantity}}" stepKey="scrollToQty" /> |
| 31 | + <waitForPageLoad stepKey="waitForPageLoadProductCreatePage"/> |
| 32 | + <actionGroup ref="fillMainProductForm" stepKey="fillBasicProductInfo" /> |
| 33 | + |
35 | 34 | <click selector="{{AdminProductFormSection.contentTab}}" stepKey="clickContentTab" />
|
36 | 35 | <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.TinyMCE4}}" stepKey="waitForDescription" />
|
37 | 36 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.InsertImageIcon}}" stepKey="clickInsertImageIcon1" />
|
38 |
| - <waitForPageLoad stepKey="waitForPageLoad1" /> |
39 | 37 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.Browse}}" stepKey="clickBrowse1" />
|
40 |
| - <waitForPageLoad stepKey="waitForPageLoad2" /> |
41 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading1" /> |
42 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading2" /> |
| 38 | + <waitForLoadingMaskToDisappear stepKey="waitForBrowseModal" /> |
43 | 39 | <see selector="{{ProductDescriptionWYSIWYGToolbarSection.CancelBtn}}" userInput="Cancel" stepKey="seeCancelBtn1" />
|
44 | 40 | <see selector="{{ProductDescriptionWYSIWYGToolbarSection.CreateFolder}}" userInput="Create Folder" stepKey="seeCreateFolderBtn1" />
|
45 |
| - <click selector="{{ProductDescriptionWYSIWYGToolbarSection.CreateFolder}}" stepKey="createFolder1"/> |
46 |
| - <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.FolderName}}" stepKey="waitForPopUp1" /> |
| 41 | + <dontSeeElement selector="{{ProductDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="dontSeeAddSelectedBtn1" /> |
| 42 | + <click selector="{{ProductDescriptionWYSIWYGToolbarSection.CreateFolder}}" stepKey="createFolder1" /> |
| 43 | + <waitForElement selector="{{ProductDescriptionWYSIWYGToolbarSection.FolderName}}" stepKey="waitForPopUp1" /> |
47 | 44 | <fillField selector="{{ProductDescriptionWYSIWYGToolbarSection.FolderName}}" userInput="{{ImageFolder.name}}" stepKey="fillFolderName1" />
|
48 | 45 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.AcceptFolderName}}" stepKey="acceptFolderName11" />
|
49 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading3" /> |
50 | 46 | <conditionalClick selector="{{ProductDescriptionWYSIWYGToolbarSection.StorageRootArrow}}" dependentSelector="{{ProductDescriptionWYSIWYGToolbarSection.checkIfArrowExpand}}" stepKey="clickStorageRootArrowIfClosed" visible="true"/>
|
51 | 47 | <conditionalClick selector="{{ProductDescriptionWYSIWYGToolbarSection.WysiwygArrow}}" dependentSelector="{{ProductDescriptionWYSIWYGToolbarSection.checkIfWysiwygArrowExpand}}" stepKey="clickWysiwygArrowIfClosed" visible="true"/>
|
52 | 48 | <waitForText userInput="{{ImageFolder.name}}" stepKey="waitForNewFolder1" />
|
53 | 49 | <click userInput="{{ImageFolder.name}}" stepKey="clickOnCreatedFolder1" />
|
54 | 50 | <waitForLoadingMaskToDisappear stepKey="waitForLoading4" />
|
55 | 51 | <attachFile selector="{{ProductDescriptionWYSIWYGToolbarSection.BrowseUploadImage}}" userInput="{{ImageUpload1.value}}" stepKey="uploadImage1"/>
|
56 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading5" /> |
| 52 | + <waitForLoadingMaskToDisappear stepKey="waitForFileUpload1" /> |
57 | 53 | <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.image(ImageUpload1.value)}}" stepKey="waitForUploadImage1" />
|
58 | 54 | <seeElement selector="{{ProductDescriptionWYSIWYGToolbarSection.imageSelected(ImageUpload1.value)}}" stepKey="seeImageSelected1" />
|
59 | 55 | <see selector="{{ProductDescriptionWYSIWYGToolbarSection.DeleteSelectedBtn}}" userInput="Delete Selected" stepKey="seeDeleteBtn1"/>
|
60 | 56 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.DeleteSelectedBtn}}" stepKey="clickDeleteSelected1" />
|
61 |
| - <waitForText userInput="OK" stepKey="waitForConfirm1" /> |
62 |
| - <click selector="{{ProductDescriptionWYSIWYGToolbarSection.confirmDelete}}" stepKey="confirmDelete1" /> |
| 57 | + <waitForElementVisible selector="{{AdminConfirmationModalSection.ok}}" stepKey="waitForConfirmDelete1"/> |
| 58 | + <click selector="{{AdminConfirmationModalSection.ok}}" stepKey="confirmDelete1" /> |
63 | 59 | <waitForElementNotVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.image(ImageUpload1.value)}}" stepKey="waitForImageDeleted1" />
|
64 | 60 | <dontSeeElement selector="{{ProductDescriptionWYSIWYGToolbarSection.image(ImageUpload1.value)}}" stepKey="dontSeeImage1" />
|
| 61 | + <dontSeeElement selector="{{ProductDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="dontSeeAddSelectedBtn2" /> |
65 | 62 | <attachFile selector="{{ProductDescriptionWYSIWYGToolbarSection.BrowseUploadImage}}" userInput="{{ImageUpload1.value}}" stepKey="uploadImage2"/>
|
66 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading6" /> |
| 63 | + <waitForLoadingMaskToDisappear stepKey="waitForFileUpload2" /> |
67 | 64 | <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.image(ImageUpload1.value)}}" stepKey="waitForUploadImage2" />
|
68 | 65 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="clickInsertBtn1" />
|
69 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading7" /> |
70 |
| - <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.OkBtn}}" stepKey="waitForOkBtn1" /> |
| 66 | + <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.ImageDescription}}" stepKey="waitForImageDescriptionButton1" /> |
71 | 67 | <fillField selector="{{ProductDescriptionWYSIWYGToolbarSection.ImageDescription}}" userInput="{{ImageUpload1.content}}" stepKey="fillImageDescription1" />
|
72 | 68 | <fillField selector="{{ProductDescriptionWYSIWYGToolbarSection.Height}}" userInput="{{ImageUpload1.height}}" stepKey="fillImageHeight1" />
|
73 | 69 | <click selector="{{ProductDescriptionWYSIWYGToolbarSection.OkBtn}}" stepKey="clickOkBtn1" />
|
74 |
| - <waitForPageLoad stepKey="waitForPageLoad3"/> |
75 | 70 | <scrollTo selector="{{ProductDescriptionWYSIWYGToolbarSection.TinyMCE4}}" stepKey="scrollToTinyMCE4" />
|
76 | 71 | <click selector="{{ProductShortDescriptionWYSIWYGToolbarSection.InsertImageIcon}}" stepKey="clickInsertImageIcon2" />
|
77 |
| - <waitForPageLoad stepKey="waitForPageLoad4" /> |
78 | 72 | <click selector="{{ProductShortDescriptionWYSIWYGToolbarSection.Browse}}" stepKey="clickBrowse2" />
|
79 |
| - <waitForPageLoad stepKey="waitForPageLoad5" /> |
80 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading8" /> |
| 73 | + <waitForElementVisible selector="{{ProductDescriptionWYSIWYGToolbarSection.CancelBtn}}" stepKey="waitForCancelButton2"/> |
81 | 74 | <see selector="{{ProductShortDescriptionWYSIWYGToolbarSection.CancelBtn}}" userInput="Cancel" stepKey="seeCancelBtn2" />
|
82 | 75 | <see selector="{{ProductShortDescriptionWYSIWYGToolbarSection.CreateFolder}}" userInput="Create Folder" stepKey="seeCreateFolderBtn2" />
|
83 |
| - <dontSeeElement selector="{{ProductShortDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="dontSeeAddSelectedBtn2" /> |
| 76 | + <dontSeeElement selector="{{ProductShortDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="dontSeeAddSelectedBtn3" /> |
84 | 77 | <attachFile selector="{{ProductShortDescriptionWYSIWYGToolbarSection.BrowseUploadImage}}" userInput="{{ImageUpload3.value}}" stepKey="uploadImage3"/>
|
| 78 | + <waitForLoadingMaskToDisappear stepKey="waitForFileUpload3" /> |
85 | 79 | <waitForElementVisible selector="{{ProductShortDescriptionWYSIWYGToolbarSection.image(ImageUpload3.value)}}" stepKey="waitForUploadImage3" />
|
86 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading9" /> |
87 |
| - <wait time="3" stepKey="waitMore" /> |
88 | 80 | <waitForElement selector="{{ProductShortDescriptionWYSIWYGToolbarSection.DeleteSelectedBtn}}" stepKey="waitForDeletebtn" />
|
89 | 81 | <see selector="{{ProductShortDescriptionWYSIWYGToolbarSection.DeleteSelectedBtn}}" userInput="Delete Selected" stepKey="seeDeleteBtn2"/>
|
90 | 82 | <click selector="{{ProductShortDescriptionWYSIWYGToolbarSection.DeleteSelectedBtn}}" stepKey="clickDeleteSelected2" />
|
91 |
| - <waitForText userInput="OK" stepKey="waitForConfirm3" /> |
92 |
| - <click selector="{{ProductShortDescriptionWYSIWYGToolbarSection.confirmDelete}}" stepKey="confirmDelete2" /> |
| 83 | + <waitForElementVisible selector="{{AdminConfirmationModalSection.ok}}" stepKey="waitForConfirm3"/> |
| 84 | + <click selector="{{AdminConfirmationModalSection.ok}}" stepKey="confirmDelete2" /> |
| 85 | + <dontSeeElement selector="{{ProductDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="dontSeeAddSelectedBtn4" /> |
93 | 86 | <attachFile selector="{{ProductShortDescriptionWYSIWYGToolbarSection.BrowseUploadImage}}" userInput="{{ImageUpload3.value}}" stepKey="uploadImage4"/>
|
94 |
| - <waitForLoadingMaskToDisappear stepKey="waitForLoading10" /> |
| 87 | + <waitForLoadingMaskToDisappear stepKey="waitForFileUpload4" /> |
95 | 88 | <waitForElementVisible selector="{{ProductShortDescriptionWYSIWYGToolbarSection.image(ImageUpload3.value)}}" stepKey="waitForUploadImage4" />
|
96 | 89 | <click selector="{{ProductShortDescriptionWYSIWYGToolbarSection.InsertFile}}" stepKey="clickInsertBtn" />
|
97 | 90 | <waitForLoadingMaskToDisappear stepKey="waitForLoading11" />
|
|
107 | 100 | <seeElement selector="{{StorefrontProductInfoMainSection.mediaDescription}}" stepKey="assertMediaDescription"/>
|
108 | 101 | <seeElementInDOM selector="{{StorefrontCategoryMainSection.imageSource(ImageUpload3.fileName)}}" stepKey="assertMediaSource3"/>
|
109 | 102 | <seeElementInDOM selector="{{StorefrontCategoryMainSection.imageSource(ImageUpload1.fileName)}}" stepKey="assertMediaSource1"/>
|
110 |
| - <after> |
111 |
| - <actionGroup ref="DisabledWYSIWYG" stepKey="disableWYSIWYG"/> |
112 |
| - <actionGroup ref="logout" stepKey="logout"/> |
113 |
| - </after> |
114 | 103 | </test>
|
115 | 104 | </tests>
|
0 commit comments