itemengine-cypress-automation 1.0.576-IEI-7079-7fbe573.0 → 1.0.576-IEI-7079-0591b8d.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.
@@ -1,6 +1,8 @@
1
1
  import { chartsDotPlotPage } from "../../../../pages";
2
2
  import abortEarlySetup from "../../../../support/helpers/abortEarly";
3
3
 
4
+ const alternativeAnswerCheck = Cypress.env('ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT');
5
+
4
6
  describe('Create item page - Charts - Dot plot: Partial different with alternative answers', () => {
5
7
  before(() => {
6
8
  cy.loginAs('admin');
@@ -83,6 +85,9 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
83
85
  chartsDotPlotPage.steps.verifyEmptyDotColumnPreviewTab({ point: 6, min: 1, interval: 1 });
84
86
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
85
87
  chartsDotPlotPage.steps.verifyCorrectAnswerSectionNotExists();
88
+ if (alternativeAnswerCheck === 'true') {
89
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleNotExists();
90
+ }
86
91
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
87
92
  /*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 dot column attempted correctly, correct/incorrect status message and correct answer section should not be displayed')
88
93
  chartsDotPlotPage.steps.checkAnswer();
@@ -112,6 +117,9 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
112
117
  chartsDotPlotPage.steps.verifyEmptyDotColumnPreviewTab({ point: 6, min: 1, interval: 1 });
113
118
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
114
119
  chartsDotPlotPage.steps.verifyCorrectAnswerSectionNotExists();
120
+ if (alternativeAnswerCheck === 'true') {
121
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleNotExists();
122
+ }
115
123
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
116
124
  /*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 dot column attempted correctly, correct/incorrect status message and correct answer section should not be displayed')
117
125
  chartsDotPlotPage.steps.checkAnswer();
@@ -147,6 +155,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
147
155
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
148
156
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
149
157
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
158
+ //alternative answer
159
+ if (alternativeAnswerCheck === 'true') {
160
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 4 pts, 2 pts)');
161
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
162
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
163
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
164
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
165
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
166
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
167
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 4 pts, 2 pts, 6 pts, 5 pts, 2 pts, 1 pt)');
168
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
169
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
170
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
171
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
172
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
173
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
174
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
175
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
176
+ }
150
177
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
151
178
  /*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 dot column set correctly from correct accordion, incorrect icon should be displayed in dot column set incorrectly, correct/incorrect status message and correct answer section should not be displayed')
152
179
  chartsDotPlotPage.steps.checkAnswer();
@@ -182,6 +209,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
182
209
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
183
210
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
184
211
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
212
+ //alternative answer
213
+ if (alternativeAnswerCheck === 'true') {
214
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 4 pts, 2 pts)');
215
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
216
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
217
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
218
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
219
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
220
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
221
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 4 pts, 2 pts, 6 pts, 5 pts, 2 pts, 1 pt)');
222
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
223
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
224
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
225
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
226
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
227
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
228
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
229
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
230
+ }
185
231
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
186
232
  /*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 dot column set correctly from alternate accordion, incorrect icon should be displayed in dot column set incorrectly, correct/incorrect status message and correct answer section should not be displayed')
187
233
  chartsDotPlotPage.steps.checkAnswer();
@@ -217,6 +263,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
217
263
  chartsDotPlotPage.steps.verifyCorrectDotColumnCorrectAnswerSection({ point: 4, min: 1, interval: 1 });
218
264
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
219
265
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
266
+ //alternative answer
267
+ if (alternativeAnswerCheck === 'true') {
268
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 4 pts, 2 pts)');
269
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
270
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
271
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
272
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
273
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
274
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
275
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 4 pts, 2 pts, 6 pts, 5 pts, 2 pts, 1 pt)');
276
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
277
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
278
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
279
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
280
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
281
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
282
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
283
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
284
+ }
220
285
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
221
286
  /* 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 dot column set correctly, incorrect icon should be displayed in dot column set incorrectly, correct/incorrect status message and correct answer section should not be displayed')
222
287
  chartsDotPlotPage.steps.checkAnswer();
@@ -251,6 +316,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
251
316
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
252
317
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
253
318
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
319
+ //alternative answer
320
+ if (alternativeAnswerCheck === 'true') {
321
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 4 pts, 2 pts)');
322
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
323
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
324
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
325
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
326
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
327
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
328
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 4 pts, 2 pts, 6 pts, 5 pts, 2 pts, 1 pt)');
329
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
330
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
331
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
332
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
333
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
334
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
335
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
336
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
337
+ }
254
338
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
255
339
  /* cy.log('When the user has attempted the question with the common response between correct and alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in common dot column set correctly, incorrect icon should be displayed in dot column set incorrectly, correct/incorrect status message and correct answer section should not be displayed')
256
340
  chartsDotPlotPage.steps.checkAnswer();
@@ -287,6 +371,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
287
371
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
288
372
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
289
373
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
374
+ //alternative answer
375
+ if (alternativeAnswerCheck === 'true') {
376
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 4 pts, 2 pts)');
377
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
378
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
379
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
380
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
381
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
382
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
383
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 4 pts, 2 pts, 6 pts, 5 pts, 2 pts, 1 pt)');
384
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
385
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
386
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
387
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
388
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
389
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
390
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
391
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
392
+ }
290
393
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
291
394
  /*cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icon should be displayed in dot column set incorrectly, correct/incorrect status message and correct answer section should not be displayed')
292
395
  chartsDotPlotPage.steps.checkAnswer();
@@ -2,6 +2,8 @@ import { chartsDotPlotPage } from "../../../../pages";
2
2
  import abortEarlySetup from "../../../../support/helpers/abortEarly";
3
3
  const css = Cypress.env('css');
4
4
 
5
+ const alternativeAnswerCheck = Cypress.env('ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT');
6
+
5
7
  describe('Create item page - Charts - Dot plot: Partial different with alternative answers', () => {
6
8
  before(() => {
7
9
  cy.loginAs('admin');
@@ -84,6 +86,9 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
84
86
  chartsDotPlotPage.steps.verifyEmptyDotColumnPreviewTab({ point: 6, min: 1, interval: 1 });
85
87
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
86
88
  chartsDotPlotPage.steps.verifyCorrectAnswerSectionNotExists();
89
+ if (alternativeAnswerCheck === 'true') {
90
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleNotExists();
91
+ }
87
92
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
88
93
  /*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 dot column attempted correctly, a status message and correct answer section should not be displayed')
89
94
  chartsDotPlotPage.steps.checkAnswer();
@@ -113,6 +118,9 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
113
118
  chartsDotPlotPage.steps.verifyEmptyDotColumnPreviewTab({ point: 6, min: 1, interval: 1 });
114
119
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
115
120
  chartsDotPlotPage.steps.verifyCorrectAnswerSectionNotExists();
121
+ if (alternativeAnswerCheck === 'true') {
122
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleNotExists();
123
+ }
116
124
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
117
125
  /*(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 dot column attempted correctly, a status message and correct answer section should not be displayed')
118
126
  chartsDotPlotPage.steps.checkAnswer();
@@ -148,6 +156,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
148
156
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
149
157
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
150
158
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
159
+ //alternative answer
160
+ if (alternativeAnswerCheck === 'true') {
161
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
162
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
163
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
164
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
165
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
166
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
167
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
168
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
169
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
170
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
171
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
172
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
173
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
174
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
175
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
176
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
177
+ }
151
178
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
152
179
  /*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 dot column responses from correct accordion and incorrect icon should be displayed in dot column set incorrectly, a status message should not be displayed and correct answer section should not be displayed')
153
180
  chartsDotPlotPage.steps.checkAnswer();
@@ -183,6 +210,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
183
210
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
184
211
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
185
212
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
213
+ //alternative answer
214
+ if (alternativeAnswerCheck === 'true') {
215
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
216
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
217
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
218
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
219
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
220
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
221
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
222
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
223
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
224
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
225
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
226
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
227
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
228
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
229
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
230
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
231
+ }
186
232
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
187
233
  /*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 dot column attempted correctly from alternate accordion, incorrect icon should be displayed in dot column set incorrectly, a status message should not be displayed and correct answer section should not be displayed')
188
234
  chartsDotPlotPage.steps.checkAnswer();
@@ -218,6 +264,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
218
264
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
219
265
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
220
266
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
267
+ //alternative answer
268
+ if (alternativeAnswerCheck === 'true') {
269
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
270
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
271
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
272
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
273
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
274
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
275
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
276
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
277
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
278
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
279
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
280
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
281
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
282
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
283
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
284
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
285
+ }
221
286
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
222
287
  /*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 dot column from the correct accordion, incorrect icon should be displayed in the dot column from the alternative accordion and, a status message should not be displayed and correct answer section should not be displayed')
223
288
  chartsDotPlotPage.steps.checkAnswer();
@@ -253,6 +318,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
253
318
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
254
319
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
255
320
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
321
+ //alternative answer
322
+ if (alternativeAnswerCheck === 'true') {
323
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
324
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
325
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
326
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
327
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
328
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
329
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
330
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
331
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
332
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
333
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
334
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
335
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
336
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
337
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
338
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
339
+ }
256
340
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
257
341
  /*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 dot column attempted correctly from correct accordion, incorrect icon should be displayed in dot column set incorrectly from the alternative accordion, a status message should not be displayed and correct answer section should not be displayed')
258
342
  chartsDotPlotPage.steps.checkAnswer();
@@ -287,6 +371,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
287
371
  chartsDotPlotPage.steps.verifyCorrectDotColumnCorrectAnswerSection({ point: 4, min: 1, interval: 1 });
288
372
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
289
373
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
374
+ //alternative answer
375
+ if (alternativeAnswerCheck === 'true') {
376
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
377
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
378
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
379
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
380
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
381
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
382
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
383
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
384
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
385
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
386
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
387
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
388
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
389
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
390
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
391
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
392
+ }
290
393
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
291
394
  /*cy.log('When the user has attempted the question with common response of correct responses from correct and alternative accordion and clicks on \'Check answer\' button, then correct icon should be displayed in common dot column attempted correctly, incorrect icon should be displayed in dot column set incorrectly, a status message should not be displayed and correct answer section should not be displayed')
292
395
  chartsDotPlotPage.steps.checkAnswer();
@@ -323,6 +426,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
323
426
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
324
427
  chartsDotPlotPage.steps.verifyEmptyDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1});
325
428
  chartsDotPlotPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
429
+ //alternative answer
430
+ if (alternativeAnswerCheck === 'true') {
431
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 3 pts, 4 pts, 5 pts, 2 pts, 3 pts, 3 pts)');
432
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
433
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
434
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
435
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
436
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
437
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
438
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 2 pts, 3 pts, 3 pts, 1 pts, 2 pts, 2 pts)');
439
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
440
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
441
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
442
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
443
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
444
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
445
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
446
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
447
+ }
326
448
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
327
449
  /*cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icon should be displayed in dot column attempted incorrectly, a status message should not be displayed and correct answer section should not be displayed')
328
450
  chartsDotPlotPage.steps.checkAnswer();
@@ -379,6 +501,25 @@ describe('Create item page - Charts - Dot plot: Partial different with alternati
379
501
  chartsDotPlotPage.steps.verifyCorrectDotColumnCorrectAnswerSection({ point: 4, min: 1, interval: 1 });
380
502
  chartsDotPlotPage.steps.verifyCorrectDotColumnCorrectAnswerSection({ point: 5, min: 1, interval: 1 });
381
503
  chartsDotPlotPage.steps.verifyCorrectDotColumnCorrectAnswerSection({ point: 6, min: 1, interval: 1 });
504
+ //alternative answer
505
+ if (alternativeAnswerCheck === 'true') {
506
+ chartsDotPlotPage.steps.verifyCorrectAnswersLabelAndPointVisible('(Points per response in order of appearance - 1.5 pts, 2 pts, 3 pts, 3 pts, 3.5 pts, 18 pts)');
507
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleExists();
508
+ chartsDotPlotPage.steps.disableShowAlternativeAnswersToggle();
509
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
510
+ chartsDotPlotPage.steps.verifyAlternativeAnswersSectionNotExist();
511
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
512
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleChecked();
513
+ chartsDotPlotPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(Points per response in order of appearance - 0.5 pts, 1 pts, 3 pts, 2 pts, 2.5 pts, 16 pts)');
514
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 1, min: 1, interval: 1 });
515
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 2, min: 1, interval: 1 });
516
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 3, min: 1, interval: 1 });
517
+ chartsDotPlotPage.steps.verifyCorrectDotColumnAlternateAnswerSection({ point: 4, min: 1, interval: 1 });
518
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 5, min: 1, interval: 1 });
519
+ chartsDotPlotPage.steps.verifyEmptyDotColumnAlternateAnswerSection({ point: 6, min: 1, interval: 1 });
520
+ chartsDotPlotPage.steps.clickShowAlternativeAnswersToggle();
521
+ chartsDotPlotPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
522
+ }
382
523
  chartsDotPlotPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
383
524
  /*cy.log('When user attempts the question correctly and clicks on the \'Check answer\' button, correct icons icons should be displayed beside the correct responses from the correct accordion, incorrect icons icons should be displayed beside the incorrectly answered responses, correct/incorrect answer label should not be displayed, correct answer section should not be displayed')
384
525
  chartsDotPlotPage.steps.checkAnswer();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.576-IEI-7079-7fbe573.0",
3
+ "version": "1.0.576-IEI-7079-0591b8d.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {