itemengine-cypress-automation 1.0.278 → 1.0.280-RepoUpdate13thJan-133bc9f.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (98) hide show
  1. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/allOrNothingCorrectPointsEqualToAlternativePoints.js +21 -21
  2. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perDropzoneAlternativePointsGreaterThanCorrectPoints.js +9 -9
  3. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perDropzoneBasic.js +7 -6
  4. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perDropzoneCorrectPointsEqualToAlternativePoints.js +10 -9
  5. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perDropzoneCorrectPointsGreaterThanAlternativePoints.js +11 -10
  6. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/additionalSettings.js +1 -1
  7. package/cypress/e2e/ILC/EditItem/editItem.ts +133 -0
  8. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/allOrNothingGroupedScoring.js +4 -4
  9. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/allOrNothingWithAlternativePointsGreaterThanCorrectPoints.js +15 -15
  10. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/allOrNothingWithCorrectPointsEqualToAlternativePoints.js +14 -14
  11. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +14 -14
  12. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/blankResponseScoring.js +214 -0
  13. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/manuallyAndNonScored.js +4 -4
  14. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +14 -14
  15. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialDifferentWeightsBasic.js +8 -8
  16. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +14 -14
  17. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +14 -14
  18. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialEqualWeightsBasic.js +8 -8
  19. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +14 -14
  20. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +14 -14
  21. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +14 -14
  22. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/responseLevelAlternateAnswerBasicScoring.js +1 -1
  23. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/Scoring/blankResponseScoring.js +228 -0
  24. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/Scoring/manuallyAndNonScored.js +3 -3
  25. package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/Scoring/blankResponseScoring.js +242 -0
  26. package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/Scoring/blankResponseScoring.js +245 -0
  27. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/blankResponseScoring.js +237 -0
  28. package/cypress/e2e/ILC/Matching/Scoring/allOrNothingGroupedScoring.js +4 -4
  29. package/cypress/e2e/ILC/Matching/Scoring/allOrNothingWithAlternativePointsGreaterThanCorrectPoints.js +14 -14
  30. package/cypress/e2e/ILC/Matching/Scoring/allOrNothingWithCorrectPointsEqualToAlternativePoints.js +14 -14
  31. package/cypress/e2e/ILC/Matching/Scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +14 -14
  32. package/cypress/e2e/ILC/Matching/Scoring/blankResponseScoring.js +239 -0
  33. package/cypress/e2e/ILC/Matching/Scoring/manuallyAndNonScored.js +2 -2
  34. package/cypress/e2e/ILC/Matching/Scoring/partialDifferentWeightsScoringBasic.js +2 -2
  35. package/cypress/e2e/ILC/Matching/Scoring/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +7 -7
  36. package/cypress/e2e/ILC/Matching/Scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +7 -7
  37. package/cypress/e2e/ILC/Matching/Scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +7 -7
  38. package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsBasic.js +4 -4
  39. package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +14 -14
  40. package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +14 -14
  41. package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +14 -14
  42. package/cypress/e2e/ILC/Matching/questionInstructionsAndPromptSection.js +3 -2
  43. package/cypress/e2e/ILC/MatchingDropdown/Scoring/allOrNothingWithAlternativePointsGreaterThanCorrectPoints.js +7 -7
  44. package/cypress/e2e/ILC/MatchingDropdown/Scoring/allOrNothingWithCorrectPointsEqualToAlternativePoints.js +7 -7
  45. package/cypress/e2e/ILC/MatchingDropdown/Scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +7 -7
  46. package/cypress/e2e/ILC/MatchingDropdown/Scoring/blankResponseScoring.js +212 -0
  47. package/cypress/e2e/ILC/MatchingDropdown/Scoring/manuallyAndNonScored.js +2 -2
  48. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialDifferentWeightsScoringBasic.js +2 -2
  49. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +7 -7
  50. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternatePoints.js +7 -7
  51. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternatePoints.js +7 -7
  52. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialEqualWeightsBasic.js +4 -4
  53. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +7 -7
  54. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +7 -7
  55. package/cypress/e2e/ILC/MatchingDropdown/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +7 -7
  56. package/cypress/e2e/ILC/MultipleSelectionGridNew/Scoring/blankResponseScoring.js +366 -0
  57. package/cypress/e2e/ILC/SingleSelectionGridNew/Scoring/blankResponseScoring.js +306 -0
  58. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/allOrNothingAlternatePointsGreaterThanCorrectPoints.js +243 -0
  59. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +242 -0
  60. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/allOrNothingCorrectPointsGreaterThanAlternatePoints.js +289 -0
  61. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +284 -0
  62. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialDifferentWeightsCorrectPointsEqualToAlternativePoints.js +238 -0
  63. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialDifferentWeightsCorrectPointsGreaterThanAlternativePoints.js +279 -0
  64. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialDifferentWeightsScoringBasic.js +641 -0
  65. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialEqualWeightsAlternativePointsGreaterThanCorrectPoints.js +278 -0
  66. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialEqualWeightsCorrectPointsEqualToAlternativePoints.js +228 -0
  67. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialEqualWeightsCorrectPointsGreaterThanAlternativePoints.js +234 -0
  68. package/cypress/e2e/ILC/TextEntryMath/MathTemplateScoring/partialEqualWeightsScoringBasic.js +237 -0
  69. package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingBasicForAddEvaluation.js +134 -0
  70. package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingBasicForAlternateAnswer.js +138 -0
  71. package/cypress/e2e/ILC/TextEntryMath/Scoring/blankResponseScoring.js +263 -0
  72. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +5 -5
  73. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsScoringBasicForAlternateAnswer.js +166 -0
  74. package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViewsFormulaTemplate.smoke.js +3 -3
  75. package/cypress/e2e/ILC/TextEntryMath/customSettings.js +3 -3
  76. package/cypress/e2e/ILC/TextEntryMath/customSettingsSeparators.ts +193 -0
  77. package/cypress/e2e/ILC/TextEntryMath/evaluationMethodEquivalentStructures.js +5 -5
  78. package/cypress/e2e/ILC/TextEntryMath/evaluationMethodMatchExact.js +1 -1
  79. package/cypress/e2e/ILC/TextEntryMath/evaluationMethodMatchValue.js +1 -1
  80. package/cypress/e2e/ILC/TextEntryMath/evaluationMethodsWithoutSetResponse.js +4 -4
  81. package/cypress/e2e/ILC/TextEntryMath/responseEvaluationMethodsAndCustomSettings.js +8 -8
  82. package/cypress/e2e/ILC/TextEntryMathWithImage/allOrNothingScoringForAllViews.smoke.js +1 -1
  83. package/cypress/pages/components/customSettingsSeparatorsComponent.ts +17 -0
  84. package/cypress/pages/components/equationEditorFlyout.js +1 -1
  85. package/cypress/pages/components/fillInTheGapsDragAndDropCommonComponents.js +1 -1
  86. package/cypress/pages/components/fillInTheGapsDropdownCommonComponent.js +5 -1
  87. package/cypress/pages/components/gridQuestionCommonComponent.js +40 -0
  88. package/cypress/pages/components/optionsWrapperComponent.js +1 -1
  89. package/cypress/pages/createItemPage.js +38 -1
  90. package/cypress/pages/fillInTheGapsDragAndDropPage.js +45 -3
  91. package/cypress/pages/fillInTheGapsOverImageDragAndDropPage.js +35 -2
  92. package/cypress/pages/listOrderingPage.js +11 -11
  93. package/cypress/pages/matchingPage.js +31 -4
  94. package/cypress/pages/multipleSelectionPage.js +17 -2
  95. package/cypress/pages/readingRulerPage.js +5 -3
  96. package/cypress/pages/singleSelectionPage.js +3 -0
  97. package/cypress/pages/textEntryMathPage.js +19 -5
  98. package/package.json +1 -1
@@ -33,7 +33,7 @@ const selectors = {
33
33
  //Specify correct answer section
34
34
  dropzoneSpecifyCorrectAnswerSection: () => cy.get('[class="droppable-area"] [role="button"]'),
35
35
  optionContainerOptionsSpecifyCorrectAnswerSection: () => cy.get('.draggable-selected-item'),
36
- optionsContainerSpecifyCorrectAnswerSection: () => cy.get('.draggable-wrapper'),
36
+ optionsContainerSpecifyCorrectAnswerSection: () => cy.get('.draggable-wrapper'),
37
37
  addAlternateButtonSpecifyCorrectAnswer: () => cy.get('.alternate-option-btn-wrapper button'),
38
38
  selectedAlternateAnswerCountSpecifyCorrectAnswer: () => cy.get('.selected-option-wrapper'),
39
39
  alternateAnswerPopup: () => cy.get('.alternate-option-popup-wrapper'),
@@ -105,6 +105,48 @@ const steps = {
105
105
  });
106
106
  },
107
107
 
108
+ /**
109
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
110
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
111
+ */
112
+ clickAndDropOptionInDropzoneWithIndexSpecifyCorrectAnswerSection: (optionsObject) => {
113
+ Object.entries(optionsObject).forEach(([index, dropzoneIndex]) => {
114
+ fillInTheGapsDragAndDropPage.optionContainerOptionsSpecifyCorrectAnswerSection()
115
+ .eq(index)
116
+ .click();
117
+ fillInTheGapsDragAndDropPage.dropzoneSpecifyCorrectAnswerSection()
118
+ .eq(dropzoneIndex)
119
+ .click({ force: true });
120
+ });
121
+ },
122
+
123
+ /**
124
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
125
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
126
+ */
127
+ clickAndDropOptionOutsideDropzoneWithIndexPreviewTab: (dropzoneIndex) => {
128
+ fillInTheGapsDragAndDropPage.dropzonePreviewTab()
129
+ .eq(dropzoneIndex)
130
+ .click();
131
+ cy.get('.option-drag-and-drop')
132
+ .click({ force: true });
133
+ },
134
+
135
+ /**
136
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
137
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
138
+ */
139
+ clickAndDropOptionWithIndexInDropzonePreviewTab: (optionsObject) => {
140
+ Object.entries(optionsObject).forEach(([index, dropzoneIndex]) => {
141
+ fillInTheGapsDragAndDropPage.optionContainerOptionsPreviewTab()
142
+ .eq(index)
143
+ .click();
144
+ fillInTheGapsDragAndDropPage.dropzonePreviewTab()
145
+ .eq(dropzoneIndex)
146
+ .click({ force: true });
147
+ });
148
+ },
149
+
108
150
  /**
109
151
  * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
110
152
  * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
@@ -208,7 +250,7 @@ const steps = {
208
250
  fillInTheGapsDragAndDropPage.optionContainerOptionsPreviewTab()
209
251
  .find('[role="math"]')
210
252
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
211
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
253
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
212
254
  utilities.verifyElementVisibilityState(utilities.getNthElement(draggableOptionContainer.draggableOptionDragIcon(), optionIndex), 'exist');
213
255
  },
214
256
 
@@ -233,7 +275,7 @@ const steps = {
233
275
  .eq(optionIndex)
234
276
  .find('[role="math"]')
235
277
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
236
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
278
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
237
279
  },
238
280
 
239
281
  /**
@@ -95,6 +95,7 @@ const selectors = {
95
95
  dropzoneNumerationBox: () => cy.get('.answer-numeration-number-box'),
96
96
  correctAnswerResponseWrapperWithoutEnumeration: () => cy.get('.dnd-correct-answer-wrapper [class*="ResponseDropZonestyles__ResponseWrapper"]'),
97
97
  responseAreaPreviewTab: () => cy.get('[class*="ResponseDropZonestyles__ResponseWrapper"] .cell'),
98
+ droppedOptionPreviewTab: () => cy.get('.response-dropped')
98
99
  }
99
100
 
100
101
  const steps = {
@@ -186,6 +187,34 @@ const steps = {
186
187
  });
187
188
  },
188
189
 
190
+ /**
191
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
192
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
193
+ */
194
+ clickAndDropOptionWithIndexInDropzonePreviewTab: (optionsObject) => {
195
+ Object.entries(optionsObject).forEach(([index, dropzoneIndex]) => {
196
+ fillInTheGapsOverImageDragAndDropPage.optionContainerOptionsPreviewTab()
197
+ .eq(index)
198
+ .click();
199
+ fillInTheGapsOverImageDragAndDropPage.dropzonePreviewTab()
200
+ .eq(dropzoneIndex)
201
+ .click({ force: true });
202
+ });
203
+ },
204
+
205
+ /**
206
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
207
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
208
+ */
209
+ clickAndDropOptionOutsideDropzoneWithIndexPreviewTab: (droppedIndex) => {
210
+ fillInTheGapsOverImageDragAndDropPage.droppedOptionPreviewTab()
211
+ .eq(droppedIndex)
212
+ .click();
213
+ cy.get('.option-drag-and-drop')
214
+ .click();
215
+ },
216
+
217
+
189
218
  /**
190
219
  * Verifies the correct answer responses without enumeration.
191
220
  * @param {string[]} correctAnswerArray - An array of correct answer responses to verify.
@@ -336,7 +365,7 @@ const steps = {
336
365
  fillInTheGapsOverImageDragAndDropPage.optionContainerOptionsPreviewTab()
337
366
  .find('[role="math"]')
338
367
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
339
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
368
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
340
369
  utilities.verifyElementVisibilityState(utilities.getNthElement(draggableOptionContainer.draggableOptionDragIcon(), optionIndex), 'exist');
341
370
  },
342
371
 
@@ -361,7 +390,7 @@ const steps = {
361
390
  .eq(optionIndex)
362
391
  .find('[role="math"]')
363
392
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
364
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
393
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
365
394
  },
366
395
 
367
396
  /**
@@ -403,6 +432,10 @@ const steps = {
403
432
  });
404
433
  },
405
434
 
435
+ verifyVisibilityOfCorrectAnswerLabel: ()=>{
436
+ utilities.verifyInnerText(fillInTheGapsOverImageDragAndDropPage.correctAnswersLabel(), 'Correct answers');
437
+ },
438
+
406
439
  /**
407
440
  * @description Verifies the absence of a correct/incorrect option icon for a specified option in the Preview Tab.
408
441
  * @param {number} optionIndex - The index of the option to verify.
@@ -407,7 +407,7 @@ const steps = {
407
407
  .eq(optionIndex)
408
408
  .find('[role="math"]')
409
409
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
410
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
410
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
411
411
  },
412
412
 
413
413
  /**
@@ -502,7 +502,7 @@ const steps = {
502
502
  .eq(optionIndex)
503
503
  .find('[role="math"]')
504
504
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
505
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
505
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
506
506
  },
507
507
 
508
508
  /**
@@ -688,7 +688,7 @@ const steps = {
688
688
  utilities.getNthElement(listOrderingPage.optionSpecifyCorrectAnswerSection(), index)
689
689
  .find('[role="math"]')
690
690
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
691
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
691
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
692
692
  },
693
693
 
694
694
  /**
@@ -873,7 +873,7 @@ const steps = {
873
873
  .eq(optionIndex)
874
874
  .find('[role="math"]')
875
875
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
876
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
876
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
877
877
  },
878
878
 
879
879
  /**
@@ -1230,7 +1230,7 @@ const steps = {
1230
1230
  .eq(optionIndex)
1231
1231
  .find('[role="math"]')
1232
1232
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1233
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1233
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1234
1234
  },
1235
1235
 
1236
1236
  /**
@@ -1274,7 +1274,7 @@ const steps = {
1274
1274
  .eq(optionIndex)
1275
1275
  .find('[role="math"]')
1276
1276
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1277
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1277
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1278
1278
  },
1279
1279
 
1280
1280
  /**
@@ -1549,7 +1549,7 @@ const steps = {
1549
1549
  .eq(optionIndex)
1550
1550
  .find('[role="math"]')
1551
1551
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1552
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1552
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1553
1553
  },
1554
1554
 
1555
1555
  /**
@@ -1561,7 +1561,7 @@ const steps = {
1561
1561
  .eq(optionIndex)
1562
1562
  .find('[role="math"]')
1563
1563
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1564
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1564
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1565
1565
  },
1566
1566
 
1567
1567
  /**
@@ -1573,7 +1573,7 @@ const steps = {
1573
1573
  .eq(optionIndex)
1574
1574
  .find('[role="math"]')
1575
1575
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1576
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1576
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1577
1577
  },
1578
1578
 
1579
1579
  /**
@@ -1585,7 +1585,7 @@ const steps = {
1585
1585
  .eq(optionIndex)
1586
1586
  .find('[role="math"]')
1587
1587
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
1588
- // .contains(constants.CKEditorInputFieldEnteredEquationText);
1588
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
1589
1589
  },
1590
1590
 
1591
1591
  /**
@@ -1719,7 +1719,7 @@ const steps = {
1719
1719
  verifyCorrectIncorrectIconsNotExistListOrderingReorderAsSeparate: () => {
1720
1720
  utilities.verifyElementVisibilityState(listOrderingPage.correctIconNew(), 'notExist');
1721
1721
  utilities.verifyElementVisibilityState(listOrderingPage.incorrectIconNew(), 'notExist');
1722
- }
1722
+ },
1723
1723
  }
1724
1724
 
1725
1725
  const tests = {
@@ -100,8 +100,7 @@ const selectors = {
100
100
  dropdownNumeration: () => cy.get('[class*="ResponseDropdownComponentstyles__NumerationDiv"]'),
101
101
  correctAnswersNumeration: () => cy.get('.answer-numeration-number-box'),
102
102
  correctAnswerResponseWrapper: () => cy.get('[class*="ClozeWithDragAndDropstyles__AnswerCell"]'),
103
- correctAnswersOptions: () => cy.get('.match-list-drag-and-drop .question-text-wrapper'),
104
- correctAnswersWrapper: () => cy.get('.match-list-drag-and-drop'),
103
+ correctAnswersOptions: () => cy.get('.match-list-drag-and-drop'),
105
104
  correctAnswersOptionContainer: () => cy.get('.draggable-selected-option'),
106
105
  gradingViewOption: () => cy.get('.item-content-wrapper'),
107
106
  questionBorderPreviewTab: () => cy.get('[class*="ClozeWithDragAndDropstyles__WrapperDiv"]'),
@@ -674,6 +673,18 @@ const steps = {
674
673
  });
675
674
  },
676
675
 
676
+ /**
677
+ * Sets options in dropzone in the Preview Tab based on the provided optionsObject.
678
+ * @param {Object} optionsObject - An object where keys are option texts and values are dropzone indices.
679
+ */
680
+ clickAndDropOptionOutsideDropzoneWithIndexPreviewTab: (dropzoneIndex) => {
681
+ matchingPage.dropzonePreviewTab()
682
+ .eq(dropzoneIndex)
683
+ .click();
684
+ cy.get('.option-drag-and-drop')
685
+ .click({ force: true });
686
+ },
687
+
677
688
  clickAndDropOptionInOptionsContainerInPreviewTab: (optionText) => {
678
689
  matchingPage.dropzonePreviewTab()
679
690
  .contains(optionText)
@@ -869,6 +880,18 @@ const steps = {
869
880
  });
