itemengine-cypress-automation 1.0.131 → 1.0.133-7thMarchFixes-0e78080.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (35) hide show
  1. package/cypress/e2e/ILC/AudioResponseNew/barRecorderStyle.smoke.js +1 -2
  2. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/additionalSettings.js +154 -0
  3. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/dropzoneAlternateAnswerPopup.js +170 -0
  4. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/dropzoneSettings.js +335 -0
  5. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/editTabBasicSection.js +142 -0
  6. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/headerSection.js +76 -0
  7. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +194 -0
  8. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/previewContentsForAllViews.smoke.js +8 -8
  9. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/studentViewSettings.js +341 -0
  10. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/studentViewSettingsForGroupedLayout.js +241 -0
  11. package/cypress/e2e/ILC/FillInTheGapsDropdownNew/allOrNothingForAllView.smoke.js +1 -1
  12. package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/studentViewSettingsForGroupedLayout.js +3 -3
  13. package/cypress/e2e/ILC/Graphing/Scoring/allOrNothingWithAlternativePointsGreaterThanCorrectPoints.js +350 -0
  14. package/cypress/e2e/ILC/Graphing/Scoring/allOrNothingWithCorrectPointsEqualToCorrectPoints.js +356 -0
  15. package/cypress/e2e/ILC/Graphing/Scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +402 -0
  16. package/cypress/e2e/ILC/Graphing/previewContentsForAllViews.smoke.js +4 -4
  17. package/cypress/e2e/ILC/SimpleCalculator/editTabFunctionality.js +242 -0
  18. package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViews.smoke.js +11 -16
  19. package/cypress/e2e/ILC/TextEntryMath/checkAnswerFunctionalityForAllViews.smoke.js +4 -6
  20. package/cypress/e2e/ILC/TextEntryMath/previewContentsForAllViews.smoke.js +3 -4
  21. package/cypress/fixtures/theme/ilc.json +2 -0
  22. package/cypress/pages/components/autoScoredSpecifyCorrectAnswerSection.js +1 -1
  23. package/cypress/pages/components/correctIncorrectAnswerLabelComponent.js +1 -1
  24. package/cypress/pages/components/fillInTheGapsDragAndDropCommonComponents.js +35 -5
  25. package/cypress/pages/components/imageCanvasComponent.js +1 -1
  26. package/cypress/pages/components/index.js +2 -1
  27. package/cypress/pages/components/questionInputFieldComponent.js +31 -0
  28. package/cypress/pages/components/responseAreaSettingsPopupComponent.js +74 -0
  29. package/cypress/pages/drawingResponsePage.js +1 -1
  30. package/cypress/pages/fillInTheGapsDragAndDropPage.js +318 -62
  31. package/cypress/pages/fillInTheGapsOverImageDragAndDropPage.js +2 -26
  32. package/cypress/pages/fillInTheGapsOverImageDropdownPage.js +24 -1
  33. package/cypress/pages/simpleCalculatorPage.js +140 -10
  34. package/cypress/pages/textEntryMathPage.js +3 -2
  35. package/package.json +2 -2
