itemengine-cypress-automation 1.0.167-repoUpdate10April-1465c8c.0 → 1.0.169-uploadResponseMigration-83ab996.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (113) hide show
  1. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/allOrNothingBasicForAllViews.smoke.js +2 -2
  2. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/clickAndDrop.js +11 -22
  3. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/clickAndDrop.js +7 -18
  4. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/clickAndDrop.js +6 -11
  5. package/cypress/e2e/ILC/Graphing/previewContentsForAllViews.smoke.js +1 -0
  6. package/cypress/e2e/ILC/Graphing/toolsControlsAndBackgroundSection.js +36 -2
  7. package/cypress/e2e/ILC/GridFill/allOrNothingBasicForAllViews.smoke.js +34 -22
  8. package/cypress/e2e/ILC/GridFill/checkAnswerFunctionalityForAllViews.smoke.js +24 -8
  9. package/cypress/e2e/ILC/GridFill/previewContentsForAllViews.smoke.js +25 -5
  10. package/cypress/e2e/ILC/GridFill/scoring/allOrNothingAlternativePointsGreaterThanCorrectPoints.js +114 -68
  11. package/cypress/e2e/ILC/GridFill/scoring/allOrNothingCorrectPointsEqualToAlternativePoints.js +111 -67
  12. package/cypress/e2e/ILC/GridFill/scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +123 -71
  13. package/cypress/e2e/ILC/GridFill/scoring/allOrNothingScoringCellShadeCount.js +63 -41
  14. package/cypress/e2e/ILC/GridFill/scoring/manuallyAndNonScored.js +25 -21
  15. package/cypress/e2e/ILC/GridFill/scoring/partialEqualWeightsBasic.js +85 -50
  16. package/cypress/e2e/ILC/GridFill/scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +115 -68
  17. package/cypress/e2e/ILC/GridFill/scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +98 -54
  18. package/cypress/e2e/ILC/GridFill/scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +120 -72
  19. package/cypress/e2e/ILC/GridFill/studentViewSettingsSection.js +3 -3
  20. package/cypress/e2e/ILC/Matching/specifyCorrectAnswerSection.js +1 -1
  21. package/cypress/e2e/ILC/ToolSettings/toolSettingsContent.js +4 -4
  22. package/cypress/fixtures/theme/ilc.json +26 -14
  23. package/cypress/pages/components/autoScoredScoringSectionMultiResponseType.js +1 -1
  24. package/cypress/pages/components/autoScoredSpecifyCorrectAnswerSection.js +0 -3
  25. package/cypress/pages/components/autoScoredStudentViewSettings.js +1 -1
  26. package/cypress/pages/components/colorPopupComponent.js +2 -2
  27. package/cypress/pages/components/gridQuestionCommonComponent.js +2 -629
  28. package/cypress/pages/components/index.js +0 -3
  29. package/cypress/pages/components/maximumCapacityPerDropzoneComponent.js +1 -1
  30. package/cypress/pages/components/measuringToolComponent.js +2 -2
  31. package/cypress/pages/components/scoringSectionBaseEditTab.js +1 -1
  32. package/cypress/pages/components/setPointsPopupBase.js +4 -6
  33. package/cypress/pages/components/specifyRowsAndColumnsComponent.js +3 -60
  34. package/cypress/pages/components/toolSettingsComponent.js +12 -80
  35. package/cypress/pages/dragAndDropIntoCategoriesPage.js +8 -0
  36. package/cypress/pages/feedbackScalePage.js +449 -591
  37. package/cypress/pages/fillInTheGapsOverImageDragAndDropPage.js +1 -3
  38. package/cypress/pages/graphingPage.js +145 -9
  39. package/cypress/pages/gridFillPage.js +120 -135
  40. package/cypress/pages/highlightPage.js +394 -0
  41. package/cypress/pages/index.js +2 -5
  42. package/cypress/pages/matchingPage.js +20 -78
  43. package/cypress/pages/multipleSelectionGridPage.js +1 -88
  44. package/cypress/pages/singleSelectionGridPage.js +0 -86
  45. package/cypress/support/migrationHelpers/extractLrnQuestionData.js +38 -1
  46. package/cypress/support/migrationHelpers/lrnQestionTypesENUM.js +1 -0
  47. package/cypress/support/migrationHelpers/migrationScript.js +4 -0
  48. package/cypress/support/migrationHelpers/verifyIeQuestionData.js +34 -2
  49. package/package.json +1 -1
  50. package/cypress/e2e/ILC/BrainingCampManipulative/additionalSettings.js +0 -83
  51. package/cypress/e2e/ILC/BrainingCampManipulative/editTabBasicSection.js +0 -200
  52. package/cypress/e2e/ILC/BrainingCampManipulative/editTabScoringSection.js +0 -56
  53. package/cypress/e2e/ILC/BrainingCampManipulative/gradingViewAndCorrectAnswerViewContents.smoke.js +0 -95
  54. package/cypress/e2e/ILC/BrainingCampManipulative/headerSection.js +0 -71
  55. package/cypress/e2e/ILC/BrainingCampManipulative/previewTabContent.smoke.js +0 -72
  56. package/cypress/e2e/ILC/BrainingCampManipulative/toolSettings.js +0 -71
  57. package/cypress/e2e/ILC/EssayResponse/essayResponseAdditionalSettings.js +0 -432
  58. package/cypress/e2e/ILC/EssayResponse/essayResponseAdditionalSettingsBasic.js +0 -134
  59. package/cypress/e2e/ILC/FeedbackScaleNew/feedbackScaleStylePreviewTab.js +0 -161
  60. package/cypress/e2e/ILC/FeedbackScaleNew/numbersFeedbackScaleStyle.js +0 -308
  61. package/cypress/e2e/ILC/FeedbackScaleNew/previewContentsForAllViews.smoke.js +0 -216
  62. package/cypress/e2e/ILC/FeedbackScaleNew/starsHeartsFeedbackScaleStyle.js +0 -336
  63. package/cypress/e2e/ILC/FeedbackScaleNew/textFeedbackScaleStyle.js +0 -570
  64. package/cypress/e2e/ILC/FeedbackScaleNew/thumbsFeedbackScaleStyle.js +0 -214
  65. package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropAdditionalSettings.js +0 -356
  66. package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropAdditionalSettingsResponseAccordion.js +0 -299
  67. package/cypress/e2e/ILC/Graphing/Scoring/allOrNothingWithCorrectPointsEqualToAlternatePoints.js +0 -355
  68. package/cypress/e2e/ILC/Matching/maximumCapacityPerDropzoneSection.js +0 -309
  69. package/cypress/e2e/ILC/Matching/toolSettings.js +0 -72
  70. package/cypress/e2e/ILC/MultipleSelectionGridNew/editTabBasicSection.js +0 -1033
  71. package/cypress/e2e/ILC/MultipleSelectionGridNew/test.js +0 -28
  72. package/cypress/e2e/ILC/NumberLine/Scoring/allOrNothingWithAlternatePointsGreaterThanCorrectPoints.js +0 -236
  73. package/cypress/e2e/ILC/NumberLine/Scoring/allOrNothingWithCorrectPointsEqualToAlternatePoints.js +0 -239
  74. package/cypress/e2e/ILC/NumberLine/Scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +0 -278
  75. package/cypress/e2e/ILC/NumberLine/Scoring/manualAndNonScoredScoring.js +0 -178
  76. package/cypress/e2e/ILC/NumberLine/Scoring/partialEqualWeightsBasic.js +0 -407
  77. package/cypress/e2e/ILC/NumberLine/Scoring/partialEqualWeightsWithAlternatePointsGreaterThanCorrectPoints.js +0 -273
  78. package/cypress/e2e/ILC/NumberLine/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternatePoints.js +0 -278
  79. package/cypress/e2e/ILC/NumberLine/Scoring/partialEqualWeigtsWithCorrectPointsEqualToAlternatePoints.js +0 -228
  80. package/cypress/e2e/ILC/NumberLine/additionalSettings.js +0 -120
  81. package/cypress/e2e/ILC/NumberLine/allOrNothingScoringForAllViews.smoke.js +0 -659
  82. package/cypress/e2e/ILC/NumberLine/checkAnswerFunctionalityForAllViews.smoke.js +0 -149
  83. package/cypress/e2e/ILC/NumberLine/editTabScoringSection.js +0 -151
  84. package/cypress/e2e/ILC/NumberLine/gradingViewAndCorrectAnswerView.smoke.js +0 -171
  85. package/cypress/e2e/ILC/NumberLine/headerSection.js +0 -76
  86. package/cypress/e2e/ILC/NumberLine/minimumScoringPenaltyPointsAndRoundingDropdown.js +0 -54
  87. package/cypress/e2e/ILC/NumberLine/previewTabContentsForAllViews.smoke.js +0 -200
  88. package/cypress/e2e/ILC/NumberLine/specifyCorrectAnswerSection.js +0 -67
  89. package/cypress/e2e/ILC/NumberLine/studentViewSettings.js +0 -135
  90. package/cypress/e2e/ILC/NumberLine/toolSettings.js +0 -73
  91. package/cypress/e2e/ILC/NumberLine/toolsAndControls.js +0 -372
  92. package/cypress/e2e/ILC/SingleSelectionGridNew/editTabBasicSection.js +0 -1014
  93. package/cypress/e2e/ILC/TextSelection/Scoring/allOrNothingAlternatePointsMoreThanCorrectPoints.js +0 -235
  94. package/cypress/e2e/ILC/TextSelection/Scoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +0 -235
  95. package/cypress/e2e/ILC/TextSelection/Scoring/allOrNothingCorrectPointsMoreThanAlternatePoints.js +0 -235
  96. package/cypress/e2e/ILC/TextSelection/Scoring/partialDifferentWeightsBasic.js +0 -457
  97. package/cypress/e2e/ILC/TextSelection/Scoring/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +0 -342
  98. package/cypress/e2e/ILC/TextSelection/Scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +0 -342
  99. package/cypress/e2e/ILC/TextSelection/Scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +0 -342
  100. package/cypress/e2e/ILC/TextSelection/Scoring/partialEqualWeightsBasic.js +0 -155
  101. package/cypress/e2e/ILC/TextSelection/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +0 -314
  102. package/cypress/e2e/ILC/TextSelection/Scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +0 -275
  103. package/cypress/e2e/ILC/TextSelection/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +0 -314
  104. package/cypress/e2e/ILC/TextSelection/allOrNothingScoringForAllViews.smoke.js +0 -290
  105. package/cypress/e2e/ILC/TextSelection/checkAnswerFunctionalityForAllViews.smoke.js +0 -142
  106. package/cypress/e2e/ILC/TextSelection/previewContentsForAllViews.js +0 -137
  107. package/cypress/pages/brainingCampManipulativePage.js +0 -122
  108. package/cypress/pages/components/defaultToolDropdown.js +0 -77
  109. package/cypress/pages/components/resetPopupComponent.js +0 -74
  110. package/cypress/pages/components/toolsAndControlsComponent.js +0 -69
  111. package/cypress/pages/feedbackScalePage copy.js +0 -716
  112. package/cypress/pages/numberLinePage.js +0 -723
  113. package/cypress/pages/textSelectionPage.js +0 -582
@@ -25,170 +25,216 @@ describe('Create item page - Grid fill: All or nothing with alternative answers'
25
25
  gridFillPage.steps.switchToPreviewTab();
26
26
  });
27
27
 
28
- it('When the user selects \'Grading\' view without attempting the question, no correct/incorrect icons should be displayed in response grid and correct icon should be displayed in responses from alternative accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
28
+ it('When the user selects \'Grading\' view without attempting the question, correct icon should be displayed in responses from alternative accordion', () => {
29
29
  gridFillPage.steps.switchToGradingView();
30
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 2);
31
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 3);
32
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 4);
33
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
34
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
35
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
36
- gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
30
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
31
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
32
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
33
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
34
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 3);
35
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 3);
36
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
37
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 4);
38
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 4);
37
39
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
38
40
  });
39
41
 
40
- it('When the user attempts the question with responses from the correct accordion, then the user should be awarded with points specified for correct accordion (less than overall points) and on switching to \'Grading\' view, correct icon should be displayed in responses from correct accordion, and a status message with text \'Your answer is correct\' should be displayed and correct responses from alternate accordion should be displayed in the correct answers section', () => {
42
+ it('When the user attempts the question with responses from the correct accordion, then the user should be awarded with points specified for correct accordion (less than overall points) and on switching to \'Grading\' view, correct icon, background and border should be displayed in responses from correct accordion, and a status message with text \'Your answer is correct\' should be displayed', () => {
41
43
  gridFillPage.steps.resetQuestionPreview();
42
44
  gridFillPage.steps.selectCellPreviewTab(0, 0);
43
45
  gridFillPage.steps.selectCellPreviewTab(0, 1);
44
46
  gridFillPage.steps.selectCellPreviewTab(0, 2);
45
47
  gridFillPage.steps.verifyPreviewScore(10, 20);
46
48
  gridFillPage.steps.switchToGradingView();
47
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
48
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
49
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
50
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
51
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
52
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
49
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
50
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
51
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
52
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
53
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
54
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
53
55
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
54
56
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
55
57
  cy.log('When the user has attempted the question with responses from the correct accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the responses from correct accordion and status message with text \'Your answer is correct\' should be displayed')
56
58
  gridFillPage.steps.checkAnswer();
57
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
58
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
59
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
59
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
60
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
61
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
62
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
63
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
64
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
60
65
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
61
66
  });
62
67
 
63
- it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with full points and on switching to \'Grading\' view, correct icon should be displayed in responses from alternative accordion and status message with text \'Your answer is correct\' should be displayed and correct answers section should not be displayed', () => {
68
+ it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with full points and on switching to \'Grading\' view, correct icon, background and border should be displayed in responses from alternative accordion and status message with text \'Your answer is correct\' should be displayed', () => {
64
69
  gridFillPage.steps.resetQuestionPreview();
65
70
  gridFillPage.steps.selectCellPreviewTab(0, 2);
66
71
  gridFillPage.steps.selectCellPreviewTab(0, 3);
67
72
  gridFillPage.steps.selectCellPreviewTab(0, 4);
68
73
  gridFillPage.steps.verifyPreviewScore(20, 20);
69
74
  gridFillPage.steps.switchToGradingView();
70
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
71
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
72
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
75
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
76
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
77
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
78
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
79
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
80
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
73
81
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
74
- gridFillPage.steps.verifyCorrectAnswerSectionNotExists();
75
82
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
76
83
  cy.log('When the user has attempted the question with responses from the alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the responses from alternative accordion and a status message with text \'Your answer is correct\' should be displayed')
77
84
  gridFillPage.steps.checkAnswer();
78
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
79
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
80
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
85
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
86
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
87
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
88
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
89
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
90
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
81
91
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
82
92
  });
83
93
 
84
- it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed in the selected responses from correct accordion, and a status message with text \'Your answer is incorrect\' should be displayed with correct icons in responses from alternate accordion should be displayed in the correct answers section', () => {
94
+ it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon and border should be displayed in the selected responses from alternative accordion, incorrect icon should be displayed for partially selected correct accordion response and a status message with text \'Your answer is incorrect\' should be displayed', () => {
85
95
  gridFillPage.steps.resetQuestionPreview();
86
96
  gridFillPage.steps.selectCellPreviewTab(0, 0);
87
97
  gridFillPage.steps.selectCellPreviewTab(0, 1);
88
98
  gridFillPage.steps.verifyPreviewScore(0, 20);
89
99
  gridFillPage.steps.switchToGradingView();
90
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
91
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
92
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
93
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
94
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
100
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
101
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
102
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
103
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
104
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
105
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
106
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 0);
107
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 0);
108
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 1);
109
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 1);
95
110
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
96
111
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
97
112
  cy.log('When the user has attempted the question with partially correct options exclusively from the correct accordion and clicks on \'Check answer\' button, then incorrect icon should be displayed for partially selected correct accordion responses, a status message with text \'Your answer is incorrect\' and correct answer section should not be displayed')
