itemengine-cypress-automation 1.0.29 → 1.0.31
Sign up to get free protection for your applications and to get access to all the features.
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesAdditionalSettings.js +963 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesClickAndDrop.js +669 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesEditTabScoringTypes.js +205 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedOptionsAllOrNothing.js +143 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedOptionsPartialScoreForEachCell.js +145 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedOptionsPartialScoreForEachResponse.js +141 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedOptionsTotalScoreDividedBetweenCell.js +165 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedOptionsTotalScoreDividedBetweenResponses.js +420 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesGroupedSetCorrectAnswerCheckboxes.js +266 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesHeaderSection.js +83 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesManuallyAndNonScored.js +184 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesResponseOptionsSection.js +112 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesRowsAndCategoriesSection.js +569 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesSetCorrectAnswerSection.js +130 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardAllOrNothing.js +186 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardPartialScoreForEachCell.js +145 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardPartialScoreForEachResponse.js +140 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardSetCorrectAnswerCheckboxes.js +234 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardTotalScoreDividedBetweenCell.js +165 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesStandardTotalScoreDividedBetweenResponse.js +420 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesSwitchingCases.js +45 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropAdditionalSettings.js +0 -292
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropAdditionalSettingsResponseAccordion.js +299 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsAllOrNothingScoring.js +1 -180
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsAllOrNothingWithAlternateAnswer.js +186 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsPartialDifferentWeightsScoring.js +0 -87
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsPartialDifferentWeightsWithAlternateAnswer.js +95 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsPartialEqualWeightsScoring.js +0 -86
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedOptionsPartialEqualWeightsWithAlternateAnswer.js +94 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionPartialDifferentWeightsScoring.js +0 -75
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionPartialDifferentWeightsWithAlternateAnswer.js +83 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionsAllOrNothingwithAlternateAnswer.js +74 -0
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionsAutoScoredAllOrNothingScoring.js +0 -67
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionsPartialEqualWeightsScoring.js +0 -74
- package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropStandardOptionsPartialEqualWeightsWithAlternateAnswer.js +82 -0
- package/package.json +1 -1
package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesResponseOptionsSection.js
ADDED
@@ -0,0 +1,112 @@
|
|
1
|
+
import { dragAndDropIntoCategoriesPage } from "../../../pages";
|
2
|
+
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
3
|
+
const css = Cypress.env('css');
|
4
|
+
const optionsForThreeResponses = ['Response 1', 'Response 2', 'Response 3'];
|
5
|
+
const responseForGroup2 = ['Response 3', 'Response 4'];
|
6
|
+
|
7
|
+
describe('Create Item page - Drag and drop into categories: Options sections, Response options', () => {
|
8
|
+
before(() => {
|
9
|
+
cy.loginAs('admin');
|
10
|
+
});
|
11
|
+
|
12
|
+
describe('Response options and Response options layout dropdown', () => {
|
13
|
+
abortEarlySetup();
|
14
|
+
before(() => {
|
15
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
16
|
+
cy.barsPreLoaderWait();
|
17
|
+
});
|
18
|
+
|
19
|
+
dragAndDropIntoCategoriesPage.tests.verifyResponseOptionsLayoutDropdownSection();
|
20
|
+
});
|
21
|
+
|
22
|
+
describe('Options - \'Standard\' response options - Edit tab section contents', () => {
|
23
|
+
abortEarlySetup();
|
24
|
+
before(() => {
|
25
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
26
|
+
cy.barsPreLoaderWait();
|
27
|
+
});
|
28
|
+
|
29
|
+
dragAndDropIntoCategoriesPage.tests.verifyOptionsSectionContentAndFunctionality();
|
30
|
+
});
|
31
|
+
|
32
|
+
describe('\'Standard\' response options layout - Set correct answer section contents', () => {
|
33
|
+
abortEarlySetup();
|
34
|
+
before(() => {
|
35
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
36
|
+
cy.barsPreLoaderWait();
|
37
|
+
});
|
38
|
+
|
39
|
+
dragAndDropIntoCategoriesPage.tests.verifyStandardResponseDraggableOptionsInSetCorrectAnswerSection('drag and drop into categories');
|
40
|
+
|
41
|
+
it('When the user deletes an option, then the deleted option should get removed from the response options container as well as from the response areas (if any) in the \'Set Correct Answer\' section', () => {
|
42
|
+
const optionsAfterDeleting = optionsForThreeResponses.filter((el) => el !== 'Response 3');
|
43
|
+
cy.log('Setting a correct answer option')
|
44
|
+
dragAndDropIntoCategoriesPage.steps.clickAndDropDraggableOptionInCategoryCellOfSetCorrectAnswerSection('Response 3', 0);
|
45
|
+
dragAndDropIntoCategoriesPage.steps.deleteOption(2);
|
46
|
+
cy.log('Checking the deleted option should not exist within the draggable answer responses under \'Set Correct Answer\' section')
|
47
|
+
dragAndDropIntoCategoriesPage.steps.verifyDraggableResponsesSetCorrectAnswer('drag and drop into categories', optionsAfterDeleting);
|
48
|
+
});
|
49
|
+
});
|
50
|
+
|
51
|
+
describe('\'Standard\' Response options layout - Preview tab contents', () => {
|
52
|
+
abortEarlySetup();
|
53
|
+
before(() => {
|
54
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
55
|
+
cy.barsPreLoaderWait();
|
56
|
+
dragAndDropIntoCategoriesPage.steps.switchToPreviewTab();
|
57
|
+
});
|
58
|
+
|
59
|
+
dragAndDropIntoCategoriesPage.tests.verifyStandardResponseDraggableOptionsInPreviewTab('drag and drop into categories');
|
60
|
+
});
|
61
|
+
|
62
|
+
describe('\'Grouped\' response options layout - Edit tab section contents', () => {
|
63
|
+
abortEarlySetup();
|
64
|
+
before(() => {
|
65
|
+
cy.log('Navigate to drag and drop into categories question type');
|
66
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
67
|
+
cy.barsPreLoaderWait();
|
68
|
+
});
|
69
|
+
|
70
|
+
dragAndDropIntoCategoriesPage.tests.verifyGroupedOptionsContentAndFunctionality();
|
71
|
+
});
|
72
|
+
|
73
|
+
describe('\'Grouped\' response options layout - Set correct answer section contents', () => {
|
74
|
+
abortEarlySetup();
|
75
|
+
before(() => {
|
76
|
+
cy.log('Navigate to drag and drop into categories question type');
|
77
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
78
|
+
cy.barsPreLoaderWait();
|
79
|
+
dragAndDropIntoCategoriesPage.steps.selectResponseOptionsLayout('Grouped');
|
80
|
+
});
|
81
|
+
|
82
|
+
dragAndDropIntoCategoriesPage.tests.verifyGroupedResponseDraggableOptionsInSetCorrectAnswerSection('drag and drop into categories');
|
83
|
+
|
84
|
+
it('When the user deletes a group, then the deleted group should get removed from the response options container as well as from the response areas (if any) of the \'Set Correct Answer\' section', () => {
|
85
|
+
cy.log('Pre step: Entering text into the text fields of group 2 response container')
|
86
|
+
dragAndDropIntoCategoriesPage.steps.addInputToOptionsForGroupedResponseLayout(1, responseForGroup2);
|
87
|
+
dragAndDropIntoCategoriesPage.steps.addGroupTitle(1, 'Group title B');
|
88
|
+
cy.log('Setting a correct answer option')
|
89
|
+
dragAndDropIntoCategoriesPage.steps.clickAndDropDraggableOptionInCategoryCellOfSetCorrectAnswerSection('Response 2', 0);
|
90
|
+
cy.log('Deleting the 1st group')
|
91
|
+
dragAndDropIntoCategoriesPage.steps.deleteGroup(0);
|
92
|
+
dragAndDropIntoCategoriesPage.steps.verifyCountOfGroupsInSetCorrectAnswerSection(1);
|
93
|
+
cy.log('verifying the contents of group 2 after deleting group 1')
|
94
|
+
dragAndDropIntoCategoriesPage.steps.verifyGroupedResponseContainerContentsInSetCorrectAnswerSection(0, responseForGroup2);
|
95
|
+
dragAndDropIntoCategoriesPage.setCorrectAnswerSectionGroupedResponseTitle()
|
96
|
+
.should('have.text', 'Group title B');
|
97
|
+
});
|
98
|
+
});
|
99
|
+
|
100
|
+
describe('\'Grouped\' response options layout - Preview tab contents', () => {
|
101
|
+
abortEarlySetup();
|
102
|
+
before(() => {
|
103
|
+
cy.log('Navigate to drag and drop into categories question type');
|
104
|
+
dragAndDropIntoCategoriesPage.steps.navigateToCreateQuestion('drag and drop into categories');
|
105
|
+
cy.barsPreLoaderWait();
|
106
|
+
dragAndDropIntoCategoriesPage.steps.selectResponseOptionsLayout('Grouped');
|
107
|
+
dragAndDropIntoCategoriesPage.steps.switchToPreviewTab();
|
108
|
+
});
|
109
|
+
|
110
|
+
dragAndDropIntoCategoriesPage.tests.verifyGroupedResponseDraggableOptionsInPreviewTab('drag and drop into categories');
|
111
|
+
});
|
112
|
+
});
|