itemengine-cypress-automation 1.0.326-IEI-4285-3f1c280.0 → 1.0.328-UpdateRepo28thFeb-24a9148.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (82) hide show
  1. package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerHeaderSectionAndButtons.js +5 -4
  2. package/cypress/e2e/ILC/CkEditorInsertTable/updateTable.js +1 -0
  3. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/allOrNothingBasicForAllViews.smoke.js +100 -0
  4. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/studentViewSettingsForGroupedLayout.js +1 -0
  5. package/cypress/e2e/ILC/DrawingResponse/drawingResponseBackground.js +12 -0
  6. package/cypress/e2e/ILC/FillInTheGapsDropdownNew/dropdownAndDropdownMenuSection.js +1 -0
  7. package/cypress/e2e/ILC/FillInTheGapsDropdownNew/editQuestion.smoke.js +24 -0
  8. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/studentViewSettingsForGroupedLayout.js +5 -4
  9. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/styleAndLayoutCustomization.js +4 -3
  10. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/styleAndLayoutCustomizationDraggableOptionsPanel.js +1 -1
  11. package/cypress/e2e/ILC/FillInTheGapsTextNew/editTabBasicSection.js +80 -0
  12. package/cypress/e2e/ILC/ListOrderingNew/HorizontalOrientation/previewContentsForAllViews.smoke.js +1 -1
  13. package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/allOrNothingForAllViews.smoke.js +2 -1
  14. package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/previewContentsForAllViews.smoke.js +1 -1
  15. package/cypress/e2e/ILC/Matching/draggableOptions.js +29 -0
  16. package/cypress/e2e/ILC/Matching/styleAndLayoutCustomizationDropzoneConnectorStyle.js +52 -47
  17. package/cypress/e2e/ILC/Matching/styleAndLayoutCustomizationOptionAlignment.js +6 -4
  18. package/cypress/e2e/ILC/Matching/styleAndLayoutCustomizationOptionPlacement.js +60 -54
  19. package/cypress/e2e/ILC/MatchingDropdown/allOrNothingScoringForAllViews.smoke.js +1 -1
  20. package/cypress/e2e/ILC/MultipleSelection/checkAddAlternativeButton.js +34 -0
  21. package/cypress/e2e/ILC/MultipleSelection/checkScoringLabelBannerAndCorrectAnswer.js +79 -0
  22. package/cypress/e2e/ILC/MultipleSelection/editQuestion.smoke.js +1 -1
  23. package/cypress/e2e/ILC/MultipleSelection/editTabBasicSection.js +31 -0
  24. package/cypress/e2e/ILC/MultipleSelection/headerSection.js +36 -7
  25. package/cypress/e2e/ILC/MultipleSelection/previewContentsForInCompleteAuthoring.js +98 -0
  26. package/cypress/e2e/ILC/MultipleSelectionGridNew/Scoring/blankResponseScoring.js +5 -19
  27. package/cypress/e2e/ILC/MultipleSelectionGridNew/Scoring/checkScoringLabelBannerAndCorrectAnswer.js +80 -0
  28. package/cypress/e2e/ILC/MultipleSelectionGridNew/checkAddAlternativeButton.js +38 -0
  29. package/cypress/e2e/ILC/MultipleSelectionGridNew/editTabBasicSection.js +35 -1
  30. package/cypress/e2e/ILC/MultipleSelectionGridNew/headerSection.js +36 -10
  31. package/cypress/e2e/ILC/MultipleSelectionGridNew/previewContentForAllViewsInIncompleteAuthoring.smoke.js +71 -0
  32. package/cypress/e2e/ILC/ShortTextResponseNew/editTabBasicSections.js +88 -2
  33. package/cypress/e2e/ILC/SingleSelection/checkAddAlternativeButton.js +34 -0
  34. package/cypress/e2e/ILC/SingleSelection/checkScoringLabelBannerAndCorrectAnswer.js +79 -0
  35. package/cypress/e2e/ILC/SingleSelection/editQuestion.smoke.js +72 -0
  36. package/cypress/e2e/ILC/SingleSelection/editTabBasicSection.js +31 -0
  37. package/cypress/e2e/ILC/SingleSelection/headerSection.js +36 -11
  38. package/cypress/e2e/ILC/SingleSelection/previewContentsForInCompleteAuthoring.js +92 -0
  39. package/cypress/e2e/ILC/SingleSelectionGridNew/Scoring/blankResponseScoring.js +4 -18
  40. package/cypress/e2e/ILC/SingleSelectionGridNew/Scoring/checkScoringLabelBannerAndCorrectAnswerSection.js +79 -0
  41. package/cypress/e2e/ILC/SingleSelectionGridNew/checkAddAlternativeButton.js +35 -0
  42. package/cypress/e2e/ILC/SingleSelectionGridNew/editTabBasicSection.js +34 -0
  43. package/cypress/e2e/ILC/SingleSelectionGridNew/headerSection.js +37 -10
  44. package/cypress/e2e/ILC/SingleSelectionGridNew/previewContentsForAllViewsInIncompleteAuthoring.smoke.js +69 -0
  45. package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViewsFormulaTemplate.smoke.js +5 -6
  46. package/cypress/e2e/ILC/TextEntryMath/customSettings.js +1 -1
  47. package/cypress/e2e/ILC/TextEntryMath/previewContentsForAllViews.smoke.js +33 -0
  48. package/cypress/e2e/ILC/TextSelection/ScoringGeneric/basicScoringForAllTextSelectionTypes.smoke.js +7 -7
  49. package/cypress/e2e/ILC/TextSelection/previewContentsForAllViews.smoke.js +8 -8
  50. package/cypress/e2e/ILC/UploadResponse/editTabBasicSection.js +2 -3
  51. package/cypress/e2e/ILC/UploadResponse/gradingViewAndCorrectAnswerViewContents.smoke.js +0 -41
  52. package/cypress/e2e/ILC/UploadResponse/thumbNail.smoke.js +1 -17
  53. package/cypress/e2e/ILC/VideoResponseNew/compactRecorderStyle.smoke.js +3 -3
  54. package/cypress/e2e/ILC/VideoResponseNew/editTabBasicSection.js +6 -6
  55. package/cypress/pages/components/autoScoredScoringPreviewTab.js +0 -1
  56. package/cypress/pages/components/barAndLineChartComponent.js +1 -1
  57. package/cypress/pages/components/ckEditorInsertTableComponent.js +1 -1
  58. package/cypress/pages/components/ckEditorToolbar.js +1 -1
  59. package/cypress/pages/components/equationEditorSectionCommonComponent.js +2 -2
  60. package/cypress/pages/components/fillInTheGapsDropdownCommonComponent.js +11 -0
  61. package/cypress/pages/components/fillInTheGapsTextCommonComponent.js +11 -0
  62. package/cypress/pages/components/gridQuestionCommonComponent.js +3 -4
  63. package/cypress/pages/components/imageCanvasComponent.js +2 -0
  64. package/cypress/pages/components/layoutSectionComponent.js +1 -1
  65. package/cypress/pages/components/maximumCapacityPerDropzoneComponent.js +1 -1
  66. package/cypress/pages/components/numberLineCommonComponent.js +3 -3
  67. package/cypress/pages/createItemPage.js +0 -7
  68. package/cypress/pages/dragAndDropIntoCategoriesPage.js +32 -0
  69. package/cypress/pages/drawingResponsePage.js +13 -3
  70. package/cypress/pages/fillInTheGapsOverImageDragAndDropPage.js +6 -5
  71. package/cypress/pages/fillInTheGapsOverImageTextPage.js +14 -4
  72. package/cypress/pages/graphingPage.js +12 -12
  73. package/cypress/pages/matchingPage.js +3 -3
  74. package/cypress/pages/multipleSelectionGridPage.js +4 -5
  75. package/cypress/pages/multipleSelectionPage.js +4 -6
  76. package/cypress/pages/shortTextResponsePage.js +20 -2
  77. package/cypress/pages/singleSelectionPage.js +2 -3
  78. package/cypress/pages/textEntryMathPage.js +13 -2
  79. package/cypress/pages/textEntryMathWithImagePage.js +2 -2
  80. package/cypress/pages/uploadResponsePage.js +2 -2
  81. package/package.json +1 -1
  82. package/cypress/e2e/ILC/ThinkSphere/dummyTest.js +0 -17