98
113
  gridFillPage.steps.checkAnswer();
99
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
100
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
114
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 0);
115
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 0);
116
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 1);
117
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 1);
101
118
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
102
119
  });
103
120
 
104
- it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed in the selected alternative accordion responses and a status message with text \'Your answer is incorrect\' should be displayed with correct icons in responses from alternate accordion should be displayed in the correct answers section', () => {
121
+ it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon, background and border should be displayed in the selected alternative accordion responses, correct icon and border should be displayed for unselected alternative accordion response and a status message with text \'Your answer is incorrect\' should be displayed', () => {
105
122
  gridFillPage.steps.resetQuestionPreview();
106
123
  gridFillPage.steps.selectCellPreviewTab(0, 3);
107
124
  gridFillPage.steps.verifyPreviewScore(0, 20);
108
125
  gridFillPage.steps.switchToGradingView();
109
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
110
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
111
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
112
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
126
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
127
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
128
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
129
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
130
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 4);
131
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
132
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
133
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 4);
113
134
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
114
135
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
115
136
  cy.log('When the user has attempted the question with partially correct options exclusively from the alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the correct answer responses, no icon/border should be displayed for unselected response cell and a status message with text \'Your answer is incorrect\' and correct answer section should not be displayed')
116
137
  gridFillPage.steps.checkAnswer();