@@ -0,0 +1,241 @@
1
+ import { fillInTheGapsDragAndDropPage } from "../../../pages";
2
+ import abortEarlySetup from "../../../support/helpers/abortEarly";
3
+ let flowers = [['Flower', 'Petals', 'Seed', 'Pollen'],
4
+ ['Leaflet', 'Leaves', 'Leaf', 'Green'],
5
+ ['Stem', 'Branch', 'Trunk', 'Tree'],
6
+ ['Rose', 'Lily', 'Orchid', 'Petals']
7
+ ];
8
+ let groupTitles = ['Group A', 'Group B', 'Group C', 'Group D'];
9
+
10
+ describe('Create Item page - Fill in the gaps with drag and drop: Student view settings for grouped options layout', () => {
11
+ before(() => {
12
+ cy.loginAs('admin');
13
+ });
14
+
15
+ describe('Randomize options - Functionality : Edit tab', () => {
16
+ abortEarlySetup();
17
+ before(() => {
18
+ fillInTheGapsDragAndDropPage.steps.navigateToCreateQuestion('fill in the gaps with drag and drop');
19
+ cy.barsPreLoaderWait();
20
+ fillInTheGapsDragAndDropPage.steps.addResponseArea();
21
+ fillInTheGapsDragAndDropPage.steps.addTextInQuestionInstructionsInputField('Drag and drop options into correct dropzone');
22
+ fillInTheGapsDragAndDropPage.steps.setGroupedOptions();
23
+ });
24
+
25
+ it('When the \'Randomize options\' functionality is disabled, then the group container as well as the options inside the group should be displayed in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
26
+ flowers.forEach((options, index) => {
27
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(index, options);
28
+ });
29
+ });
30
+
31
+ it('When the user enables the \'Randomize options\' functionality, then the group container as well as the options inside the group should be in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
32
+ fillInTheGapsDragAndDropPage.steps.checkRandomizeOptionsCheckbox();
33
+ flowers.forEach((options, index) => {
34
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(index, options);
35
+ });
36
+ });
37
+ });
38
+
39
+ describe('Randomize options - Functionality : Preview tab', () => {
40
+ let optionsArray = [];
41
+ let groupTitleArray = [];
42
+ abortEarlySetup();
43
+ before(() => {
44
+ fillInTheGapsDragAndDropPage.steps.navigateToCreateQuestion('fill in the gaps with drag and drop');
45
+ cy.barsPreLoaderWait();
46
+ fillInTheGapsDragAndDropPage.steps.addTextInQuestionInstructionsInputField('Drag and drop options into correct dropzone');
47
+ fillInTheGapsDragAndDropPage.steps.addResponseArea();
48
+ fillInTheGapsDragAndDropPage.steps.setGroupedOptions();
49
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
50
+ });
51
+
52
+ it('When the \'Randomize options\' functionality is disabled, then the group container as well as the options inside the group should be displayed in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
53
+ groupTitles.forEach((groupTitle, groupIndex) => {
54
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedOptionsTitlePreviewTab(groupIndex, groupTitle);
55
+ })
56
+ flowers.forEach((options, index) => {
57
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(index, options);
58
+ });
59
+ });
60
+
61
+ it('When the user enables the \'Randomize options\' functionality, then the group container as well as the options inside the group should be displayed in a random order', () => {
62
+ fillInTheGapsDragAndDropPage.steps.switchToEditTab();
63
+ fillInTheGapsDragAndDropPage.steps.checkRandomizeOptionsCheckbox();
64
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
65
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizationOfGroupsInPreviewTab(groupTitles);
66
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[0], flowers[0]);
67
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[1], flowers[1]);
68
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[2], flowers[2]);
69
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[3], flowers[3]);
70
+ optionsArray = fillInTheGapsDragAndDropPage.steps.getOptionsArray();
71
+ groupTitleArray = fillInTheGapsDragAndDropPage.steps.getGroupTitleArray();
72
+ });
73
+
74
+ it('When the user switches to \'Edit tab\' and does not modify any question properties, then the order of group containers as well as the options inside the group should not change', () => {
75
+ fillInTheGapsDragAndDropPage.steps.resetQuestionPreview();
76
+ groupTitleArray.forEach((groupTitle, groupIndex) => {
77
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedOptionsTitlePreviewTab(groupIndex, groupTitle);
78
+ });
79
+ for (let index = 0, groupIndex = 0; index < optionsArray.length, groupIndex < 4; index = index + 4, groupIndex++) {
80
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(groupIndex, [optionsArray[index], optionsArray[index + 1], optionsArray[index + 2], optionsArray[index + 3]]);
81
+ }
82
+ });
83
+
84
+ it('When the user switches to \'Edit tab\' and modifies any of question properties, then the order of group containers as well as the options inside the group should change', () => {
85
+ fillInTheGapsDragAndDropPage.steps.switchToEditTab();
86
+ fillInTheGapsDragAndDropPage.steps.allotPoints(5);
87
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
88
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizationOfGroupsInPreviewTab(groupTitles);
89
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[0], flowers[0]);
90
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[1], flowers[1]);
91
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[2], flowers[2]);
92
+ fillInTheGapsDragAndDropPage.steps.verifyRandomizeOptionOrderInGroup(groupTitles[3], flowers[3]);
93
+ fillInTheGapsDragAndDropPage.steps.verifyOptionsAreRerandomized(optionsArray);
94
+ fillInTheGapsDragAndDropPage.steps.verifyGroupsAreRerandomized(groupTitleArray);
95
+ });
96
+
97
+ it('When the user disables the \'Randomize options\' functionality, then the order of group containers as well as the options inside the group should be displayed in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
98
+ fillInTheGapsDragAndDropPage.steps.switchToEditTab();
99
+ fillInTheGapsDragAndDropPage.steps.uncheckRandomizeOptionsCheckbox();
100
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
101
+ flowers.forEach((options, index) => {
102
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(index, options);
103
+ });
104
+ });
105
+ });
106
+
107
+ describe('Allow multiple instances of same draggable option - Functionality : Edit tab', () => {
108
+ abortEarlySetup();
109
+ before(() => {
110
+ fillInTheGapsDragAndDropPage.steps.navigateToCreateQuestion('fill in the gaps with drag and drop');
111
+ cy.barsPreLoaderWait();
112
+ fillInTheGapsDragAndDropPage.steps.addTextInQuestionInstructionsInputField('Drag and drop options into correct dropzone');
113
+ fillInTheGapsDragAndDropPage.steps.addResponseArea();
114
+ fillInTheGapsDragAndDropPage.steps.expandDraggableOptionsLayoutDropdown();
115
+ fillInTheGapsDragAndDropPage.steps.selectOptionFromDraggableOptionsLayoutDropdown('Grouped');
116
+ fillInTheGapsDragAndDropPage.steps.addGroupTitle(groupTitles[0]);
117
+ fillInTheGapsDragAndDropPage.steps.addMultipleOptionFields(2);
118
+ fillInTheGapsDragAndDropPage.steps.addInputToOptionsInputField(flowers[0]);
119
+ fillInTheGapsDragAndDropPage.steps.addGroupWithTitleAndOptionsInDraggableOptionsSection(groupTitles[1], flowers[1]);
120
+ });
121
+
122
+ it('When the \'Allow multiple instances of same draggable option\' functionality is disabled, then on setting correct answer in the dropzone, the draggable options should get removed from the respective group of the options container', () => {
123
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Flower': 0 });
124
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(0, ['Petals', 'Seed', 'Pollen']);
125
+ });
126
+
127
+ it('When the user enables the \'Allow multiple instances of same draggable option\' functionality, then on setting correct answer in the dropzone, the draggable options should persist in respective group of the options container', () => {
128
+ fillInTheGapsDragAndDropPage.steps.checkAllowMultipleInstancesOfSameDraggableOptionCheckbox();
129
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Leaves': 1 });
130
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneSpecifyCorrectAnswerSection(1, ['Leaves']);
131
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(0, flowers[0]);
132
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(1, flowers[1]);
133
+ });
134
+
135
+ it('The user should be able to use the same draggable option for multiple dropzones', () => {
136
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Leaves': 2 });
137
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneSpecifyCorrectAnswerSection(1, ['Leaves']);
138
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneSpecifyCorrectAnswerSection(2, ['Leaves']);
139
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(0, flowers[0]);
140
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(1, flowers[1]);
141
+ });
142
+
143
+ it('When the user removes the draggable option and moves it into the options container, only one option should be displayed in the respective group', () => {
144
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInOptionsContainerInSpecifyCorrectAnswerSection('Leaves');
145
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInOptionsContainerInSpecifyCorrectAnswerSection('Leaves');
146
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(1, flowers[1]);
147
+ });
148
+
149
+ it('When the user disables the \'Allow multiple instances of same draggable option\' functionality, the duplicate answer set as correct answer should get removed from the dropzone and the draggable option should also not exist in the options container of the \'Set correct answer\' section', () => {
150
+ cy.log('Pre step: Setting identical options as correct responses')
151
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Leaves': 1 });
152
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Leaves': 2 });
153
+ fillInTheGapsDragAndDropPage.steps.uncheckAllowMultipleInstancesOfSameDraggableOptionCheckbox();
154
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneSpecifyCorrectAnswerSection(1, ['Leaves']);
155
+ fillInTheGapsDragAndDropPage.steps.verifyDropzoneTextSpecifyCorrectAnswerSection(2, '');
156
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInSpecifyCorrectAnswerSection(1, ['Leaflet', 'Leaf', 'Green']);
157
+ });
158
+ });
159
+
160
+ describe('Allow multiple instances of same draggable option - Functionality: Preview tab', () => {
161
+ abortEarlySetup();
162
+ before(() => {
163
+ fillInTheGapsDragAndDropPage.steps.navigateToCreateQuestion('fill in the gaps with drag and drop');
164
+ cy.barsPreLoaderWait();
165
+ fillInTheGapsDragAndDropPage.steps.addTextInQuestionInstructionsInputField('Drag and drop options into correct dropzone');
166
+ fillInTheGapsDragAndDropPage.steps.addResponseArea();
167
+ fillInTheGapsDragAndDropPage.steps.expandDraggableOptionsLayoutDropdown();
168
+ fillInTheGapsDragAndDropPage.steps.selectOptionFromDraggableOptionsLayoutDropdown('Grouped');
169
+ fillInTheGapsDragAndDropPage.steps.addGroupTitle(groupTitles[0]);
170
+ fillInTheGapsDragAndDropPage.steps.addMultipleOptionFields(2);
171
+ fillInTheGapsDragAndDropPage.steps.addInputToOptionsInputField(flowers[0]);
172
+ fillInTheGapsDragAndDropPage.steps.addGroupWithTitleAndOptionsInDraggableOptionsSection(groupTitles[1], flowers[1]);
173
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
174
+ });
175
+
176
+ it('When the \'Allow multiple instances of same draggable option\' functionality is disabled, then on attempting the question, the draggable options should get removed from the options container', () => {
177
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Flower': 0 });
178
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(0, ['Petals', 'Seed', 'Pollen']);
179
+ });
180
+
181
+ it('When the \'Allow multiple instances of same draggable option\' functionality is enabled, then on attempting the question, the draggable options should persist in the options container', () => {
182
+ fillInTheGapsDragAndDropPage.steps.switchToEditTab();
183
+ fillInTheGapsDragAndDropPage.steps.checkAllowMultipleInstancesOfSameDraggableOptionCheckbox();
184
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
185
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Flower': 0 });
186
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionPreviewTab(0, 'Flower');
187
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(0, flowers[0]);
188
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(1, flowers[1]);
189
+ });
190
+
191
+ it('The user should be able to use the same draggable option for multiple dropzones', () => {
192
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Leaves': 1 });
193
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Leaves': 2 });
194
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneOfPreviewTab(1, ['Leaves']);
195
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneOfPreviewTab(2, ['Leaves']);
196
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(0, flowers[0]);
197
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(1, flowers[1]);
198
+ });
199
+
200
+ it('When the user removes the draggable option and moves it into the options container, only one option should be displayed in the respective group', () => {
201
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInOptionsContainerInPreviewTab('Leaves');
202
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInOptionsContainerInPreviewTab('Leaves');
203
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(1, flowers[1]);
204
+ });
205
+
206
+ it('When the user disables the \'Allow multiple instances of same draggable option\' functionality, then on attempting the question, the draggable options should get removed from the options container', () => {
207
+ fillInTheGapsDragAndDropPage.steps.switchToEditTab();
208
+ fillInTheGapsDragAndDropPage.steps.uncheckAllowMultipleInstancesOfSameDraggableOptionCheckbox();
209
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
210
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Leaves': 1 });
211
+ fillInTheGapsDragAndDropPage.steps.verifyDraggableOptionInDropzoneOfPreviewTab(1, ['Leaves']);
212
+ fillInTheGapsDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(1, ['Leaflet', 'Leaf', 'Green']);
213
+ });
214
+ });
215
+
216
+ describe('Allow multiple instances of same draggable option - Scoring', () => {
217
+ before(() => {
218
+ fillInTheGapsDragAndDropPage.steps.navigateToCreateQuestion('fill in the gaps with drag and drop');
219
+ cy.barsPreLoaderWait();
220
+ fillInTheGapsDragAndDropPage.steps.addTextInQuestionInstructionsInputField('Drag and drop options into correct dropzone');
221
+ fillInTheGapsDragAndDropPage.steps.addResponseArea();
222
+ fillInTheGapsDragAndDropPage.steps.expandDraggableOptionsLayoutDropdown();
223
+ fillInTheGapsDragAndDropPage.steps.selectOptionFromDraggableOptionsLayoutDropdown('Grouped');
224
+ fillInTheGapsDragAndDropPage.steps.addGroupTitle(groupTitles[0]);
225
+ fillInTheGapsDragAndDropPage.steps.addMultipleOptionFields(2);
226
+ fillInTheGapsDragAndDropPage.steps.addInputToOptionsInputField(flowers[0]);
227
+ fillInTheGapsDragAndDropPage.steps.checkAllowMultipleInstancesOfSameDraggableOptionCheckbox();
228
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Flower': 0 });
229
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzoneSpecifyCorrectAnswerSection({ 'Flower': 1 });
230
+ fillInTheGapsDragAndDropPage.steps.allotPoints(5);
231
+ fillInTheGapsDragAndDropPage.steps.switchToPreviewTab();
232
+ });
233
+
234
+ it('When the user has set same answer options in the \'Set correct answer\' section, then the user should be awarded full points on attempting the question with reused options', () => {
235
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Flower': 0 });
236
+ fillInTheGapsDragAndDropPage.steps.clickAndDropOptionInDropzonePreviewTab({ 'Flower': 1 });
237
+ fillInTheGapsDragAndDropPage.steps.verifyPreviewScore(5, 5);
238
+ fillInTheGapsDragAndDropPage.steps.verifyPreviewTabPointsBackgroundForCorrectAnswer();
239
+ });
240
+ });
241
+ });
@@ -162,7 +162,7 @@ describe('Create item page - Fill in the gaps with dropdown: All or nothing ', (
162
162
  gradingViewPage.steps.verifyGradingViewScore(20, 20);
163
163
  };
164
164
  if (view === 'Question preview' || view === 'Item preview') {
165
- fillInTheGapsDropdownPage.steps.verifyPreviewScore(0, 20);
165
+ fillInTheGapsDropdownPage.steps.verifyPreviewScore(20, 20);
166
166
  fillInTheGapsDropdownPage.steps.switchToGradingView();
167
167
  };
168
168
  fillInTheGapsDropdownPage.steps.verifyCorrectOptionIcon(0);
@@ -86,9 +86,9 @@ describe('Create Item page - Fill in the gaps over image - drag and drop: Studen
86
86
  groupTitleArray.forEach((groupTitle, groupIndex) => {
87
87
  fillInTheGapsOverImageDragAndDropPage.steps.verifyGroupedOptionsTitlePreviewTab(groupIndex, groupTitle);
88
88
  });
89
- flowers.forEach((options, index) => {
90
- fillInTheGapsOverImageDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(index, options);
91
- });
89
+ for (let index = 0, groupIndex = 0; index < optionsArray.length, groupIndex < 4; index = index + 4, groupIndex++) {
90
+ fillInTheGapsOverImageDragAndDropPage.steps.verifyGroupedContainerContentsInPreviewTab(groupIndex, [optionsArray[index], optionsArray[index + 1], optionsArray[index + 2], optionsArray[index + 3]]);
91
+ }
92
92
  });
93
93
 
94
94
  it('When the user switches to \'Edit tab\' and modifies any of question properties, then the order of group containers as well as the options inside the group should change', () => {