itemengine-cypress-automation 1.0.564-IEI-7011-cf323ce.0 → 1.0.564-IEI-7011-3998a1c.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.
- package/cypress/e2e/ILC/MultipleSelection/allOrNothingBasicForAllViews.smoke.js +1 -167
- package/cypress/e2e/ILC/MultipleSelection/allOrNothingWithAlternativeAnswer.js +284 -17
- package/cypress/e2e/ILC/MultipleSelection/partialDifferentWeightsWithAlternativeAnswer.js +397 -25
- package/cypress/e2e/ILC/MultipleSelection/partialEqualWeightsWithAlternativeAnswer.js +320 -20
- package/cypress/pages/components/showAlternativeAnswersComponent.js +40 -64
- package/cypress/pages/multipleSelectionPage.js +32 -0
- package/package.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { dialogBoxBase, gradingViewPage, itemPreviewPage, multipleSelectionPage, studentViewPage } from "../../../pages";
|
|
2
2
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
|
3
3
|
import utilities from "../../../support/helpers/utilities";
|
|
4
|
-
const options = ['Pollution caused by treating chemical waste', 'Pollution caused by cement production', 'Pollution caused by methane production', 'Pollution caused by cement and methane production'
|
|
4
|
+
const options = ['Pollution caused by treating chemical waste', 'Pollution caused by cement production', 'Pollution caused by methane production', 'Pollution caused by cement and methane production'];
|
|
5
5
|
const grepTags = Cypress.env('grepTags');
|
|
6
6
|
const alternativeAnswerCheck = Cypress.env('ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT');
|
|
7
7
|
let correctAnswerViews = ['Question preview', 'Item preview', 'Grading view'];
|
|
@@ -204,172 +204,6 @@ describe('Create Item page - Multiple selection: All or nothing ', () => {
|
|
|
204
204
|
});
|
|
205
205
|
});
|
|
206
206
|
|
|
207
|
-
views.forEach((view) => {
|
|
208
|
-
describe(`Multiple selection: all or nothing scoring with alternative answer - ${view}`, { tags: 'smoke' }, () => {
|
|
209
|
-
abortEarlySetup();
|
|
210
|
-
before(() => {
|
|
211
|
-
switch (view) {
|
|
212
|
-
case 'Question preview':
|
|
213
|
-
multipleSelectionPage.steps.navigateToCreateQuestion('multiple selection');
|
|
214
|
-
cy.barsPreLoaderWait();
|
|
215
|
-
multipleSelectionPage.steps.addTextInQuestionInstructionsInputField('Which of the following is the major contributor to increased carbon dioxide levels because of urbanization? Select your answer from the options below.')
|
|
216
|
-
multipleSelectionPage.steps.addOption();
|
|
217
|
-
multipleSelectionPage.steps.addInputToOptionsInputField(options);
|
|
218
|
-
multipleSelectionPage.steps.allotPoints(20);
|
|
219
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInSpecifyCorrectAnswerSection(0);
|
|
220
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInSpecifyCorrectAnswerSection(1);
|
|
221
|
-
multipleSelectionPage.steps.clickOnAddAlternativeAnswerButton();
|
|
222
|
-
multipleSelectionPage.steps.allotPoints(10);
|
|
223
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInSpecifyCorrectAnswerSection(4);
|
|
224
|
-
multipleSelectionPage.steps.switchToPreviewTab();
|
|
225
|
-
break;
|
|
226
|
-
case 'Item preview':
|
|
227
|
-
cy.visit(`/item-engine/demo/edit-item/${utilities.base64Encoding(itemReferenceID)}`);
|
|
228
|
-
itemPreviewPage.steps.switchToPreviewTab();
|
|
229
|
-
break;
|
|
230
|
-
case 'Grading view':
|
|
231
|
-
cy.visit(`/item-engine/demo/render-item/student-view/${utilities.base64Encoding(itemReferenceID)}`);
|
|
232
|
-
break;
|
|
233
|
-
}
|
|
234
|
-
});
|
|
235
|
-
|
|
236
|
-
beforeEach(() => {
|
|
237
|
-
switch (view) {
|
|
238
|
-
case 'Question preview':
|
|
239
|
-
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
240
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectBorderNotExists();
|
|
241
|
-
multipleSelectionPage.steps.resetQuestionPreview();
|
|
242
|
-
break;
|
|
243
|
-
case 'Item preview':
|
|
244
|
-
itemPreviewPage.steps.switchToStudentView();
|
|
245
|
-
itemPreviewPage.steps.resetQuestionPreview();
|
|
246
|
-
break;
|
|
247
|
-
case 'Grading view':
|
|
248
|
-
cy.visit(`/item-engine/demo/render-item/student-view/${utilities.base64Encoding(itemReferenceID)}`);
|
|
249
|
-
break;
|
|
250
|
-
}
|
|
251
|
-
});
|
|
252
|
-
|
|
253
|
-
if (view === 'Question preview') {
|
|
254
|
-
after(() => {
|
|
255
|
-
multipleSelectionPage.steps.clickOnSaveQuestionButton();
|
|
256
|
-
utilities.verifyElementVisibilityState(itemPreviewPage.referenceID(), 'visible');
|
|
257
|
-
itemReferenceID = itemPreviewPage.steps.getItemReferenceID();
|
|
258
|
-
});
|
|
259
|
-
};
|
|
260
|
-
|
|
261
|
-
it('When the user selects \'Grading\' view without attempting the question, no icons should be displayed beside unattempted responses and correct answer should be displayed in correct answer section', () => {
|
|
262
|
-
if (view === 'Grading view') {
|
|
263
|
-
studentViewPage.steps.submitResponse();
|
|
264
|
-
utilities.verifyElementVisibilityState(dialogBoxBase.dialogBox(), 'visible');
|
|
265
|
-
studentViewPage.steps.clickOnGoToGradingViewButton();
|
|
266
|
-
gradingViewPage.steps.verifyGradingViewScore(0, 20);
|
|
267
|
-
}
|
|
268
|
-
if (view === 'Question preview' || view === 'Item preview') {
|
|
269
|
-
multipleSelectionPage.steps.switchToGradingView();
|
|
270
|
-
multipleSelectionPage.steps.verifyPreviewScore(0, 20);
|
|
271
|
-
}
|
|
272
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(0);
|
|
273
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(1);
|
|
274
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(2);
|
|
275
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(3);
|
|
276
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabelNotExist();
|
|
277
|
-
//correct answer section
|
|
278
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(0);
|
|
279
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(1);
|
|
280
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(2);
|
|
281
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
282
|
-
if (alternativeAnswerCheck === 'true') {
|
|
283
|
-
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
284
|
-
}
|
|
285
|
-
});
|
|
286
|
-
|
|
287
|
-
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 besides all incorrect responses, no icons should be displayed besides unattempted responses options and status message \'Your answer is incorrect\' should be displayed below the question preview and correct answer should be displayed in correct answer section', () => {
|
|
288
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(2);
|
|
289
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(3);
|
|
290
|
-
if (view === 'Grading view') {
|
|
291
|
-
studentViewPage.steps.submitResponse();
|
|
292
|
-
utilities.verifyElementVisibilityState(dialogBoxBase.dialogBox(), 'visible');
|
|
293
|
-
studentViewPage.steps.clickOnGoToGradingViewButton();
|
|
294
|
-
gradingViewPage.steps.verifyGradingViewScore(0, 20);
|
|
295
|
-
}
|
|
296
|
-
if (view === 'Question preview' || view === 'Item preview') {
|
|
297
|
-
multipleSelectionPage.steps.verifyPreviewScore(0, 20);
|
|
298
|
-
multipleSelectionPage.steps.switchToGradingView();
|
|
299
|
-
}
|
|
300
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(0);
|
|
301
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(1);
|
|
302
|
-
multipleSelectionPage.steps.verifyIncorrectOptionIconStudentView(2);
|
|
303
|
-
multipleSelectionPage.steps.verifyIncorrectOptionIconStudentView(3);
|
|
304
|
-
//correct answer section
|
|
305
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(0);
|
|
306
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(1);
|
|
307
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(2);
|
|
308
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
309
|
-
if (alternativeAnswerCheck === 'true') {
|
|
310
|
-
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
311
|
-
}
|
|
312
|
-
});
|
|
313
|
-
|
|
314
|
-
it('When the user attempts the question partially correct, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icons should be displayed besides the correct responses, incorrect icons should be displayed beside the incorrect responses and no icon should be displayed besides unattempted options, and status message \'Your answer is incorrect\' should be displayed below the question preview and correct answer should be displayed in correct answer section', () => {
|
|
315
|
-
if (view === 'Grading view') {
|
|
316
|
-
studentViewPage.steps.clearResponses();
|
|
317
|
-
}
|
|
318
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(0);
|
|
319
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(2);
|
|
320
|
-
if (view === 'Grading view') {
|
|
321
|
-
studentViewPage.steps.submitResponse();
|
|
322
|
-
utilities.verifyElementVisibilityState(dialogBoxBase.dialogBox(), 'exist');
|
|
323
|
-
studentViewPage.steps.clickOnGoToGradingViewButton();
|
|
324
|
-
gradingViewPage.steps.verifyGradingViewScore(0, 20);
|
|
325
|
-
}
|
|
326
|
-
if (view === 'Question preview' || view === 'Item preview') {
|
|
327
|
-
multipleSelectionPage.steps.verifyPreviewScore(0, 20);
|
|
328
|
-
multipleSelectionPage.steps.switchToGradingView();
|
|
329
|
-
}
|
|
330
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconStudentView(0);
|
|
331
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(1);
|
|
332
|
-
multipleSelectionPage.steps.verifyIncorrectOptionIconStudentView(2);
|
|
333
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(3);
|
|
334
|
-
//correct answer section
|
|
335
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(0);
|
|
336
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(1);
|
|
337
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(2);
|
|
338
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
339
|
-
if (alternativeAnswerCheck === 'true') {
|
|
340
|
-
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
341
|
-
}
|
|
342
|
-
});
|
|
343
|
-
|
|
344
|
-
it(`${view}: Multiple selection - When user attempts the question correctly, the user should be awarded full points and on switching to \'Grading\' view, then correct icons should be displayed beside all the correct responses, and status message \'Your answer is correct\'should be displayed below the question preview and correct answer section should not be displayed`, () => {
|
|
345
|
-
if (view === 'Grading view') {
|
|
346
|
-
studentViewPage.steps.clearResponses();
|
|
347
|
-
}
|
|
348
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(0);
|
|
349
|
-
multipleSelectionPage.steps.checkOptionsCheckboxInPreviewTab(1);
|
|
350
|
-
if (view === 'Grading view') {
|
|
351
|
-
studentViewPage.steps.submitResponse();
|
|
352
|
-
utilities.verifyElementVisibilityState(dialogBoxBase.dialogBox(), 'visible');
|
|
353
|
-
studentViewPage.steps.clickOnGoToGradingViewButton();
|
|
354
|
-
gradingViewPage.steps.verifyGradingViewScore(20, 20);
|
|
355
|
-
}
|
|
356
|
-
if (view === 'Question preview' || view === 'Item preview') {
|
|
357
|
-
multipleSelectionPage.steps.verifyPreviewScore(20, 20);
|
|
358
|
-
multipleSelectionPage.steps.switchToGradingView();
|
|
359
|
-
}
|
|
360
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconStudentView(0);
|
|
361
|
-
multipleSelectionPage.steps.verifyCorrectOptionIconStudentView(1);
|
|
362
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(2);
|
|
363
|
-
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(3);
|
|
364
|
-
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
365
|
-
if (alternativeAnswerCheck === 'true') {
|
|
366
|
-
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
367
|
-
}
|
|
368
|
-
cy.eyesCheckWindow(`Multiple selection ${view} view - Attempting the question correctly`);
|
|
369
|
-
});
|
|
370
|
-
});
|
|
371
|
-
});
|
|
372
|
-
|
|
373
207
|
views.forEach((view) => {
|
|
374
208
|
describe(`Multiple selection - Manually scored: ${view}`, { tags: 'smoke' }, () => {
|
|
375
209
|
abortEarlySetup();
|
|
@@ -50,7 +50,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
50
50
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
51
51
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
52
52
|
if (alternativeAnswerCheck === 'true') {
|
|
53
|
-
multipleSelectionPage.steps.
|
|
53
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
54
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
55
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
56
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
57
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
58
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
59
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
60
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
61
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
62
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
63
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
64
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
65
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
66
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
67
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
68
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
54
69
|
}
|
|
55
70
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
56
71
|
});
|
|
@@ -155,7 +170,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
155
170
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
156
171
|
//show alternative answers
|
|
157
172
|
if (alternativeAnswerCheck === 'true') {
|
|
158
|
-
multipleSelectionPage.steps.
|
|
173
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
174
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
175
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
176
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
177
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
178
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
179
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
180
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
181
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
182
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
183
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
184
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
185
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
186
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
187
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
188
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
159
189
|
}
|
|
160
190
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
161
191
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the correct accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the correct accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -190,7 +220,16 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
190
220
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
191
221
|
//show alternative answers
|
|
192
222
|
if (alternativeAnswerCheck === 'true') {
|
|
193
|
-
multipleSelectionPage.steps.
|
|
223
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
224
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
225
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
226
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
227
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
228
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
229
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
230
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
231
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
232
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
194
233
|
}
|
|
195
234
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
196
235
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -224,7 +263,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
224
263
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
225
264
|
//show alternative answers
|
|
226
265
|
if (alternativeAnswerCheck === 'true') {
|
|
227
|
-
multipleSelectionPage.steps.
|
|
266
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
267
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
268
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
269
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
270
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
271
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
272
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
273
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
274
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
275
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
276
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
277
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
278
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
279
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
280
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
281
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
228
282
|
}
|
|
229
283
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
230
284
|
/*cy.log('When the user has attempted the question with equal number of correct responses from correct accordion and alternative accordion, then correct icon should be displayed besides correct accordion answer responses, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides alternative accordion answer responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -258,7 +312,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
258
312
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
259
313
|
//show alternative answers
|
|
260
314
|
if (alternativeAnswerCheck === 'true') {
|
|
261
|
-
multipleSelectionPage.steps.
|
|
315
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
316
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
317
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
318
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
319
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
320
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
321
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
322
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
323
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
324
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
325
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
326
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
327
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
328
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
329
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
330
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
262
331
|
}
|
|
263
332
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
264
333
|
/*cy.log('When the user has attempted the question with the common response between correct accordion and alternative accordion, and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the correct accordion, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -290,7 +359,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
290
359
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
291
360
|
//show alternative answers
|
|
292
361
|
if (alternativeAnswerCheck === 'true') {
|
|
293
|
-
multipleSelectionPage.steps.
|
|
362
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
363
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
364
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
365
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
366
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
367
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
368
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
369
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
370
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
371
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
372
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
373
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
374
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
375
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
376
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
377
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
294
378
|
}
|
|
295
379
|
// multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
296
380
|
/*cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icons should only be displayed besides incorrect responses, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -383,7 +467,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
383
467
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
384
468
|
//show alternative answers
|
|
385
469
|
if (alternativeAnswerCheck === 'true') {
|
|
386
|
-
multipleSelectionPage.steps.
|
|
470
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
471
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
472
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
473
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
474
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
475
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
476
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
477
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
478
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
479
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
480
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
481
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
482
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
483
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
484
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
485
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
387
486
|
}
|
|
388
487
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
389
488
|
});
|
|
@@ -468,7 +567,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
468
567
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
469
568
|
//show alternative answers
|
|
470
569
|
if (alternativeAnswerCheck === 'true') {
|
|
471
|
-
multipleSelectionPage.steps.
|
|
570
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
571
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
572
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
573
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
574
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
575
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
576
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
577
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
578
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
579
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
580
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
581
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
582
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
583
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
584
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
585
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
472
586
|
}
|
|
473
587
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
474
588
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the correct accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the correct accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -502,7 +616,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
502
616
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
503
617
|
//show alternative answers
|
|
504
618
|
if (alternativeAnswerCheck === 'true') {
|
|
505
|
-
multipleSelectionPage.steps.
|
|
619
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
620
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
621
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
622
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
623
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
624
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
625
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
626
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
627
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
628
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
629
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
630
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
631
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
632
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
633
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
634
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
506
635
|
}
|
|
507
636
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
508
637
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -536,7 +665,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
536
665
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
537
666
|
//show alternative answers
|
|
538
667
|
if (alternativeAnswerCheck === 'true') {
|
|
539
|
-
multipleSelectionPage.steps.
|
|
668
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
669
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
670
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
671
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
672
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
673
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
674
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
675
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
676
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
677
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
678
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
679
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
680
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
681
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
682
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
683
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
540
684
|
}
|
|
541
685
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
542
686
|
/*cy.log('When the user has attempted the question with equal number of correct responses from correct accordion and alternative accordion, then correct icon should be displayed besides alternative accordion answer responses, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides correct accordion answer responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -569,7 +713,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
569
713
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
570
714
|
//show alternative answers
|
|
571
715
|
if (alternativeAnswerCheck === 'true') {
|
|
572
|
-
multipleSelectionPage.steps.
|
|
716
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
717
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
718
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
719
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
720
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
721
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
722
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
723
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
724
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
725
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
726
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
727
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
728
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
729
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
730
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
731
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
573
732
|
}
|
|
574
733
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
575
734
|
/*cy.log('When the user has attempted the question with the common response between correct accordion and alternative accordion, and clicks on \'Check answer\' button, then correct icons should only be displayed besides the common response, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -601,7 +760,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
601
760
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
602
761
|
//show alternative answers
|
|
603
762
|
if (alternativeAnswerCheck === 'true') {
|
|
604
|
-
multipleSelectionPage.steps.
|
|
763
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
764
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
765
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
766
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
767
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
768
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
769
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
770
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(10 points)');
|
|
771
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(0);
|
|
772
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(1);
|
|
773
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
774
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(3);
|
|
775
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(4);
|
|
776
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
777
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
778
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
605
779
|
}
|
|
606
780
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
607
781
|
/*cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icons should be displayed besides incorrect responses, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -655,7 +829,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
655
829
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
656
830
|
//show alternative answers
|
|
657
831
|
if (alternativeAnswerCheck === 'true') {
|
|
658
|
-
multipleSelectionPage.steps.
|
|
832
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
833
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
834
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
835
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
836
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
837
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
838
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
839
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
840
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
841
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
842
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
843
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
844
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
845
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
846
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
847
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
659
848
|
}
|
|
660
849
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
661
850
|
});
|
|
@@ -739,7 +928,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
739
928
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
740
929
|
//show alternative answers
|
|
741
930
|
if (alternativeAnswerCheck === 'true') {
|
|
742
|
-
multipleSelectionPage.steps.
|
|
931
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
932
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
933
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
934
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
935
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
936
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
937
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
938
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
939
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
940
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
941
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
942
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
943
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
944
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
945
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
946
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
743
947
|
}
|
|
744
948
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
745
949
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the correct accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the correct accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -774,7 +978,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
774
978
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
775
979
|
//show alternative answers
|
|
776
980
|
if (alternativeAnswerCheck === 'true') {
|
|
777
|
-
multipleSelectionPage.steps.
|
|
981
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
982
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
983
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
984
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
985
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
986
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
987
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
988
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
989
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
990
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
991
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
992
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
993
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
994
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
995
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
996
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
778
997
|
}
|
|
779
998
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
780
999
|
/*cy.log('When the user has attempted the question with partially correct responses exclusively from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides the incorrect responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -808,7 +1027,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
808
1027
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
809
1028
|
//show alternative answers
|
|
810
1029
|
if (alternativeAnswerCheck === 'true') {
|
|
811
|
-
multipleSelectionPage.steps.
|
|
1030
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
1031
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
1032
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
1033
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
1034
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
1035
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1036
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
1037
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
1038
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
1039
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
1040
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
1041
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
1042
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
1043
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
1044
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1045
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
812
1046
|
}
|
|
813
1047
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
814
1048
|
/*cy.log('When the user has attempted the question with equal number of correct responses from correct accordion and alternative accordion, then correct icon should be displayed besides correct accordion answer responses, correct icons should not be displayed besides unattempted correct options, incorrect icon should be displayed besides alternative accordion answer responses, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
@@ -839,6 +1073,24 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
839
1073
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
840
1074
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
841
1075
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
1076
|
+
if (alternativeAnswerCheck === 'true') {
|
|
1077
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
1078
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
1079
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
1080
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
1081
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
1082
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1083
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
1084
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
1085
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
1086
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
1087
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
1088
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
1089
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
1090
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
1091
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1092
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
1093
|
+
}
|
|
842
1094
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
843
1095
|
/*cy.log('When the user has attempted the question with the common response between correct accordion and alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the correct accordion, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|
|
844
1096
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -869,7 +1121,22 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
869
1121
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
870
1122
|
//show alternative answers
|
|
871
1123
|
if (alternativeAnswerCheck === 'true') {
|
|
872
|
-
multipleSelectionPage.steps.
|
|
1124
|
+
multipleSelectionPage.steps.verifyCorrectAnswersLabelAndPointVisible('(20 points)');
|
|
1125
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleExists();
|
|
1126
|
+
multipleSelectionPage.steps.disableShowAlternativeAnswersToggle();
|
|
1127
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
1128
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersSectionNotExist();
|
|
1129
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1130
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleChecked();
|
|
1131
|
+
multipleSelectionPage.steps.verifyAlternativeAnswersLabelAndPointVisible(1, '(20 points)');
|
|
1132
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(2);
|
|
1133
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(3);
|
|
1134
|
+
multipleSelectionPage.steps.verifyCorrectOptionIconAlternativeAnswerSection(4);
|
|
1135
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(0);
|
|
1136
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(1);
|
|
1137
|
+
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleAlternativeAnswerSection(5);
|
|
1138
|
+
multipleSelectionPage.steps.clickShowAlternativeAnswersToggle();
|
|
1139
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleUnchecked();
|
|
873
1140
|
}
|
|
874
1141
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
875
1142
|
/*cy.log('When the user has attempted the question incorrectly and clicks on \'Check answer\' button, then incorrect icons should only be displayed besides incorrect responses, correct icons should not be displayed besides unattempted correct options, and status message \'Your answer is incorrect\' should be displayed below the question preview')
|