117
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
138
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
139
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
118
140
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
119
141
  });
120
142
 
121
- it('When the user attempts the question partially correct with all the responses correct as per the correct accordion but one response incomplete, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed in the response from alternative accordion, correct icons in responses from alternate accordion should be displayed in the correct answers section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
143
+ it('When the user attempts the question partially correct with all the responses correct as per the correct accordion but one response incomplete, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon, background and border should be displayed in the selected alternative accordion responses, correct icon and border should be displayed for unselected correct answer response and a status message with text \'Your answer is incorrect\' should be displayed', () => {
122
144
  gridFillPage.steps.resetQuestionPreview();
123
145
  gridFillPage.steps.selectCellPreviewTab(0, 3);
124
146
  gridFillPage.steps.selectCellPreviewTab(0, 4);
125
147
  gridFillPage.steps.verifyPreviewScore(0, 20);
126
148
  gridFillPage.steps.switchToGradingView();
127
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
128
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
129
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
130
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
131
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
149
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
150
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
151
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
152
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
153
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
154
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
155
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
132
156
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
133
157
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
134
158
  cy.log('When the user has attempted the question with partially correct with all the response correct as per the alternative accordion but one response incomplete and clicks on \'Check answer\' button, then correct icon should be displayed in the response from the alternative accordion and no icon should be displayed for unselected response, a status message with text \'Your answer is incorrect\' should be displayed')
135
159
  gridFillPage.steps.checkAnswer();
136
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
137
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
160
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
161
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
162
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
163
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
138
164
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
139
165
  });
140
166
 
141
- it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed in response from alternative accordion, incorrect icon should be displayed in responses from correct accordion, correct icons in responses from alternate accordion should be displayed in the correct answers section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
167
+ it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed in selected alternative accordion response, correct icon should be displayed for unselected response from alternative accordion, incorrect icon should be displayed in selected correct accordion response and a status message with text \'Your answer is incorrect\' should be displayed', () => {
142
168
  gridFillPage.steps.resetQuestionPreview();
143
169
  gridFillPage.steps.selectCellPreviewTab(0, 0);
144
170
  gridFillPage.steps.selectCellPreviewTab(0, 4);
145
171
  gridFillPage.steps.verifyPreviewScore(0, 20);
146
172
  gridFillPage.steps.switchToGradingView();
147
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(0, 0);
148
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
149
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
150
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
151
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
173
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
174
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
175
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
176
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
177
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 3);
178
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 3);
179
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
180
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
181
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 0);
182
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 0);
152
183
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
153
184
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
154
185
  cy.log('When the user has attempted the question with equal number of correct responses from correct and alternative accordion and clicks on \'Check answer\' button, then correct icon, background and border should be displayed in alternative accordion response, incorrect icon, background and border should be displayed in correct accordion response and a status message with text \'Your answer is incorrect\' should be displayed')