870
881
  },
871
882
 
883
+ /**
884
+ * Verifies the correct option icon for a specified dropzone in the Preview Tab for blank answer response.
885
+ * @param {number} dropzoneIndex - The index of the dropzone to verify.
886
+ */
887
+ verifyCorrectOptionIconForEmptyOption: (dropzoneIndex) => {
888
+ matchingPage.dropzonePreviewTab()
889
+ .eq(dropzoneIndex)
890
+ .within(() => {
891
+ utilities.verifyElementVisibilityState(autoScoredScoringPreviewTab.correctIcon(), 'exist');
892
+ });
893
+ },
894
+
872
895
  /**
873
896
  * @description Verifies the incorrect option icon for a specified dropzone in the Preview Tab.
874
897
  * @param {number} dropzoneIndex - The index of the dropzone to verify.
@@ -942,7 +965,7 @@ const steps = {
942
965
  correctAnswerArray.forEach((correctAnswerGroup, index) => {
943
966
  utilities.verifyTextContent(utilities.getNthElement(matchingPage.correctAnswersNumeration(), index), index + 1);
944
967
  correctAnswerGroup.forEach((answerOption, optionIndex) => {
945
- utilities.verifyTextContent(utilities.getNthElement(matchingPage.correctAnswersWrapper(), index).find('.question-text-wrapper').eq(optionIndex), answerOption);
968
+ utilities.verifyTextContent(utilities.getNthElement(matchingPage.correctAnswersOptions(), index).find('.question-text-wrapper').eq(optionIndex), answerOption);
946
969
  });
947
970
  });
948
971
  },
@@ -962,6 +985,10 @@ const steps = {
962
985
  }
963
986
  },
964
987
 
988
+ verifyCorrectAnswerSectionLabel: () => {
989
+ utilities.verifyInnerText(matchingPage.correctAnswersLabel(), 'Correct answers');
990
+ },
991
+
965
992
  verifyCorrectAnswerSectionNotExists: () => {
966
993
  utilities.verifyElementVisibilityState(matchingPage.correctAnswersOptions(), 'notExist');
967
994
  },
@@ -3035,7 +3062,7 @@ const tests = {
3035
3062
  } else {
3036
3063
  autoScoredSpecifyCorrectAnswerSection.alternativeAnswerAccordion()
3037
3064
  .within(() => {
3038
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
3065
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
3039
3066
  });
3040
3067
  };
3041
3068
  });
@@ -6,6 +6,8 @@ import { ckEditorEquationEditorComponent } from "../pages/components/ckEditorEqu
6
6
  import { ckEditorInsertTableComponent } from "../pages/components/ckEditorInsertTableComponent"
7
7
  import { ckEditorInsertImageComponent } from "./components/ckEditorInsertImageComponent";
8
8
  import { ckEditorLinkComponent } from "../pages/components/ckEditorLinkComponent"
9
+ import { createItemPage } from "./createItemPage";
10
+ import { selectQuestionResourceToolPage } from "./selectQuestionResourceToolPage";
9
11
  const css = Cypress.env('css');
10
12
  const options = ['Pollution caused by treating chemical waste', 'Pollution caused by cement production', 'Pollution caused by methane production', 'Pollution caused by cement and methane production'];
11
13
 
@@ -30,6 +32,7 @@ const selectors = {
30
32
  ...ckEditorInsertTableComponent,
31
33
  ...ckEditorInsertImageComponent,
32
34
  ...ckEditorLinkComponent,
35
+ ...createItemPage,
33
36
  //Specify correct answer section
34
37
  optionWrapperSpecifyCorrectAnswerSection: () => cy.get('.mcq-option-wrapper'),
35
38
  optionsText: () => cy.get('.mcq-label'),
@@ -98,6 +101,8 @@ const steps = {
98
101
  ...ckEditorInsertTableComponent.steps,
99
102
  ...ckEditorInsertImageComponent.steps,
100
103
  ...ckEditorLinkComponent.steps,
104
+ ...createItemPage.steps,
105
+ ...selectQuestionResourceToolPage.steps,
101
106
  /**
102
107
  * Verifies the contents of an option wrapper in the 'Specify correct answer' section for multiple selection questions.
103
108
  * @param {number} optionIndex - The index of the option wrapper to be verified.
@@ -368,7 +373,7 @@ const steps = {
368
373
  .eq(index)
369
374
  .find('[role="math"]')
370
375
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
371
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
376
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
372
377
  },
373
378
 
374
379
  /**
@@ -415,7 +420,7 @@ const steps = {
415
420
  .eq(index)
416
421
  .find('[role="math"]')
417
422
  .should('have.attr', 'aria-label', constants.CKEditorInputFieldEnteredEquationAriaLabel)
418
- // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
423
+ // .contains(constants.CKEditorInputFieldEnteredEquationText); ;
419
424
  },
420
425
 
421
426
  checkOptionsWrapperInSpecifyCorrectAnswerSection: (optionIndex) => {
@@ -840,6 +845,16 @@ const steps = {
840
845
  verifyCorrectAnswerSectionNotExist: () => {
841
846
  multipleSelectionPage.correctAnswerSectionWrapper()
842
847
  .should('not.exist');
848
+ },
849
+
850
+ /**
851
+ * Verifies the input field text value of an option in the feedback scale options accordion.
852
+ * @param {number} optionAccordionIndex - The index of the option accordion.
853
+ * @param {string} text - The expected text value of the input field.
854
+ * @returns {void}
855
+ */
856
+ verifyOptionInputFieldText: (optionAccordionIndex, text) => {
857
+ utilities.verifyInnerText(utilities.getNthElement(multipleSelectionPage.optionsText(), optionAccordionIndex), text)
843
858
  }