@@ -328,6 +328,38 @@ const steps = {
328
328
  };
329
329
  },
330
330
 
331
+ /**
332
+ * @param {number} cellIndex - Index of the table cell.
333
+ * @param {("Heading" | "Subheading" | "Text" | "Dropzone" | "None")} cellProperty - Type of property to verify.
334
+ * @description Verifies the appearance and content of a specific property in a table cell on the preview tab.
335
+ */
336
+ verifyTableCellPropertyStudentView: (cellIndex, cellProperty) => {
337
+ switch (cellProperty) {
338
+ case 'Heading':
339
+ utilities.getNthElement(dragAndDropIntoCategoriesPage.cellContainerPreviewTab(), cellIndex)
340
+ .should('have.class', 'header-cell');
341
+ break;
342
+ case 'Subheading':
343
+ utilities.getNthElement(dragAndDropIntoCategoriesPage.cellContainerPreviewTab(), cellIndex)
344
+ .should('have.class', 'sub-header-cell');
345
+ break;
346
+ case 'Text':
347
+ utilities.getNthElement(dragAndDropIntoCategoriesPage.cellContainerPreviewTab(), cellIndex)
348
+ .should('have.class', 'text-cell');
349
+ break;
350
+ case 'Dropzone':
351
+ utilities.getNthElement(dragAndDropIntoCategoriesPage.cellContainerPreviewTab(), cellIndex)
352
+ .should('have.class', 'dropzone-cell');
353
+ break;
354
+ case 'None':
355
+ utilities.getNthElement(dragAndDropIntoCategoriesPage.cellContainerPreviewTab(), cellIndex)
356
+ .should('have.class', 'none-cell');
357
+ break;
358
+ default:
359
+ throw new Error('Invalid list option');
360
+ };
361
+ },
362
+
331
363
  /**
332
364
  * @param {number} cellIndex - Index of the table cell.
333
365
  * @param {("Heading" | "Subheading" | "Text" | "Dropzone" | "None")} cellProperty - Type of property to verify.
@@ -1,5 +1,5 @@
1
1
  import utilities from "../support/helpers/utilities"
2
- import { questionInstructionsComponent, createQuestionBasePage, commonComponents, additionalSettingsPanel, scoringSectionBaseEditTab, customizeSpecialCharacterComponent, customizeMathCharacterComponent } from "./components"
2
+ import { questionInstructionsComponent, createQuestionBasePage, commonComponents, additionalSettingsPanel, scoringSectionBaseEditTab, customizeSpecialCharacterComponent, customizeMathCharacterComponent, backgroundImageUploadComponent } from "./components"
3
3
  import { createItemPage } from "./createItemPage";
4
4
  import { dialogBoxBase } from "./dialogBoxBase";
5
5
 
@@ -15,6 +15,7 @@ const selectors = {
15
15
  ...createQuestionBasePage,
16
16
  ...customizeSpecialCharacterComponent,
17
17
  ...customizeMathCharacterComponent,
18
+ ...backgroundImageUploadComponent,
18
19
  //Customize toolbar options and controls
19
20
  customizeToolbarOptionsAndControlsAccordion: () => cy.get('.drawing-response-accordion .ngie-accordion-summary'),
20
21
  customizeToolbarOptionsAndControlsLabel: () => cy.get('.customized-options-label'),
@@ -116,9 +117,9 @@ const selectors = {
116
117
  imageRadioButton: () => cy.get('input[aria-label="Image"]'),
117
118
  patternLabel: () => cy.get('label[aria-label="Pattern"]'),
118
119
  patternRadioButton: () => cy.get('input[aria-label="Pattern"]'),
119
- canvasWidthLabel: () => cy.get('label[aria-labelledby="Canvas width (px)"]'),
120
+ canvasWidthLabel: () => cy.get('label[for="Canvas width (px)"]'),
120
121
  canvasWidthInputField: () => cy.get('input[aria-label="Canvas width (px)"]'),
121
- canvasHeightLabel: () => cy.get('label[aria-labelledby="Canvas height (px)"]'),
122
+ canvasHeightLabel: () => cy.get('label[for="Canvas height (px)"]'),
122
123
  canvasHeightInputField: () => cy.get('input[aria-label="Canvas height (px)"]'),
123
124
  aspectRatioButton: () => cy.get('.lock-reset-icon-wrapper button').eq(0),
124
125
  resetDimensionsButton: () => cy.get('.lock-reset-icon-wrapper button').eq(1),
@@ -231,6 +232,7 @@ const steps = {
231
232
  ...customizeSpecialCharacterComponent.steps,
232
233
  ...customizeMathCharacterComponent.steps,
233
234
  ...createItemPage.steps,
235
+ ...backgroundImageUploadComponent.steps,
234
236
  /**
235
237
  * @param {string[]} arrayOfToolbarOptions array of toolbar options to be selected
236
238
  * @description this function selects toolbar options from edit tab
@@ -642,6 +644,14 @@ const steps = {
642
644
  .attachFile(file);
643
645
  },
644
646
 
647
+ /**
648
+ * @description this function deletes an uploaded file
649
+ */
650
+ deleteUploadedFile: () => {
651
+ backgroundImageUploadComponent.steps.deleteImage();
652
+ backgroundImageUploadComponent.steps.clickOnDeleteButtonInDeleteImagePopup();
653
+ },
654
+
645
655
  verifyImageContainerErrorMessage: (fileName) => {
646
656
  drawingResponsePage.insertImageContainerErrorMessage()
647
657
  .should('have.text', `The following files were rejected${fileName} is too large. The maximum file size is 5MB`)
@@ -76,9 +76,9 @@ const selectors = {
76
76
  optionAlignmentInDropzoneOptions: (alignmentOption) => cy.get(`.option-alignment button[aria-label*="option alignment in dropzone ${alignmentOption}"]`),
77
77
  setHeightAndWidthForAllDropzoneCheckboxLabel: () => cy.get('[data-ngie-testid="set-height-and-width-for-all-dropzones-checkbox"] .MuiFormControlLabel-label'),
78
78
  setHeightAndWidthForAllDropzoneCheckbox: () => cy.get('[data-ngie-testid="set-height-and-width-for-all-dropzones-checkbox"] input'),
79
- dropzoneHeightInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [aria-labelledby="Height (px)"]'),
79
+ dropzoneHeightInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [for="Height (px)"]'),
80
80
  dropzoneHeightInputField: () => cy.get('.dropzone-text-container-dimension [id="Height (px)"]'),
81
- dropzoneWidthInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [aria-labelledby="Width (px)"]'),
81
+ dropzoneWidthInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [for="Width (px)"]'),
82
82
  dropzoneWidthInputField: () => cy.get('.dropzone-text-container-dimension [id="Width (px)"]'),
83
83
  draggableOptionPanelPlacementLabel: () => cy.get('.draggable-option-panel-label'),
84
84
  panelPlacementLabel: () => cy.get('.panel-placement-style .options-label'),
@@ -711,7 +711,7 @@ const steps = {
711
711
 
712
712
  verifyNoImageAlternativeTextPresentInPreviewTab: () => {
713
713
  imageCanvasComponent.canvasImageInPreviewTab()
714
- .should('have.attr', 'alt', 'highlightImage.jpg');
714
+ .should('have.attr', 'alt', 'highlightImage');
715
715
  },
716
716
 
717
717
  /**
@@ -765,10 +765,11 @@ const steps = {
765
765
 
766
766
  checkBlockRadioButton: () => {
767
767
  fillInTheGapsOverImageDragAndDropPage.blockRadioButton()
768
- .click()
768
+ .click();
769
769
  cy.wait(500);
770
770
  fillInTheGapsOverImageDragAndDropPage.blockRadioButton()
771
- .should('be.checked');
771
+ .parents('[data-value="block"]')
772
+ .should('have.class', 'radio-option-checked');
772
773
  },
773
774
 
774
775
  verifyInlineOptionPlacementSpecifyCorrectAnswer: () => {
@@ -36,9 +36,9 @@ const selectors = {
36
36
  correctAnswerSectionWithoutEnumerationWrapper: () => cy.get('.label-image-with-text-correct-answer-wrapper'),
37
37
  setHeightAndWidthForAllTextContainersCheckboxLabel: () => cy.get('[data-ngie-testid="set-height-and-width-for-all-text-containers-checkbox"] .MuiFormControlLabel-label'),
38
38
  setHeightAndWidthForAllTextContainersCheckbox: () => cy.get('[data-ngie-testid="set-height-and-width-for-all-text-containers-checkbox"] input'),
39
- textContainerHeightInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [aria-labelledby="Height (px)"]'),
39
+ textContainerHeightInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [for="Height (px)"]'),
40
40
  textContainerHeightInputField: () => cy.get('.dropzone-text-container-dimension [id="Height (px)"]'),
41
- textContainerWidthInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [aria-labelledby="Width (px)"]'),
41
+ textContainerWidthInputFieldLabel: () => cy.get('.dropzone-text-container-dimension [for="Width (px)"]'),
42
42
  textContainerWidthInputField: () => cy.get('.dropzone-text-container-dimension [id="Width (px)"]'),
43
43
  textContainerConnectorStyleLabel: () => cy.get('.dropzone-connector-style-label'),
44
44
  responseArea: () => cy.get('.canvas-dropzone'),
@@ -69,7 +69,7 @@ const steps = {
69
69
  ...styleAndLayoutCustomizationAccordionComponent.steps,
70
70
  ...figCommonStyleAndLayoutComponent.steps,
71
71
  ...connectorStyleStyleAndLayoutCustomizationComponent.steps,
72
- ...createItemPage.steps,
72
+ ...createItemPage.steps,
73
73
  /**
74
74
  * Verify that the incorrect option icon is displayed for a specific answer input field.
75
75
  * @param {number} inputFieldIndex - The index of the answer input field to verify.
@@ -316,7 +316,17 @@ const steps = {
316
316
  */
317
317
  verifyTextContainerWidthInputFieldValue: (value) => {
318
318
  utilities.verifyInputFieldValue(fillInTheGapsOverImageTextPage.textContainerWidthInputField(), value);
319
- }
319
+ },
320
+
321
+ /**
322
+ * @param {string} file name of the file in fixtures/upload folder
323
+ ] * @description this function uploads a file
324
+ */
325
+ uploadFileWithoutVerification: (file) => {
326
+ fillInTheGapsOverImageTextPage.inputTypeFile()
327
+ .attachFile(file);
328
+ cy.wait(4000);
329
+ },
320
330
  }
321
331
 
322
332
  const tests = {
@@ -621,7 +621,7 @@ const steps = {
621
621
 
622
622
  verifyXAxisMinArrowNotExistGraphEditTab: () => {
623
623
  graphingPage.xAxisGraphEditTab()
624
- .should('not.have.attr', 'marker-start');
624
+ .should('have.attr', 'marker-start', 'null');
625
625
  },
626
626
 
627
627
  verifyXAxisMinArrowExistGraphEditTab: () => {
@@ -636,12 +636,12 @@ const steps = {
636
636
 
637
637
  verifyXAxisMaxArrowNotExistGraphEditTab: () => {
638
638
  graphingPage.xAxisGraphEditTab()
639
- .should('not.have.attr', 'marker-end');
639
+ .should('have.attr', 'marker-end', 'null');
640
640
  },
641
641
 
642
642
  verifyYAxisMinArrowNotExistGraphEditTab: () => {
643
643
  graphingPage.yAxisGraphEditTab()
644
- .should('not.have.attr', 'marker-start');
644
+ .should('have.attr', 'marker-start', 'null');
645
645
  },
646
646
 
647
647
  verifyYAxisMinArrowExistGraphEditTab: () => {
@@ -656,7 +656,7 @@ const steps = {
656
656
 
657
657
  verifyYAxisMaxArrowNotExistGraphEditTab: () => {
658
658
  graphingPage.yAxisGraphEditTab()
659
- .should('not.have.attr', 'marker-end');
659
+ .should('have.attr', 'marker-end', 'null');
660
660
  },
661
661
 
662
662
  /**
@@ -1225,7 +1225,7 @@ const steps = {
1225
1225
 
1226
1226
  verifyXAxisMinArrowNotExistGraphSpecifyCorrectAnswerSection: () => {
1227
1227
  graphingPage.xAxisGraphSpecifyCorrectAnswerSection()
1228
- .should('not.have.attr', 'marker-start');
1228
+ .should('have.attr', 'marker-start', 'null');
1229
1229
  },
1230
1230
 
1231
1231
  verifyXAxisMinArrowExistGraphSpecifyCorrectAnswerSection: () => {
@@ -1240,12 +1240,12 @@ const steps = {
1240
1240
 
1241
1241
  verifyXAxisMaxArrowNotExistGraphSpecifyCorrectAnswerSection: () => {
1242
1242
  graphingPage.xAxisGraphSpecifyCorrectAnswerSection()
1243
- .should('not.have.attr', 'marker-end');
1243
+ .should('have.attr', 'marker-end', 'null');
1244
1244
  },
1245
1245
 
1246
1246
  verifyYAxisMinArrowNotExistGraphSpecifyCorrectAnswerSection: () => {
1247
1247
  graphingPage.yAxisGraphSpecifyCorrectAnswerSection()
1248
- .should('not.have.attr', 'marker-start');
1248
+ .should('have.attr', 'marker-start', 'null');
1249
1249
  },
1250
1250
 
1251
1251
  verifyYAxisMinArrowExistGraphSpecifyCorrectAnswerSection: () => {
@@ -1260,7 +1260,7 @@ const steps = {
1260
1260
 
1261
1261
  verifyYAxisMaxArrowNotExistGraphSpecifyCorrectAnswerSection: () => {
1262
1262
  graphingPage.yAxisGraphSpecifyCorrectAnswerSection()
1263
- .should('not.have.attr', 'marker-end');
1263
+ .should('have.attr', 'marker-end', 'null');
1264
1264
  },
1265
1265
 
1266
1266
  /**
@@ -1491,7 +1491,7 @@ const steps = {
1491
1491
 
1492
1492
  verifyXAxisMinArrowNotExistGraphPreviewTab: () => {
1493
1493
  graphingPage.xAxisGraphPreviewTab()
1494
- .should('not.have.attr', 'marker-start');
1494
+ .should('have.attr', 'marker-start', 'null');
1495
1495
  },
1496
1496
 
1497
1497
  verifyXAxisMinArrowExistGraphPreviewTab: () => {
@@ -1506,12 +1506,12 @@ const steps = {
1506
1506
 
1507
1507
  verifyXAxisMaxArrowNotExistGraphPreviewTab: () => {
1508
1508
  graphingPage.xAxisGraphPreviewTab()
1509
- .should('not.have.attr', 'marker-end');
1509
+ .should('have.attr', 'marker-end', 'null');
1510
1510
  },
1511
1511
 
1512
1512
  verifyYAxisMinArrowNotExistGraphPreviewTab: () => {
1513
1513
  graphingPage.yAxisGraphPreviewTab()
1514
- .should('not.have.attr', 'marker-start');
1514
+ .should('have.attr', 'marker-start', 'null');
1515
1515
  },
1516
1516
 
1517
1517
  verifyYAxisMinArrowExistGraphPreviewTab: () => {
@@ -1526,7 +1526,7 @@ const steps = {
1526
1526
 
1527
1527
  verifyYAxisMaxArrowNotExistGraphPreviewTab: () => {
1528
1528
  graphingPage.yAxisGraphPreviewTab()
1529
- .should('not.have.attr', 'marker-end');
1529
+ .should('have.attr', 'marker-end', 'null');
1530
1530
  },
1531
1531
 
1532
1532
  /**
@@ -120,7 +120,7 @@ const selectors = {
120
120
  optionRowContainerPreviewTab: () => cy.get('.match-list-response-container'),
121
121
  layoutLabel: () => cy.get('[class*="Layoutstyles__SectionWrapper"]'),
122
122
  rowSpacingDropdownLabel: () => cy.get('#Row-spacing-dropdown-label'),
123
- rowSpacingDropdown: () => cy.get('[aria-labelledby*="Row-spacing-dropdown-label"]').eq(0),
123
+ rowSpacingDropdown: () => cy.get('[aria-labelledby*="Row-spacing-select"]').eq(0),
124
124
  rowSpacingDropdownOptions: (ariaLabel = null) => {
125
125
  if (ariaLabel) {
126
126
  return cy.get(`[aria-labelledby*="Row-spacing-dropdown-label"] .dropdown-menu-item[aria-label*="${ariaLabel}"]`)
@@ -129,7 +129,7 @@ const selectors = {
129
129
  }
130
130
  },
131
131
  columnSpacingDropdownLabel: () => cy.get('#Column-spacing-dropdown-label'),
132
- columnSpacingDropdown: () => cy.get('[aria-labelledby*="Column-spacing-dropdown-label"]').eq(0),
132
+ columnSpacingDropdown: () => cy.get('[aria-labelledby*="Column-spacing-select"]').eq(0),
133
133
  columnSpacingDropdownOptions: (ariaLabel = null) => {
134
134
  if (ariaLabel) {
135
135
  return cy.get(`[aria-labelledby*="Column-spacing-dropdown-label"] .dropdown-menu-item[aria-label*="${ariaLabel}"]`)
@@ -1642,7 +1642,7 @@ const steps = {
1642
1642
  */
1643
1643
  selectRowSpacingDropdownOption: (rowSpacingOption) => {
1644
1644
  matchingPage.rowSpacingDropdownOptions(rowSpacingOption)
1645
- .click();
1645
+ .click({force:true});
1646
1646
  },
1647
1647
 
1648
1648
  /**
@@ -222,19 +222,18 @@ const tests = {
222
222
  gridQuestionCommonComponent.steps.setAnswerInSpecifyCorrectAnswerSection({ row: 1, column: 0 });
223
223
  });
224
224
 
225
- it(`When the user has unchecked all the options in the ${accordionName} accordion, \'Error: Please set a correct answer.\' error message should be thrown along with an error icon on the \'${accordionName}\' accordion`, () => {
225
+ it(`When the user has unchecked all the options in the ${accordionName} accordion, 'Error: Please set a correct answer.' error message should not be thrown along with an error icon on the '${accordionName}' accordion`, () => {
226
226
  gridQuestionCommonComponent.steps.uncheckOptionInSpecifyCorrectAnswerSection({ row: 1, column: 0 });
227
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'visible')
228
- utilities.verifyInnerText(commonComponents.errorMessage(), 'Error: Please set a correct answer.');
227
+ utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'notExist')
229
228
  if (accordionName == 'Correct') {
230
229
  autoScoredSpecifyCorrectAnswerSection.correctAnswerAccordion()
231
230
  .within(() => {
232
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
231
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
233
232
  });
234
233
  } else {
235
234
  autoScoredSpecifyCorrectAnswerSection.alternativeAnswerAccordion()
236
235
  .within(() => {
237
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
236
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
238
237
  });
239
238
  };
240
239
  });
@@ -914,7 +914,6 @@ const tests = {
914
914
  ...ckEditorInsertTableComponent.tests,
915
915
  ...ckEditorInsertImageComponent.tests,
916
916
  ...ckEditorLinkComponent.tests,
917
- //Note: need to remove this as change the global function once save as you go is available for all question types
918
917
  verifyPreviewModesAndScoreWhenPointsAndCorrectAnswersIsNotSet: () => {
919
918
  it('When the user has not set correct answer option(s) and alloted points, \'Student view\' radio button should be checked, \'Grading view\' button should not be checked, 0 points should be displayed and no correct or incorrect icons should be displayed in the preview tab', () => {
920
919
  utilities.verifyInnerText(autoScoredScoringPreviewTab.studentViewRadioButtonLabel(), 'Student view');
@@ -963,18 +962,17 @@ const tests = {
963
962
  multipleSelectionPage.steps.uncheckOptionsCheckboxInSpecifyCorrectAnswerSection(1);
964
963
  });
965
964
 
966
- it(`When the user has unchecked all selected options in the ${accordionName} accordion, \'Error: Please set a correct answer.\' error message should be thrown along with an error icon on the \'${accordionName}\' accordion`, () => {
967
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'visible')
968
- utilities.verifyInnerText(commonComponents.errorMessage(), 'Error: Please set a correct answer.');
965
+ it(`When the user has unchecked all selected options in the ${accordionName} accordion, 'Error: Please set a correct answer.' error message should not be thrown along with an error icon on the '${accordionName}' accordion`, () => {
966
+ utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'notExist')
969
967
  if (accordionName == 'Correct') {
970
968
  autoScoredSpecifyCorrectAnswerSection.correctAnswerAccordion()
971
969
  .within(() => {
972
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
970
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
973
971
  });
974
972
  } else {
975
973
  autoScoredSpecifyCorrectAnswerSection.alternativeAnswerAccordion()
976
974
  .within(() => {
977
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
975
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
978
976
  });
979
977
  };
980
978
  });
@@ -183,10 +183,22 @@ const steps = {
183
183
  .blur();
184
184
  },
185
185
 
186
+ focusInSpecifyCorrectAnswerInputField: () => {
187
+ shortTextResponsePage.answerInputFieldSpecifyCorrectAnswerSection()
188
+ .focus();
189
+ shortTextResponsePage.answerInputFieldSpecifyCorrectAnswerSection()
190
+ .parents('.short-text-response-input-field')
191
+ .should('have.class', 'Mui-focused');
192
+ },
193
+
186
194
  focusOutOfSpecifyCorrectAnswerInputField: () => {
187
195
  shortTextResponsePage.answerInputFieldSpecifyCorrectAnswerSection()
188
196
  .clear()
197
+ .click()
189
198
  .blur();
199
+ shortTextResponsePage.answerInputFieldSpecifyCorrectAnswerSection()
200
+ .parents('.short-text-response-input-field')
201
+ .should('not.have.class', 'Mui-focused');
190
202
  },
191
203
 
192
204
  clearAndFocusOutOfResponseInputFieldPreviewTab: () => {
@@ -223,6 +235,9 @@ const steps = {
223
235
  focusInAnswerInputFieldPreviewTab: () => {
224
236
  shortTextResponsePage.previewTabResponseField()
225
237
  .click();
238
+ shortTextResponsePage.previewTabResponseField()
239
+ .parents('.short-text-preview-response-input-field')
240
+ .should('have.class', 'Mui-focused');
226
241
  },
227
242
 
228
243
  /**
@@ -310,7 +325,11 @@ const steps = {
310
325
 
311
326
  focusOutOfResponseField: () => {
312
327
  shortTextResponsePage.previewTabResponseField()
328
+ .click()
313
329
  .blur();
330
+ shortTextResponsePage.previewTabResponseField()
331
+ .parents('.short-text-preview-response-input-field')
332
+ .should('not.have.class', 'Mui-focused');
314
333
  },
315
334
 
316
335
  /**
@@ -907,8 +926,7 @@ const tests = {
907
926
 
908
927
  it('When user focuses in and out of the response accordion \'Answer\' input field, \'Error: Answer is required.\' error message should not be displayed', () => {
909
928
  shortTextResponsePage.steps.clearAndFocusOutOfSpecifyCorrectAnswerInputField();
910
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'visible');
911
- utilities.verifyInnerText(commonComponents.errorMessage(), 'Error: Answer is required.');
929
+ utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'notExist');
912
930
  });
913
931
 
914
932
  autoScoredSpecifyCorrectAnswerSection.tests.verifyAutoScoredCorrectAnswerErrorMessageCSSAndA11y();
@@ -719,7 +719,6 @@ const tests = {
719
719
  ...autoScoredStudentViewSettings.tests,
720
720
  ...additionalSettingsAccessibilitySectionComponent.tests,
721
721
  ...mcqAdditionalSettingsBase.tests,
722
- //Note: need to remove this as change the global function once save as you go is available for all question types
723
722
  verifyPreviewModesAndScoreWhenPointsAndCorrectAnswersIsNotSet: () => {
724
723
  it('When the user has not set correct answer option(s) and alloted points, \'Student view\' radio button should be checked, \'Grading view\' button should not be checked, 0 points should be displayed and no correct or incorrect icons should be displayed in the preview tab', () => {
725
724
  utilities.verifyInnerText(autoScoredScoringPreviewTab.studentViewRadioButtonLabel(), 'Student view');
@@ -777,8 +776,8 @@ const tests = {
777
776
 
778
777
  it('On deleting correct answer option(s), \'Error: Please set a correct answer.\' validation error message should be thrown along with an error icon on the \'Correct\' tab', () => {
779
778
  singleSelectionPage.steps.deleteOption(1);
780
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'exist');
781
- autoScoredSpecifyCorrectAnswerSection.steps.verifySpecifyCorrectAnswerErrorIconIsVisible();
779
+ utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'notExist');
780
+ autoScoredSpecifyCorrectAnswerSection.steps.verifySpecifyCorrectAnswerErrorIconNotExists();
782
781
  });
783
782
 
784
783
  autoScoredSpecifyCorrectAnswerSection.tests.verifyAutoScoredCorrectAnswerErrorMessageCSSAndA11y();
@@ -35,6 +35,7 @@ const selectors = {
35
35
  responseAccordionLabel: () => cy.get('[class*="ResponseAccordionstyles__Label"]'),
36
36
  responseAccordionAnswerInputField: () => cy.get('[class*="__AnswersWrapper"] .equation-input-component .mq-editable-field'),
37
37
  responseAccordionAnswerInputFieldNew: () => cy.get('[class*="__AnswersWrapper"] .equation-input-component'),
38
+ correctAnswerSection: () => cy.get('.correct-answer-wrapper'),
38
39
  responseAccordionPointsWrapper: () => cy.get('[class*="ResponseAccordionstyles__PointsDiv"]'),
39
40
  responseAccordionPointsLabel: () => cy.get('[class*="ResponseAccordionstyles__PointsLabel"]'),
40
41
  responseAccordionPointsScore: () => cy.get('[class*="ResponseAccordionstyles__Points-"]'),
@@ -1362,6 +1363,16 @@ const steps = {
1362
1363
  .eq(responseIndex)
1363
1364
  .click();
1364
1365
  },
1366
+
1367
+ correctAnswerSectionOverflow: () => {
1368
+ textEntryMathPage.correctAnswerSection()
1369
+ .should('exist')
1370
+ .then(($CorrectAnswerSection) => {
1371
+ const scrollWidth = $CorrectAnswerSection[0].scrollWidth;
1372
+ const clientWidth = $CorrectAnswerSection[0].clientWidth;
1373
+ expect(scrollWidth).to.not.be.greaterThan(clientWidth);
1374
+ });
1375
+ }
1365
1376
  }
1366
1377
 
1367
1378
  const tests = {
@@ -1418,7 +1429,7 @@ const tests = {
1418
1429
  it('User should be able to expand multiple response accordions simultaneously', () => {
1419
1430
  if (accordionName === 'Alternate') {
1420
1431
  textEntryMathPage.steps.deleteAlternativeAnswerAccordion(0);
1421
- }
1432
+ }
1422
1433
  textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1423
1434
  textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(1);
1424
1435
  textEntryMathPage.steps.verifyResponseAccordionIsExpanded(0);
@@ -1942,7 +1953,7 @@ const tests = {
1942
1953
  }
1943
1954
  });
1944
1955
  })
1945
- }
1956
+ },
1946
1957
  }
1947
1958
 
1948
1959
  export const textEntryMathPage = {
@@ -21,8 +21,8 @@ const selectors = {
21
21
  cancelButton: () => cy.get('[data-testid*="reject-button"]'),
22
22
  setHeightAndWidthForAllTextContainersLabel: () => cy.get('.set-textContainer-dimensions-checkbox label'),
23
23
  setHeightAndWidthForAllTextContainersCheckbox: () => cy.get('.set-textContainer-dimensions-checkbox .ngie-checkbox'),
24
- heightLabel: () => cy.get('[aria-labelledby="Height (px)"]'),
25
- widthLabel: () => cy.get('[aria-labelledby="Width (px)"]'),
24
+ heightLabel: () => cy.get('[for="Height (px)"]'),
25
+ widthLabel: () => cy.get('[for="Width (px)"]'),
26
26
  heightInputField: () => cy.get('.MuiInputBase-input[aria-label="Height (px)"]'),
27
27
  widthInputField: () => cy.get('.MuiInputBase-input[aria-label="Width (px)"]'),
28
28
  textContainerEditTab: () => cy.get('.canvas-dropzone'),
@@ -90,14 +90,13 @@ const selectors = {
90
90
  maximumFileSize: () => cy.get('[class*="UploadQuestionPreviewstyle__MaxFileLimitDesc"]'),
91
91
  unSupportedFileInfoIcon: () => cy.get('[class*="UploadedDocumentsstyle__UnSupportedFileIcon"]'),
92
92
  //Thumb nail
93
- imageThumbNail: () => cy.get('img[class*="UploadedDocumentsstyle__ImageContainer"]'),
93
+ imageThumbNail: () => cy.get('[class*="UploadedDocumentsstyle__ImageContainer"]'),
94
94
  imageThumbNailButton: () => cy.get('[class*="UploadedDocumentsstyle__ImageContainerButton"]'),
95
95
  popUpWrapper: () => cy.get('[class*="UploadedDocumentsstyle__ImagePopupDiv"]'),
96
96
  imageDisplayedInsidePopUp: () => cy.get('.image-upload-popup-wrapper'),
97
97
  downloadIconOfPopUp: () => cy.get('.download-icon'),
98
98
  downloadTextOfPopUp: () => cy.get('[class*="UploadedDocumentsstyle__DownloadTextWrapper"]'),
99
99
  closePopUpButton: () => cy.get('.close-popup-btn'),
100
- imageThumbnailGradingPage: () => cy.get('img[class*="UploadQuestionPreviewstyle__ImageContainer"]'),
101
100
  }
102
101
 
103
102
  const steps = {
@@ -243,6 +242,7 @@ const steps = {
243
242
  * Verifies the pop up details and visiblity when user clicks on thumb nail or on image name
244
243
  */
245
244
  verifyImagePopUpDetail: () => {
245
+ cy.wait(2000);
246
246
  utilities.verifyElementVisibilityState(uploadResponsePage.popUpWrapper(), 'visible');
247
247
  utilities.verifyElementVisibilityState(uploadResponsePage.imageDisplayedInsidePopUp(), 'visible');
248
248
  utilities.verifyElementVisibilityState(uploadResponsePage.downloadIconOfPopUp(), 'visible');
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.326-IEI-4285-3f1c280.0",
3
+ "version": "1.0.328-UpdateRepo28thFeb-24a9148.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -1,17 +0,0 @@
1
- import { rulerPage } from "../../../pages";
2
- import abortEarlySetup from "../../../support/helpers/abortEarly";
3
-
4
- describe('Dummy test for setting up pipeline Create question page - Ruler resource type', () => {
5
- before(() => {
6
- cy.loginAs('admin');
7
- });
8
-
9
- describe('Header section contents', () => {
10
- abortEarlySetup();
11
- before(() => {
12
- rulerPage.steps.navigateToCreateResource('ruler');
13
- });
14
-
15
- rulerPage.tests.verifyCreateQuestionPageQuestionTypeHeader('Ruler');
16
- });
17
- });