155
186
  gridFillPage.steps.checkAnswer();
156
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(0, 0);
157
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
187
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 0);
188
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 0);
189
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
190
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
158
191
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
159
192
  });
160
193
 
161
- it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be in the common response, correct icons in responses from alternate accordion should be displayed in the correct answers section and a status message \'Your answer is incorrect\' should be displayed', () => {
194
+ it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon, background and border should be in the common response and correct icon and border response from alternative answer accordion and a status message \'Your answer is incorrect\' should be displayed', () => {
162
195
  gridFillPage.steps.resetQuestionPreview();
163
196
  gridFillPage.steps.selectCellPreviewTab(0, 2);
164
197
  gridFillPage.steps.verifyPreviewScore(0, 20);
165
198
  gridFillPage.steps.switchToGradingView();
166
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
167
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
168
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
169
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
199
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
200
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
201
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
202
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 3);
203
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 3);
204
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
205
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 4);
206
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 4);
170
207
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
171
208
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
172
209
  cy.log('When the user has attempted the question with common response between correct and alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the correct answer responses, no icon should be displayed for unselected response area and a status message with text \'Your answer is incorrect\' should be displayed')
173
210
  gridFillPage.steps.checkAnswer();
174
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
211
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
212
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
175
213
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
176
214
  });
177
215
 