844
859
  }
845
860
 
@@ -1,5 +1,6 @@
1
1
  import utilities from "../support/helpers/utilities";
2
2
  import { createQuestionBasePage, additionalSettingsPanel, colorPopupComponent } from "./components";
3
+ import { createItemPage } from "./createItemPage";
3
4
  import { dialogBoxBase } from "./dialogBoxBase";
4
5
  import { selectQuestionResourceToolPage } from "./selectQuestionResourceToolPage";
5
6
  const css = Cypress.env('css');
@@ -55,6 +56,7 @@ const steps = {
55
56
  ...additionalSettingsPanel.steps,
56
57
  ...dialogBoxBase.steps,
57
58
  ...selectQuestionResourceToolPage.steps,
59
+ ...createItemPage.steps,
58
60
 
59
61
  verifyDisplayButtonToStudentCheckboxIsChecked: () => {
60
62
  readingRulerPage.displayButtonToStudentCheckbox()
@@ -292,9 +294,9 @@ const steps = {
292
294
  },
293
295
 
294
296
  /**
295
- * Verifies the resize buttons in the preview tab based on the specified ruler style.
296
- * @param {'Line focus'| 'Overlay mask'| 'Drag handle'} style - The style of the ruler
297
- */
297
+ * Verifies the resize buttons in the preview tab based on the specified ruler style.
298
+ * @param {'Line focus'| 'Overlay mask'| 'Drag handle'} style - The style of the ruler
299
+ */
298
300
  verifyRulerButtonsInPreviewTab: (style) => {
299
301
  switch (style) {
300
302
  case 'Line focus':
@@ -1,6 +1,7 @@
1
1
  import constants from "../fixtures/constants";
2
2
  import utilities from "../support/helpers/utilities";
3
3
  import { additionalSettingsPanel, createQuestionBasePage, mcqAdditionalSettingsBase, scoringSectionBaseEditTab, autoScoredSpecifyCorrectAnswerSection, optionsWrapperComponent, commonComponents, autoScoredScoringPreviewTab, autoScoredStudentViewSettings, ckEditorToolbar, equationEditorFlyout, randomizeOptionsComponent, lockUnlockOptionComponent, questionInstructionsComponent, additionalSettingsAccessibilitySectionComponent } from "./components";
4
+ import { createItemPage } from "./createItemPage";
4
5
  const css = Cypress.env('css');
5
6
 
6
7
  const options = ['Pollution caused by treating chemical waste', 'Pollution caused by cement production', 'Pollution caused by methane production', 'Pollution caused by cement and methane production'];
@@ -18,6 +19,7 @@ const selectors = {
18
19
  ...autoScoredScoringPreviewTab,
19
20
  ...randomizeOptionsComponent,
20
21
  ...lockUnlockOptionComponent,
22
+ ...createItemPage,
21
23
  optionsRadioButton: () => cy.get('input[type="radio"]'),
22
24
  optionsRadioButtonForSpecifyCorrectAnswer: () => cy.get('.radio-option-wrapper:visible input[type="radio"]'),
23
25
  editTabOptionsWrapper: () => cy.get('.edit-mcq-option-wrapper'),
@@ -54,6 +56,7 @@ const steps = {
54
56
  ...equationEditorFlyout.steps,
55
57
  ...randomizeOptionsComponent.steps,
56
58
  ...lockUnlockOptionComponent.steps,
59
+ ...createItemPage.steps,
57
60
  /**
58
61
  * Verifies the contents of an option wrapper in the 'Specify correct answer' section for single selection questions.
59
62
  * @param {number} optionIndex - The index of the option wrapper to be verified.
@@ -44,6 +44,7 @@ const selectors = {
44
44
  //Evaluation tab
45
45
  evaluationTab: () => cy.get('[data-ngie-testid*="evaluation"][data-ngie-testid*="tab"]'),
46
46
  evaluationTabCloseButton: () => cy.get('.styled-close-button[aria-label*="Evaluation"]'),
47
+ evaluationCard: () => cy.get('.evaluation-styled-card'),
47
48
  evaluationContainer: (evaluationMethodTitle = null) => {
48
49
  if (evaluationMethodTitle) {
49
50
  return cy.get(`.evaluation-styled-card`).contains(evaluationMethodTitle)
@@ -360,15 +361,23 @@ const steps = {
360
361
  /**
361
362
  * Select evaluation method
362
363
  * @param {string} evaluationMethodTitle Title of evaluation method
364
+ * @param {number} index index of evolution method
363
365
  */
364
366
  selectEvaluationMethod: (evaluationMethodTitle) => {
365
- textEntryMathPage.evaluationContainer(evaluationMethodTitle)
366
- .click();
367
+ if (index !== null) {
368
+ utilities.getNthElement(textEntryMathPage.evaluationCard(), index)
369
+ .contains(evaluationMethodTitle)
370
+ .click();
371
+ } else {
372
+ textEntryMathPage.evaluationCard()
373
+ .contains(evaluationMethodTitle)
374
+ .click();
375
+ }
367
376
  textEntryMathPage.steps.verifyEvaluationMethodActiveState(evaluationMethodTitle);
368
377
  },
369
378
 
370
379
  clickOnAddEvaluationButton: () => {
371
- textEntryMathPage.addEvaluationButton()
380
+ utilities.getNthElement(textEntryMathPage.addEvaluationButton(), index)
372
381
  .click();
373
382
  },
374
383
 
@@ -967,8 +976,9 @@ const steps = {
967
976
  .should('have.attr', 'aria-expanded', 'false');
968
977
  },
969
978
 
970
- focusInLayoutInputField: () => {
979
+ focusInLayoutInputField: (index = 0) => {
971
980
  textEntryMathPage.inputFieldLayoutAccordion()
981
+ .eq(index)
972
982
  .click();
973
983
  },
974
984
 
@@ -1330,6 +1340,10 @@ const steps = {
1330
1340
  utilities.verifyCSS(utilities.getNthElement(textEntryMathPage.answerInputFieldPreviewTab(), responseAreaIndex), {
1331
1341
  'border-style': styleName
1332
1342
  });
1343
+ },
1344
+
1345
+ verifyCorrectIncorrectStatusMessageTextNotExist: () => {
1346
+ utilities.verifyElementVisibilityState(textEntryMathPage.correctIncorrectStatusMessageText(), 'notExist');
1333
1347
  }
1334
1348
  }
1335
1349
 
@@ -1448,7 +1462,7 @@ const tests = {
1448
1462
  });
1449
1463
 
1450
1464
  it('User should be able to select a different evaluation method', () => {
1451
- textEntryMathPage.steps.selectEvaluationMethod(evaluationMethods[3].name);
1465
+ textEntryMathPage.steps.selectEvaluationMethod(evaluationMethods[3].name, 3);
1452
1466
  });
1453
1467
  },
1454
1468
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.278",
3
+ "version": "1.0.280-RepoUpdate13thJan-133bc9f.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {