itemengine-cypress-automation 1.0.562 → 1.0.564-IEI-7011-cf323ce.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/config-files/ilprod.json +2 -1
- package/cypress/config-files/ilqa.json +2 -1
- package/cypress/config-files/ilstage.json +2 -1
- package/cypress/e2e/ILC/MultipleSelection/allOrNothingBasicForAllViews.smoke.js +168 -1
- package/cypress/e2e/ILC/MultipleSelection/allOrNothingWithAlternativeAnswer.js +86 -0
- package/cypress/e2e/ILC/MultipleSelection/partialDifferentWeightsWithAlternativeAnswer.js +91 -0
- package/cypress/e2e/ILC/MultipleSelection/partialEqualWeightsWithAlternativeAnswer.js +79 -0
- package/cypress/e2e/ILC/SingleSelection/allOrNothingBasicForAllViews.smoke.js +130 -0
- package/cypress/e2e/ILC/SingleSelection/allOrNothingWithAlternativeAnswer.js +16 -0
- package/cypress/pages/components/index.js +1 -0
- package/cypress/pages/components/showAlternativeAnswersComponent.js +169 -0
- package/cypress/pages/multipleSelectionPage.js +3 -1
- package/cypress/pages/singleSelectionPage.js +5 -1
- package/package.json +1 -1
- package/service.yaml +9 -1
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"admin_password": "GzL1Ezjou4wVFL8o",
|
|
13
13
|
"organisation_id": "eb7d4a20-c96c-4852-9b34-7e3231016315",
|
|
14
14
|
"migration_usernme": "ilc-prod-content-user",
|
|
15
|
-
"migration_password": "Oj2kTWQM7ZRmegmS"
|
|
15
|
+
"migration_password": "Oj2kTWQM7ZRmegmS",
|
|
16
|
+
"ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT": "false"
|
|
16
17
|
}
|
|
17
18
|
}
|
|
@@ -12,6 +12,7 @@
|
|
|
12
12
|
"admin_password": "GtOrLiig9surpeW1",
|
|
13
13
|
"organisation_id": "eb7d4a20-c96c-4852-9b34-7e3231016315",
|
|
14
14
|
"migration_usernme": "demo-technical-tester",
|
|
15
|
-
"migration_password": "SXYeokWOoTuwEg2w"
|
|
15
|
+
"migration_password": "SXYeokWOoTuwEg2w",
|
|
16
|
+
"ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT": "true"
|
|
16
17
|
}
|
|
17
18
|
}
|
|
@@ -10,6 +10,7 @@
|
|
|
10
10
|
"scriptSrc": "https://assets-itemengine-staging.imaginelearning.com/content/itemengine-assets-staging/v2/author-loader-nocache.js",
|
|
11
11
|
"admin_username": "demouser-ilc",
|
|
12
12
|
"admin_password": "T6b9FK0pC6Tg8wDz",
|
|
13
|
-
"organisation_id": "eb7d4a20-c96c-4852-9b34-7e3231016315"
|
|
13
|
+
"organisation_id": "eb7d4a20-c96c-4852-9b34-7e3231016315",
|
|
14
|
+
"ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT": "false"
|
|
14
15
|
}
|
|
15
16
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
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', 'Pollution caused by nuclear waste'];
|
|
5
5
|
const grepTags = Cypress.env('grepTags');
|
|
6
|
+
const alternativeAnswerCheck = Cypress.env('ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT');
|
|
6
7
|
let correctAnswerViews = ['Question preview', 'Item preview', 'Grading view'];
|
|
7
8
|
let questionMethodsViews = ['Question preview', 'Grading view'];
|
|
8
9
|
const views = utilities.getViews(correctAnswerViews);
|
|
@@ -203,6 +204,172 @@ describe('Create Item page - Multiple selection: All or nothing ', () => {
|
|
|
203
204
|
});
|
|
204
205
|
});
|
|
205
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
|
+
|
|
206
373
|
views.forEach((view) => {
|
|
207
374
|
describe(`Multiple selection - Manually scored: ${view}`, { tags: 'smoke' }, () => {
|
|
208
375
|
abortEarlySetup();
|
|
@@ -2,6 +2,7 @@ import { multipleSelectionPage } from "../../../pages";
|
|
|
2
2
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
|
3
3
|
import utilities from "../../../support/helpers/utilities";
|
|
4
4
|
const css = Cypress.env('css');
|
|
5
|
+
const alternativeAnswerCheck = Cypress.env('ENABLE_ALTERNATIVE_ANSWER_ENHANCEMENT');
|
|
5
6
|
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', 'Pollution caused by electronic waste', 'Pollution caused by nuclear waste'];
|
|
6
7
|
|
|
7
8
|
describe('Create item page - Multiple selection: All or nothing with alternative answer', () => {
|
|
@@ -48,6 +49,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
48
49
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
49
50
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
50
51
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
52
|
+
if (alternativeAnswerCheck === 'true') {
|
|
53
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
54
|
+
}
|
|
51
55
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
52
56
|
});
|
|
53
57
|
|
|
@@ -65,6 +69,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
65
69
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
66
70
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
67
71
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
72
|
+
if (alternativeAnswerCheck === 'true') {
|
|
73
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
74
|
+
}
|
|
68
75
|
//multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
69
76
|
/*cy.log('When the user has attempted the question with responses from the correct accordion and clicks on \'Check answer\' button, then correct icons should be displayed besides correct responses, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
70
77
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -112,6 +119,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
112
119
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
113
120
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
114
121
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
122
|
+
if (alternativeAnswerCheck === 'true') {
|
|
123
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
124
|
+
}
|
|
115
125
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
116
126
|
/*cy.log('When the user has attempted the question with responses from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
117
127
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -143,6 +153,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
143
153
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
144
154
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
145
155
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
156
|
+
//show alternative answers
|
|
157
|
+
if (alternativeAnswerCheck === 'true') {
|
|
158
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
159
|
+
}
|
|
146
160
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
147
161
|
/*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')
|
|
148
162
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -174,6 +188,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
174
188
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
175
189
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
176
190
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
191
|
+
//show alternative answers
|
|
192
|
+
if (alternativeAnswerCheck === 'true') {
|
|
193
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
194
|
+
}
|
|
177
195
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
178
196
|
/*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')
|
|
179
197
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -204,6 +222,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
204
222
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
205
223
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
206
224
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
225
|
+
//show alternative answers
|
|
226
|
+
if (alternativeAnswerCheck === 'true') {
|
|
227
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
228
|
+
}
|
|
207
229
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
208
230
|
/*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')
|
|
209
231
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -234,6 +256,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
234
256
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
235
257
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
236
258
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
259
|
+
//show alternative answers
|
|
260
|
+
if (alternativeAnswerCheck === 'true') {
|
|
261
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
262
|
+
}
|
|
237
263
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
238
264
|
/*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')
|
|
239
265
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -262,6 +288,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
262
288
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
263
289
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
264
290
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
291
|
+
//show alternative answers
|
|
292
|
+
if (alternativeAnswerCheck === 'true') {
|
|
293
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
294
|
+
}
|
|
265
295
|
// multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
266
296
|
/*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')
|
|
267
297
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -351,6 +381,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
351
381
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
352
382
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
353
383
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
384
|
+
//show alternative answers
|
|
385
|
+
if (alternativeAnswerCheck === 'true') {
|
|
386
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
387
|
+
}
|
|
354
388
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
355
389
|
});
|
|
356
390
|
|
|
@@ -368,6 +402,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
368
402
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
369
403
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
370
404
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
405
|
+
if (alternativeAnswerCheck === 'true') {
|
|
406
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
407
|
+
}
|
|
371
408
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
372
409
|
/*cy.log('When the user has attempted the question with responses from the correct accordion and clicks on \'Check answer\' button, then correct icons should be displayed besides correct responses, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
373
410
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -394,6 +431,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
394
431
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
395
432
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
396
433
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
434
|
+
if (alternativeAnswerCheck === 'true') {
|
|
435
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
436
|
+
}
|
|
397
437
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
398
438
|
/*cy.log('When the user has attempted the question with responses from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
399
439
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -426,6 +466,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
426
466
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
427
467
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
428
468
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
469
|
+
//show alternative answers
|
|
470
|
+
if (alternativeAnswerCheck === 'true') {
|
|
471
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
472
|
+
}
|
|
429
473
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
430
474
|
/*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')
|
|
431
475
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -456,6 +500,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
456
500
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
457
501
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
458
502
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
503
|
+
//show alternative answers
|
|
504
|
+
if (alternativeAnswerCheck === 'true') {
|
|
505
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
506
|
+
}
|
|
459
507
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
460
508
|
/*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')
|
|
461
509
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -486,6 +534,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
486
534
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
487
535
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
488
536
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
537
|
+
//show alternative answers
|
|
538
|
+
if (alternativeAnswerCheck === 'true') {
|
|
539
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
540
|
+
}
|
|
489
541
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
490
542
|
/*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')
|
|
491
543
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -515,6 +567,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
515
567
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
516
568
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
517
569
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
570
|
+
//show alternative answers
|
|
571
|
+
if (alternativeAnswerCheck === 'true') {
|
|
572
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
573
|
+
}
|
|
518
574
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
519
575
|
/*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')
|
|
520
576
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -543,6 +599,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
543
599
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(3);
|
|
544
600
|
multipleSelectionPage.steps.verifyCorrectOptionIconCorrectAnswerSection(4);
|
|
545
601
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
602
|
+
//show alternative answers
|
|
603
|
+
if (alternativeAnswerCheck === 'true') {
|
|
604
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 10);
|
|
605
|
+
}
|
|
546
606
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
547
607
|
/*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')
|
|
548
608
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -593,6 +653,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
593
653
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
594
654
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
595
655
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
656
|
+
//show alternative answers
|
|
657
|
+
if (alternativeAnswerCheck === 'true') {
|
|
658
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 20);
|
|
659
|
+
}
|
|
596
660
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
597
661
|
});
|
|
598
662
|
|
|
@@ -610,6 +674,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
610
674
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
611
675
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
612
676
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
677
|
+
if (alternativeAnswerCheck === 'true') {
|
|
678
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
679
|
+
}
|
|
613
680
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
614
681
|
/*cy.log('When the user has attempted the question with responses from the correct accordion and clicks on \'Check answer\' button, then correct icons should be displayed besides correct responses, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
615
682
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -636,6 +703,9 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
636
703
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleStudentView(5);
|
|
637
704
|
multipleSelectionPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
|
638
705
|
multipleSelectionPage.steps.verifyCorrectAnswerSectionNotExist();
|
|
706
|
+
if (alternativeAnswerCheck === 'true') {
|
|
707
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleNotExists();
|
|
708
|
+
}
|
|
639
709
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
640
710
|
/*cy.log('When the user has attempted the question with responses from the alternative accordion and clicks on \'Check answer\' button, then correct icons should only be displayed besides correct responses from the alternative accordion, and status message \'Your answer is correct\' should be displayed below the question preview')
|
|
641
711
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -667,6 +737,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
667
737
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
668
738
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
669
739
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
740
|
+
//show alternative answers
|
|
741
|
+
if (alternativeAnswerCheck === 'true') {
|
|
742
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 20);
|
|
743
|
+
}
|
|
670
744
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
671
745
|
/*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')
|
|
672
746
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -698,6 +772,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
698
772
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
699
773
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
700
774
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
775
|
+
//show alternative answers
|
|
776
|
+
if (alternativeAnswerCheck === 'true') {
|
|
777
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 20);
|
|
778
|
+
}
|
|
701
779
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
702
780
|
/*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')
|
|
703
781
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -728,6 +806,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
728
806
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
729
807
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
730
808
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
809
|
+
//show alternative answers
|
|
810
|
+
if (alternativeAnswerCheck === 'true') {
|
|
811
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 20);
|
|
812
|
+
}
|
|
731
813
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
732
814
|
/*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')
|
|
733
815
|
multipleSelectionPage.steps.checkAnswer();
|
|
@@ -785,6 +867,10 @@ describe('Create item page - Multiple selection: All or nothing with alternative
|
|
|
785
867
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(3);
|
|
786
868
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(4);
|
|
787
869
|
multipleSelectionPage.steps.verifyCorrectIncorrectIconNotVisibleCorrectAnswerSection(5);
|
|
870
|
+
//show alternative answers
|
|
871
|
+
if (alternativeAnswerCheck === 'true') {
|
|
872
|
+
multipleSelectionPage.steps.verifyShowAlternativeAnswersToggleFunctionality(1, 20);
|
|
873
|
+
}
|
|
788
874
|
multipleSelectionPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
|
789
875
|
/*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')
|
|
790
876
|
multipleSelectionPage.steps.checkAnswer();
|