178
- it('When the user attempts the question incorrectly, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icon should be displayed in incorrect response, correct icons in responses from alternate accordion should be displayed in the correct answers section, a status message with text \'Your answer is incorrect\'', () => {
216
+ it('When the user attempts the question incorrectly, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icon, background and border should be displayed in incorrect response, a status message with text \'Your answer is incorrect\' and correct icon and border with all correct answers from the alternative accordion should be displayed', () => {
179
217
  gridFillPage.steps.resetQuestionPreview();
180
218
  gridFillPage.steps.selectCellPreviewTab(1, 2);
181
219
  gridFillPage.steps.verifyPreviewScore(0, 20);
182
220
  gridFillPage.steps.switchToGradingView();
183
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(1, 2);
184
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
185
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 3);
186
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 4);
221
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
222
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
223
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
224
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
225
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 3);
226
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 4);
227
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
228
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 3);
229
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 4);
230
+ gridFillPage.steps.verifyIncorrectResponseIcon(1, 2);
231
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(1, 2);
187
232
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
188
233
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
189
234
  cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icon, background and border should be displayed in incorrect response and a status message with text \'Your answer is incorrect\' should be displayed')
190
235
  gridFillPage.steps.checkAnswer();
191
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(1, 2);
236
+ gridFillPage.steps.verifyIncorrectResponseIcon(1, 2);
237
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(1, 2);
192
238
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
193
239
  });
194
240
  });
@@ -24,169 +24,213 @@ describe('Create item page - Grid fill: All or nothing with alternative answers'
24
24
  gridFillPage.steps.switchToPreviewTab();
25
25
  });
26
26
 
27
- it('When the user selects \'Grading\' view without attempting the question, correct icons in responses from correct accordion should be displayed in the correct answers section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
27
+ it('When the user selects \'Grading\' view without attempting the question, correct answer tick should be displayed in correct answer cell', () => {
28
28
  gridFillPage.steps.switchToGradingView();
29
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 0);
30
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 1);
31
- gridFillPage.steps.verifyCorrectIncorrectResponseIconNotExistPreviewTab(0, 2);
32
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
33
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
34
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
35
- gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
29
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
30
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 0);
31
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 0);
32
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
33
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 1);
34
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 1);
35
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
36
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
37
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
36
38
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
37
39
  });
38
40
 
39
- it('When the user attempts the question with responses from the correct accordion, then the user should be awarded full points and on switching to \'Grading\' view, correct icon should be displayed in all the responses from correct accordion in response grid, correct answer section and a status message with text \'Your answer is correct\' should be displayed', () => {
41
+ it('When the user attempts the question with responses from the correct accordion, then the user should be awarded full points and on switching to \'Grading\' view, correct icon, border, background should be displayed in all the responses from correct accordion and a status message with text \'Your answer is correct\' should be displayed', () => {
40
42
  gridFillPage.steps.resetQuestionPreview();
41
43
  gridFillPage.steps.selectCellPreviewTab(0, 0);
42
44
  gridFillPage.steps.selectCellPreviewTab(0, 1);
43
45
  gridFillPage.steps.selectCellPreviewTab(0, 2);
44
46
  gridFillPage.steps.verifyPreviewScore(20, 20);
45
47
  gridFillPage.steps.switchToGradingView();
46
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
47
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
48
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
48
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
49
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
50
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
51
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
52
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
53
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
49
54
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
50
- gridFillPage.steps.verifyCorrectAnswerSectionNotExists();
51
- gridFillPage.steps.verifyCorrectAnswerSectionNotExists();
52
55
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
53
56
  cy.log('When the user has attempted the question with responses from the correct accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the responses from correct accordion and a status message with text \'Your answer is correct\' should be displayed')
54
57
  gridFillPage.steps.checkAnswer();
55
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
56
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
57
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
58
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
59
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
60
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
61
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
62
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
63
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
58
64
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
59
65
  });
60
66
 
61
- it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with points specified for alternative accordion and on switching to \'Grading\' view, correct icon should be displayed in all the responses from alternative accordion in response grid, correct answer section and a status message with text \'Your answer is correct\' should be displayed', () => {
67
+ it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with points specified for alternative accordion and on switching to \'Grading\' view, correct icon, border, background should be displayed in all the responses from alternative accordion, a status message with text \'Your answer is correct\' should be displayed', () => {
62
68
  gridFillPage.steps.resetQuestionPreview();
63
69
  gridFillPage.steps.selectCellPreviewTab(0, 2);
64
70
  gridFillPage.steps.selectCellPreviewTab(0, 3);
65
71
  gridFillPage.steps.selectCellPreviewTab(0, 4);
66
72
  gridFillPage.steps.verifyPreviewScore(20, 20);
67
73
  gridFillPage.steps.switchToGradingView();
68
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
69
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
70
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
74
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
75
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
76
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
77
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
78
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
79
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
71
80
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
72
- gridFillPage.steps.verifyCorrectAnswerSectionNotExists();
73
81
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
74
82
  cy.log('When the user has attempted the question with responses from the alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the responses from alternative accordion and a status message with text \'Your answer is correct\' should be displayed')
75
83
  gridFillPage.steps.checkAnswer();
76
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
77
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
78
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
84
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
85
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
86
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
87
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
88
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
89
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
79
90
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
80
91
  });
81
92
 
82
- it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed in the responses from correct accordion in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
93
+ it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon, border, background should be displayed in the responses from correct accordion, correct background should not be displayed in unselected response and a status message with text \'Your answer is incorrect\' should be displayed', () => {
83
94
  gridFillPage.steps.resetQuestionPreview();
84
95
  gridFillPage.steps.selectCellPreviewTab(0, 0);
85
96
  gridFillPage.steps.selectCellPreviewTab(0, 1);
86
97
  gridFillPage.steps.verifyPreviewScore(0, 20);
87
98
  gridFillPage.steps.switchToGradingView();
88
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
89
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
90
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
91
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
92
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
99
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
100
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
101
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
102
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
103
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
104
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
105
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
93
106
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
94
107
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
95
108
  cy.log('When the user has attempted the question with partially correct options exclusively from the correct accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the response from correct accordion, a status message with text \'Your answer is incorrect\' and correct answer section should not be displayed')
96
109
  gridFillPage.steps.checkAnswer();
97
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
98
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 1);
110
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
111
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
112
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
113
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 1);
99
114
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
100
115
  });
