|
1098 | 1098 | </actionGroup>
|
1099 | 1099 | <dontSeeElementInDOM selector="{{ProductsOnStorefront.product('1')}}" stepKey="validateProductCountStorefrontAfterChangingToFalse"/>
|
1100 | 1100 | </test>
|
| 1101 | + <test name="AdminPageBuilderProductsConfigurationValidateProductTotals"> |
| 1102 | + <annotations> |
| 1103 | + <features value="PageBuilder"/> |
| 1104 | + <stories value="Products"/> |
| 1105 | + <title value="Validate Product Totals"/> |
| 1106 | + <description value="Validate the total number of products shown for the selected conditions in the Advanced Configuration form and on Stage for Product List."/> |
| 1107 | + <severity value="CRITICAL"/> |
| 1108 | + <useCaseId value="PB-107"/> |
| 1109 | + <testCaseId value="MC-22882"/> |
| 1110 | + <group value="pagebuilder"/> |
| 1111 | + <group value="pagebuilder-products"/> |
| 1112 | + </annotations> |
| 1113 | + <before> |
| 1114 | + <createData entity="PageBuilderProductsSubCategory" stepKey="createPreReqCategory1"/> |
| 1115 | + <createData entity="PageBuilderProductsSubCategory" stepKey="createPreReqCategory2"/> |
| 1116 | + <createData entity="_defaultProduct" stepKey="createPreReqProduct1"> |
| 1117 | + <requiredEntity createDataKey="createPreReqCategory1"/> |
| 1118 | + </createData> |
| 1119 | + <createData entity="_defaultProduct" stepKey="createPreReqProduct2"> |
| 1120 | + <requiredEntity createDataKey="createPreReqCategory1"/> |
| 1121 | + </createData> |
| 1122 | + <createData entity="_defaultProduct" stepKey="createPreReqProduct3"> |
| 1123 | + <requiredEntity createDataKey="createPreReqCategory1"/> |
| 1124 | + </createData> |
| 1125 | + <createData entity="_defaultProduct" stepKey="createPreReqProduct4"> |
| 1126 | + <requiredEntity createDataKey="createPreReqCategory2"/> |
| 1127 | + </createData> |
| 1128 | + <createData entity="SimpleProductDisabled" stepKey="createPreReqProduct5"> |
| 1129 | + </createData> |
| 1130 | + <actionGroup ref="LoginAsAdmin" stepKey="loginAsAdmin"/> |
| 1131 | + <actionGroup ref="navigateToAPageWithPageBuilder" stepKey="navigateToAPageWithPageBuilder"/> |
| 1132 | + <actionGroup ref="switchToPageBuilderStage" stepKey="switchToPageBuilderStage"/> |
| 1133 | + </before> |
| 1134 | + <after> |
| 1135 | + <deleteData createDataKey="createPreReqProduct1" stepKey="deletePreReqProduct1"/> |
| 1136 | + <deleteData createDataKey="createPreReqProduct2" stepKey="deletePreReqProduct2"/> |
| 1137 | + <deleteData createDataKey="createPreReqProduct3" stepKey="deletePreReqProduct3"/> |
| 1138 | + <deleteData createDataKey="createPreReqProduct4" stepKey="deletePreReqProduct4"/> |
| 1139 | + <deleteData createDataKey="createPreReqProduct5" stepKey="deletePreReqProduct5"/> |
| 1140 | + <deleteData createDataKey="createPreReqCategory1" stepKey="deletePreReqCategory1"/> |
| 1141 | + <deleteData createDataKey="createPreReqCategory2" stepKey="deletePreReqCategory2"/> |
| 1142 | + <actionGroup ref="logout" stepKey="logout"/> |
| 1143 | + </after> |
| 1144 | + <actionGroup ref="addPageBuilderPageTitle" stepKey="enterPageTitle"> |
| 1145 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1146 | + </actionGroup> |
| 1147 | + <actionGroup ref="expandPageBuilderPanelMenuSection" stepKey="expandMenuSectionAddContent"> |
| 1148 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1149 | + </actionGroup> |
| 1150 | + <actionGroup ref="dragContentTypeToStage" stepKey="dragProductsIntoStage"> |
| 1151 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1152 | + </actionGroup> |
| 1153 | + <actionGroup ref="openPageBuilderEditPanel" stepKey="openEditAfterDrop"> |
| 1154 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1155 | + </actionGroup> |
| 1156 | + <!-- Select Products By Category --> |
| 1157 | + <actionGroup ref="chooseVisualSelectOption" stepKey="selectGridAppearanceForCategory"> |
| 1158 | + <argument name="property" value="PageBuilderProductsProductGridAppearance"/> |
| 1159 | + </actionGroup> |
| 1160 | + <actionGroup ref="chooseVisualSelectOption" stepKey="chooseSelectProductsByCategory"> |
| 1161 | + <argument name="property" value="PageBuilderProductsSelectProductsByCategory"/> |
| 1162 | + </actionGroup> |
| 1163 | + <actionGroup ref="selectCategoryFromCategoryDropDown" stepKey="selectCategory"> |
| 1164 | + <argument name="category" value="$$createPreReqCategory1.name$$"/> |
| 1165 | + </actionGroup> |
| 1166 | + <!-- Verify Total Products by Category for Grid Appearance --> |
| 1167 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForCategoryAndGrid"> |
| 1168 | + <argument name="property" value="PageBuilderTotalProductsPropertyThree"/> |
| 1169 | + </actionGroup> |
| 1170 | + <actionGroup ref="saveEditPanelSettings" stepKey="saveValidationEditPanelSettings"/> |
| 1171 | + <!-- Validate Stage --> |
| 1172 | + <actionGroup ref="validateProductCountInProducts" stepKey="validateProductsCountStageForCategoryAndGrid"> |
| 1173 | + <argument name="page" value="ProductsOnStage"/> |
| 1174 | + <argument name="count" value="3"/> |
| 1175 | + </actionGroup> |
| 1176 | + <actionGroup ref="openPageBuilderEditPanel" stepKey="openEditAfterVerifyingStageForCategoryAndGrid"> |
| 1177 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1178 | + </actionGroup> |
| 1179 | + <!-- Verify Total Products by Category for Carousel Appearance --> |
| 1180 | + <actionGroup ref="chooseVisualSelectOption" stepKey="selectCarouselAppearance"> |
| 1181 | + <argument name="property" value="PageBuilderProductsProductCarouselAppearance"/> |
| 1182 | + </actionGroup> |
| 1183 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForCategoryAndCarousel"> |
| 1184 | + <argument name="property" value="PageBuilderProductsCarouselTotalProductsPropertyThree"/> |
| 1185 | + </actionGroup> |
| 1186 | + <!-- Select Products By Sku --> |
| 1187 | + <actionGroup ref="chooseVisualSelectOption" stepKey="chooseSelectProductsBySku"> |
| 1188 | + <argument name="property" value="PageBuilderProductsSelectProductsBySKU"/> |
| 1189 | + </actionGroup> |
| 1190 | + <actionGroup ref="addSKUsToSelectProductsBySKU" stepKey="addProductsSKUsToInputField"> |
| 1191 | + <argument name="SKUs" value="$$createPreReqProduct5.sku$$,$$createPreReqProduct1.sku$$"/> |
| 1192 | + </actionGroup> |
| 1193 | + <!-- Verify Total Products by Sku for Carousel Appearance --> |
| 1194 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForSkusAndCarousel"> |
| 1195 | + <argument name="property" value="PageBuilderProductsCarouselTotalProductsPropertyTwoOneDisabled"/> |
| 1196 | + </actionGroup> |
| 1197 | + <actionGroup ref="saveEditPanelSettings" stepKey="saveEditPanelSettingsForSkuAndCarousel"/> |
| 1198 | + <!-- Validate Stage --> |
| 1199 | + <actionGroup ref="validateProductCountInProducts" stepKey="validateProductsCountStageForSkuAndCarousel"> |
| 1200 | + <argument name="page" value="ProductsCarouselOnStage"/> |
| 1201 | + <argument name="count" value="1"/> |
| 1202 | + </actionGroup> |
| 1203 | + <actionGroup ref="openPageBuilderEditPanel" stepKey="openEditAfterVerifyingStageForSkuAndCarousel"> |
| 1204 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1205 | + </actionGroup> |
| 1206 | + <!-- Verify Total Products by Sku for Grid Appearance --> |
| 1207 | + <actionGroup ref="chooseVisualSelectOption" stepKey="selectGridAppearanceForSku"> |
| 1208 | + <argument name="property" value="PageBuilderProductsProductGridAppearance"/> |
| 1209 | + </actionGroup> |
| 1210 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForSkuAndGrid"> |
| 1211 | + <argument name="property" value="PageBuilderTotalProductsPropertyTwoOneDisabled"/> |
| 1212 | + </actionGroup> |
| 1213 | + <!-- Select Products By Condition --> |
| 1214 | + <actionGroup ref="chooseVisualSelectOption" stepKey="chooseSelectProductsByCondition"> |
| 1215 | + <argument name="property" value="PageBuilderProductsSelectProductsByCondition"/> |
| 1216 | + </actionGroup> |
| 1217 | + <actionGroup ref="addConditionToProductConditions" stepKey="addCategoryCondition"> |
| 1218 | + <argument name="conditionInput" value="$$createPreReqCategory2.id$$"/> |
| 1219 | + </actionGroup> |
| 1220 | + <click selector="{{ProductsContentTypeForm.conditionsListText}}" stepKey="clickOutOfConditionField"/> |
| 1221 | + <!-- Verify Total Products by Condition for Grid Appearance --> |
| 1222 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForConditionAndGrid"> |
| 1223 | + <argument name="property" value="PageBuilderTotalProductsPropertyOne"/> |
| 1224 | + </actionGroup> |
| 1225 | + <actionGroup ref="saveEditPanelSettings" stepKey="saveValidationEditPanelSettingsForConditionAndGrid"/> |
| 1226 | + <!-- Validate Stage --> |
| 1227 | + <actionGroup ref="validateProductCountInProducts" stepKey="validateProductsCountStageForConditionAndGrid"> |
| 1228 | + <argument name="page" value="ProductsOnStage"/> |
| 1229 | + <argument name="count" value="1"/> |
| 1230 | + </actionGroup> |
| 1231 | + <actionGroup ref="openPageBuilderEditPanel" stepKey="openEditAfterVerifyingStageForConditionAndGrid"> |
| 1232 | + <argument name="contentType" value="PageBuilderProductsContentType"/> |
| 1233 | + </actionGroup> |
| 1234 | + <!-- Verify Total Products by Condition for Carousel Appearance --> |
| 1235 | + <actionGroup ref="chooseVisualSelectOption" stepKey="selectCarouselAppearanceForCondition"> |
| 1236 | + <argument name="property" value="PageBuilderProductsProductCarouselAppearance"/> |
| 1237 | + </actionGroup> |
| 1238 | + <actionGroup ref="validateProductTotals" stepKey="validateTotalProductsForConditionAndCarousel"> |
| 1239 | + <argument name="property" value="PageBuilderProductsCarouselTotalProductsPropertyOne"/> |
| 1240 | + </actionGroup> |
| 1241 | + </test> |
1101 | 1242 | </tests>
|
0 commit comments