101
116
 
102
- it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icon should be displayed in the response from alternative accordion in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
117
+ it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icon, border, background should be displayed in the response from alternative accordion, correct icon and border should be displayed in the response from correct accordion and a status message with text \'Your answer is incorrect\' should be displayed', () => {
103
118
  gridFillPage.steps.resetQuestionPreview();
104
119
  gridFillPage.steps.selectCellPreviewTab(0, 3);
105
120
  gridFillPage.steps.verifyPreviewScore(0, 20);
106
121
  gridFillPage.steps.switchToGradingView();
107
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
108
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
109
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
110
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
122
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
123
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
124
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
125
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
126
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
127
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 4);
128
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
129
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 4);
111
130
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
112
131
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
113
132
  cy.log('When the user has attempted the question with partially correct options exclusively from the alternative accordion and clicks on \'Check answer\' button, then incorrect icon should be displayed in the partially selected response from alternative accordion, a status message with text \'Your answer is incorrect\' should be displayed')
114
133
  gridFillPage.steps.checkAnswer();
115
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
134
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
135
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
116
136
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
117
137
  });
118
138
 
119
- it('When the user attempts the question partially correct with all the responses correct as per the alternative accordion but one response incomplete, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed in the response from alternative accordion in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
139
+ it('When the user attempts the question partially correct with all the responses correct as per the alternative accordion but one response incomplete, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon, border, background should be displayed in the selected response from alternative accordion, correct icon and border should be displayed in the unselected response from alternative accordion and a status message with text \'Your answer is incorrect\' should be displayed', () => {
120
140
  gridFillPage.steps.resetQuestionPreview();
121
141
  gridFillPage.steps.selectCellPreviewTab(0, 3);
122
142
  gridFillPage.steps.selectCellPreviewTab(0, 4);
123
143
  gridFillPage.steps.verifyPreviewScore(0, 20);
124
144
  gridFillPage.steps.switchToGradingView();
125
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
126
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
127
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
128
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
129
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
145
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
146
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
147
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
148
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
149
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
150
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
151
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
130
152
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
131
153
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
132
154
  cy.log('When the user has attempted the question with partially correct with all the response correct as per the alternative accordion but one response incomplete and clicks on \'Check answer\' button, then correct icon should be displayed in the response from the alternative accordion, incorrect icon should be displayed in the empty response, a status message with text \'Your answer is incorrect\' and correct answer section should not be displayed')
133
155
  gridFillPage.steps.checkAnswer();
134
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 3);
135
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 4);
156
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 3);
157
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 3);
158
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 4);
159
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 4);
136
160
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
137
161
  });
138
162
 
139
- it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed in correct accordion responses, incorrect icon should be displayed in alternative accordion response in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
163
+ it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon, border, background should be displayed in correct accordion responses, incorrect icon should be displayed in alternative accordion response, a status message with text \'Your answer is incorrect\' should be displayed', () => {
140
164
  gridFillPage.steps.resetQuestionPreview();
141
165
  gridFillPage.steps.selectCellPreviewTab(0, 0);
142
166
  gridFillPage.steps.selectCellPreviewTab(0, 4);
143
167
  gridFillPage.steps.verifyPreviewScore(0, 20);
144
168
  gridFillPage.steps.switchToGradingView();
145
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
146
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(0, 4);
147
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
148
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
149
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
169
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
170
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
171
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
172
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 1);
173
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 1);
174
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
175
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
176
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
177
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 4);
178
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 4);
150
179
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
151
180
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
152
181
  cy.log('When the user has attempted the question with equal number of correct responses from correct and alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the response from correct accordion, incorrect icon should be displayed in response from alternative accordion and a status message with text \'Your answer is incorrect\' and correct answer section should not be displayed')
153
182
  gridFillPage.steps.checkAnswer();
154
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 0);
155
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(0, 4);
183
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
184
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 0);
185
+ gridFillPage.steps.verifyIncorrectResponseIcon(0, 4);
186
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(0, 4);
156
187
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
157
188
  });
158
189
 
159
- it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be in the common response in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section and a status message with text \'Your answer is incorrect\' should be displayed', () => {
190
+ it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon, border, background should be in the common response, correct icon should be displayed in unselected response, a status message with text \'Your answer is incorrect\' should be displayed', () => {
160
191
  gridFillPage.steps.resetQuestionPreview();
161
192
  gridFillPage.steps.selectCellPreviewTab(0, 2);
162
193
  gridFillPage.steps.verifyPreviewScore(0, 20);
163
194
  gridFillPage.steps.switchToGradingView();
164
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
165
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
166
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
167
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
195
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
196
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 0);
197
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 0);
198
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
199
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 1);
200
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 1);
201
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
202
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
168
203
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
169
204
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
170
205
  cy.log('When the user has attempted the question with equal number of correct responses from correct and alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in the correct answer responses, no icon should be displayed in unselected response area, a status message with text \'Your answer is incorrect\' should be displayed')
171
206
  gridFillPage.steps.checkAnswer();
172
- gridFillPage.steps.verifyCorrectResponseIconPreviewTab(0, 2);
207
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
208
+ gridFillPage.steps.verifyCorrectResponseBorderAndBackgroundColor(0, 2);
173
209
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
174
210
  });
175
211
 
176
- it('When the user attempts the question incorrectly, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icons should be displayed in all incorrect responses in response grid, correct icon should be displayed in responses from correct answer accordion in correct answer section, a status message with text \'Your answer is incorrect\' should be displayed', () => {
212
+ it('When the user attempts the question incorrectly, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icons should be displayed in all incorrect responses, correct icon, border, background should be displayed in unselected responses from correct answer accordion, a status message with text \'Your answer is incorrect\' should be displayed', () => {
177
213
  gridFillPage.steps.resetQuestionPreview();
178
214
  gridFillPage.steps.selectCellPreviewTab(1, 2);
179
215
  gridFillPage.steps.verifyPreviewScore(0, 20);
180
216
  gridFillPage.steps.switchToGradingView();
181
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(1, 2);
182
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 0);
183
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 1);
184
- gridFillPage.steps.verifyCorrectResponseIconCorrectAnswerSection(0, 2);
217
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 0);
218
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 1);
219
+ gridFillPage.steps.verifyCorrectResponseIcon(0, 2);
220
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 0);
221
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 1);
222
+ gridFillPage.steps.verifyCorrectResponseBorder(0, 2);
223
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 0);
224
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 1);
225
+ gridFillPage.steps.verifyResponseCellHasDefaultBackgroundColor(0, 2);
226
+ gridFillPage.steps.verifyIncorrectResponseIcon(1, 2);
227
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(1, 2);
185
228
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
186
229
  gridFillPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
187
230
  cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icons should be displayed in all incorrect responses and status message with text \'Your answer is incorrect\' should be displayed')
188
231
  gridFillPage.steps.checkAnswer();
189
- gridFillPage.steps.verifyIncorrectResponseIconPreviewTab(1, 2);
232
+ gridFillPage.steps.verifyIncorrectResponseIcon(1, 2);
233
+ gridFillPage.steps.verifyIncorrectResponseBorderAndBackgroundColor(1, 2);
190
234
  gridFillPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
191
235
  });
192
236
  });