itemengine-cypress-automation 1.0.240-textentrychangesreverted-28d08d1.0 → 1.0.241-28thAugustRepoUpdate-dc7df0c.0
Sign up to get free protection for your applications and to get access to all the features.
- package/cypress/e2e/ILC/BrainingCampManipulative/editTabBasicSection.js +2 -2
- package/cypress/e2e/ILC/ChartsBar/headerSection.js +22 -5
- package/cypress/e2e/ILC/ChartsLine/headerSection.js +23 -5
- package/cypress/e2e/ILC/ContentBlocks/editTabBasics.js +3 -4
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/clickAndDrop.js +2 -4
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/draggableOptions.js +3 -4
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/headerSection.js +4 -6
- package/cypress/e2e/ILC/EssayResponse/equationEditor.smoke.js +1 -3
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/Scoring/allOrNothingWithCorrectPointsEqualToAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/clickAndDrop.js +2 -4
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/draggableOptions.js +3 -4
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/editTabBasicSection.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/headerSection.js +4 -5
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/dropdownOptionsSection.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/editTabBasicSection.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/headerSection.js +3 -5
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/specifyCorrectAnswerSection.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/additionalSettings.js +172 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/clickAndDrop.js +3 -5
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/draggableOptions.js +0 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/headerSection.js +3 -8
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/Scoring/manuallyAndNonScored.js +6 -6
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/additionalSettingsBasic.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/dropdownOptionsSection.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/editTabBasicSection.js +3 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/headerSection.js +2 -8
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/supportedFileTypes.js +2 -3
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/HeaderSection.js +3 -5
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/backgroundImageAndCanvasProperties.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/specifyCorrectAnswerSection.js +3 -3
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/styleAndLayoutCustomization.js +16 -16
- package/cypress/e2e/ILC/FillInTheGapsTextNew/editTabBasicSection.js +3 -2
- package/cypress/e2e/ILC/FillInTheGapsTextNew/headerSection.js +3 -3
- package/cypress/e2e/ILC/FillInTheGapsTextNew/specifyCorrectAnswerSection.js +3 -3
- package/cypress/e2e/ILC/Graphing/headerSection.js +2 -3
- package/cypress/e2e/ILC/GridFill/headerSection.js +2 -4
- package/cypress/e2e/ILC/GridFill/specifyCorrectAnswerSection.js +6 -3
- package/cypress/e2e/ILC/ImageHighlight/headerSection.js +2 -4
- package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/partialDifferentWeightsMinimumAndPenaltyScoring.js +2 -2
- package/cypress/e2e/ILC/ListOrderingDropdown/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/ListOrderingDropdown/specifyCorrectAnswerSection.js +6 -8
- package/cypress/e2e/ILC/ListOrderingNew/headerSection.js +2 -8
- package/cypress/e2e/ILC/ListOrderingNew/optionsOrientationSection.js +150 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/HorizontalOrientation/horizontalOrientationAllOrNothingForAllViews.smoke.js +218 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/HorizontalOrientation/previewContentsForAllViews.smoke.js +176 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/allOrNothingAlternativePointsGreaterThanCorrectPoints.js +170 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/allOrNothingCorrectPointsEqualToAlternativePoints.js +170 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +230 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/allOrNothingPenaltyScoring.js +64 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/manuallyAndNonScored.js +110 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/allOrNothingForAllViews.smoke.js +249 -0
- package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/previewContentsForAllViews.smoke.js +172 -0
- package/cypress/e2e/ILC/Matching/clickAndDrop.js +6 -10
- package/cypress/e2e/ILC/Matching/headerSection.js +2 -10
- package/cypress/e2e/ILC/Matching/matchingConnector.js +128 -0
- package/cypress/e2e/ILC/Matching/minimumScoringPenaltyPointsAndRoundingDropdown.js +2 -2
- package/cypress/e2e/ILC/Matching/questionInstructionsAndPromptSection.js +2 -15
- package/cypress/e2e/ILC/MatchingDropdown/editTabBasicSection.js +154 -0
- package/cypress/e2e/ILC/MultipleSelection/headerSection.js +4 -6
- package/cypress/e2e/ILC/MultipleSelectionGridNew/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +4 -4
- package/cypress/e2e/ILC/MultipleSelectionGridNew/Scoring/partialDifferentWeightsMinimumAndPenaltyScoring.js +1 -1
- package/cypress/e2e/ILC/MultipleSelectionGridNew/headerSection.js +3 -9
- package/cypress/e2e/ILC/NumberLine/headerSection.js +2 -3
- package/cypress/e2e/ILC/NumberLineLabel/headerSection.js +4 -4
- package/cypress/e2e/ILC/ShortTextResponseNew/headerSection.js +2 -4
- package/cypress/e2e/ILC/SingleSelection/headerSection.js +2 -5
- package/cypress/e2e/ILC/SingleSelectionGridNew/Scoring/allOrNothingAlternativePointsGreaterThanCorrectPoints.js +2 -2
- package/cypress/e2e/ILC/SingleSelectionGridNew/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +2 -2
- package/cypress/e2e/ILC/SingleSelectionGridNew/headerSection.js +2 -9
- package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingAlternatePointsGreaterThanCorrectPoints.js +210 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +210 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingCorrectPointsGreaterThanAlternatePoints.js +258 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +246 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsCorrectPointsEqualToAlternativePoints.js +203 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsCorrectPointsGreaterThanAlternativePoints.js +245 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsScoringBasic.js +541 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsAlternativePointsGreaterThanCorrectPoints.js +243 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsCorrectPointsEqualToAlternativePoints.js +203 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsCorrectPointsGreaterThanAlternativePoints.js +242 -0
- package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsScoringBasic.js +195 -0
- package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViews.smoke.js +6 -0
- package/cypress/e2e/ILC/TextEntryMath/editTabBasicSection.js +8 -1
- package/cypress/e2e/ILC/TextEntryMath/editTabScoringSection.js +12 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodEquivalentStructures.js +10 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodMatchExact.js +2 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodMatchValue.js +2 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodSymbolsAreEquivalent.js +2 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodValueIsEquivalent.js +2 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodsWithoutSetResponse.js +4 -0
- package/cypress/e2e/ILC/TextEntryMath/minimumScoringPenaltyPointsAndRoundingDropdown.js +6 -0
- package/cypress/e2e/ILC/TextEntryMath/previewContentsForAllViews.smoke.js +2 -0
- package/cypress/e2e/ILC/TextEntryMathWithImage/allOrNothingScoringForAllViews.smoke.js +6 -0
- package/cypress/e2e/ILC/TextEntryMathWithImage/backgroundImageAndCanvasProperties.js +2 -0
- package/cypress/e2e/ILC/TextEntryMathWithImage/previewTabContentsForAllViews.smoke.js +2 -0
- package/cypress/e2e/ILC/TextSelection/Scoring/singleSelectionPreviewScoring.js +247 -0
- package/cypress/e2e/ILC/TextSelection/headerSection.js +4 -5
- package/cypress/e2e/ILC/TextSelection/questionInstructionsAndQuestion.js +1 -2
- package/cypress/e2e/ILC/TextSelection/singleMultipleSelection.js +100 -0
- package/cypress/e2e/ILC/TextSelection/styleAndLayoutCustomizationAccordionOutline.js +248 -0
- package/cypress/e2e/ILC/TextSelection/styleAndLayoutCustomizationAccordionStrikethrough.js +247 -0
- package/cypress/e2e/ILC/TextSelection/styleAndLayoutCustomizationAccordionUnderline.js +239 -0
- package/cypress/e2e/ILC/TextSelection/textSelectionStyle.js +150 -0
- package/cypress/e2e/ILC/ToolAudioPlayerNew/headerSection.js +3 -2
- package/cypress/e2e/ILC/UploadResponse/editTabBasicSection.js +2 -3
- package/cypress/e2e/ILC/chartsDotsPlot/allOrNothingForAllViews.smoke.js +1 -1
- package/cypress/e2e/ILC/chartsDotsPlot/headerSection.js +21 -5
- package/cypress/pages/components/autoScoredScoringPreviewTab.js +1 -0
- package/cypress/pages/components/autoScoredSetCorrectAnswerSection.js +0 -11
- package/cypress/pages/components/autoScoredSpecifyCorrectAnswerSection.js +11 -29
- package/cypress/pages/components/draggableOptionsStyleAndLayoutComponent.js +1 -1
- package/cypress/pages/components/figCommonStyleAndLayoutComponent.js +1 -1
- package/cypress/pages/components/fillInTheGapsDropdownCommonComponent.js +2 -3
- package/cypress/pages/components/fillInTheGapsTextCommonComponent.js +2 -2
- package/cypress/pages/components/optionsWrapperComponent.js +2 -2
- package/cypress/pages/components/playbackControlsBaseComponent.js +2 -2
- package/cypress/pages/components/questionInputFieldComponent.js +1 -0
- package/cypress/pages/components/scoringSectionBaseEditTab.js +3 -2
- package/cypress/pages/components/singleMultipleSelectionModeComponent.js +1 -1
- package/cypress/pages/createItemPage.js +1 -1
- package/cypress/pages/dialogBoxBase.js +21 -9
- package/cypress/pages/dragAndDropIntoCategoriesPage.js +4 -5
- package/cypress/pages/fillInTheGapsOverImageDragAndDropPage.js +83 -5
- package/cypress/pages/graphingPage.js +4 -7
- package/cypress/pages/gridFillPage.js +15 -16
- package/cypress/pages/listOrderingPage.js +373 -2
- package/cypress/pages/matchingPage.js +89 -33
- package/cypress/pages/multipleSelectionGridPage.js +11 -13
- package/cypress/pages/multipleSelectionPage.js +4 -5
- package/cypress/pages/numberLinePage.js +2 -13
- package/cypress/pages/shortTextResponsePage.js +2 -3
- package/cypress/pages/textEntryMathPage.js +28 -0
- package/cypress/pages/textSelectionPage.js +242 -3
- package/cypress/pages/videoResponsePage.js +0 -2
- package/package.json +1 -1
- /package/cypress/e2e/ILC/TextSelection/{styleAndLayoutCustomizationAccordion.js → styleAndLayoutCustomizationAccordionFilledIn.js} +0 -0
@@ -0,0 +1,170 @@
|
|
1
|
+
import { listOrderingPage } from "../../../../pages/listOrderingPage";
|
2
|
+
import abortEarlySetup from "../../../../support/helpers/abortEarly";
|
3
|
+
|
4
|
+
let options = ['sprout', 'plant', 'flower', 'seed'];
|
5
|
+
let correctAnswerArray = ['seed', 'sprout', 'plant', 'flower'];
|
6
|
+
let alternateCorrectAnswerArray = ['seed', 'flower', 'sprout', 'plant'];
|
7
|
+
|
8
|
+
describe('Create item page - List ordering: All or nothing scoring with alternative answer - When alternative answer points are more than correct answer points', () => {
|
9
|
+
before(() => {
|
10
|
+
cy.loginAs('admin');
|
11
|
+
});
|
12
|
+
|
13
|
+
describe('Question preview: AutoScored - All or nothing with alternative answer: When alternative answer points are more than correct answer points', () => {
|
14
|
+
abortEarlySetup();
|
15
|
+
before(() => {
|
16
|
+
listOrderingPage.steps.navigateToCreateQuestion('list ordering');
|
17
|
+
cy.barsPreLoaderWait();
|
18
|
+
listOrderingPage.steps.selectOrderingLayoutOption('Reorder as a separate list');
|
19
|
+
listOrderingPage.steps.addTextInQuestionInstructionsInputField('Arrange options in correct order.');
|
20
|
+
listOrderingPage.steps.addInputToOptionsInputField(options);
|
21
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
22
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
23
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
24
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
25
|
+
listOrderingPage.steps.allotPoints(20);
|
26
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
27
|
+
listOrderingPage.steps.addAlternativeAnswerAccordion(1);
|
28
|
+
listOrderingPage.steps.allotPoints(25);
|
29
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
30
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
31
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
32
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
33
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
34
|
+
listOrderingPage.steps.switchToPreviewTab();
|
35
|
+
});
|
36
|
+
|
37
|
+
it('When the user switches to the \'Grading view\' without attempting the question, then correct/incorrect icons should be not displayed for the default list order, "Your answer is incorrect" label should not be displayed and correct answers section with a label \'Correct answers\' should be displayed with correct answers from the alternative accordion', () => {
|
38
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
39
|
+
listOrderingPage.steps.switchToGradingView();
|
40
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabelNotExist();
|
41
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
42
|
+
});
|
43
|
+
|
44
|
+
it('When the user attempts the question with responses from the correct accordion, then the user should be awarded with points specified for correct accordion (less than full points) and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
45
|
+
listOrderingPage.steps.resetQuestionPreview();
|
46
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
47
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
48
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
49
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
50
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
51
|
+
listOrderingPage.steps.verifyPreviewScore(20, 25);
|
52
|
+
listOrderingPage.steps.switchToGradingView();
|
53
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
54
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
55
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
56
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
57
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
58
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
59
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
60
|
+
});
|
61
|
+
|
62
|
+
it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with full points and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
63
|
+
listOrderingPage.steps.resetQuestionPreview();
|
64
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
65
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
66
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
67
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
68
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
69
|
+
listOrderingPage.steps.verifyPreviewScore(25, 25);
|
70
|
+
listOrderingPage.steps.switchToGradingView();
|
71
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
72
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
73
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
74
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
75
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
76
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
77
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
78
|
+
});
|
79
|
+
|
80
|
+
it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone numeration should be displayed', () => {
|
81
|
+
listOrderingPage.steps.resetQuestionPreview();
|
82
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
83
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
84
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
85
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
86
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'sprout', 'plant', 'seed']);
|
87
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
88
|
+
listOrderingPage.steps.switchToGradingView();
|
89
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
90
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
91
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
92
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
93
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
94
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
95
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
96
|
+
});
|
97
|
+
|
98
|
+
it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
99
|
+
listOrderingPage.steps.resetQuestionPreview();
|
100
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
101
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
102
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
103
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
104
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['plant', 'flower', 'sprout', 'seed']);
|
105
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
106
|
+
listOrderingPage.steps.switchToGradingView();
|
107
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
108
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
109
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
110
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
111
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
112
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
113
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
114
|
+
});
|
115
|
+
|
116
|
+
it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed besides response field with alternative answer responses, red cross-mark icon should be displayed beside responses from the correct accordion, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
117
|
+
listOrderingPage.steps.resetQuestionPreview();
|
118
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
119
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
120
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
121
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
122
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'sprout', 'flower', 'plant']);
|
123
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
124
|
+
listOrderingPage.steps.switchToGradingView();
|
125
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
126
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
127
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
128
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
129
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
130
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
131
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
132
|
+
});
|
133
|
+
|
134
|
+
it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be besides the common response, , \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
135
|
+
listOrderingPage.steps.resetQuestionPreview();
|
136
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
137
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
138
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
139
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
140
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'plant', 'flower', 'sprout']);
|
141
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
142
|
+
listOrderingPage.steps.switchToGradingView();
|
143
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
144
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
145
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
146
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
147
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
148
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
149
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
150
|
+
});
|
151
|
+
|
152
|
+
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, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers along with dropzone cell numeration should be displayed', () => {
|
153
|
+
listOrderingPage.steps.resetQuestionPreview();
|
154
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
155
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
156
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
157
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
158
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'plant', 'seed', 'sprout']);
|
159
|
+
listOrderingPage.steps.verifyPreviewScore(0, 25);
|
160
|
+
listOrderingPage.steps.switchToGradingView();
|
161
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
162
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
163
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
164
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
165
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(alternateCorrectAnswerArray);
|
166
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
167
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
168
|
+
});
|
169
|
+
});
|
170
|
+
});
|
@@ -0,0 +1,170 @@
|
|
1
|
+
import { listOrderingPage } from "../../../../pages/listOrderingPage";
|
2
|
+
import abortEarlySetup from "../../../../support/helpers/abortEarly";
|
3
|
+
|
4
|
+
let options = ['sprout', 'plant', 'flower', 'seed'];
|
5
|
+
let correctAnswerArray = ['seed', 'sprout', 'plant', 'flower'];
|
6
|
+
let alternateCorrectAnswerArray = ['seed', 'flower', 'sprout', 'plant'];
|
7
|
+
|
8
|
+
describe('Create Item page - List ordering: All or nothing scoring with alternative answer - When Correct answer points are equal to the alternative answer points', () => {
|
9
|
+
before(() => {
|
10
|
+
cy.loginAs('admin');
|
11
|
+
});
|
12
|
+
|
13
|
+
describe('Question Preview: AutoScored - All or nothing with alternative answer: Alternate answer case: When Correct answer points are equal to the alternative answer points', () => {
|
14
|
+
abortEarlySetup();
|
15
|
+
before(() => {
|
16
|
+
listOrderingPage.steps.navigateToCreateQuestion('list ordering');
|
17
|
+
cy.barsPreLoaderWait();
|
18
|
+
listOrderingPage.steps.selectOrderingLayoutOption('Reorder as a separate list');
|
19
|
+
listOrderingPage.steps.addTextInQuestionInstructionsInputField('Arrange options in correct order.');
|
20
|
+
listOrderingPage.steps.addInputToOptionsInputField(options);
|
21
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
22
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
23
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
24
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
25
|
+
listOrderingPage.steps.allotPoints(20);
|
26
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
27
|
+
listOrderingPage.steps.addAlternativeAnswerAccordion(1);
|
28
|
+
listOrderingPage.steps.allotPoints(20);
|
29
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
30
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
31
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
32
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
33
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
34
|
+
listOrderingPage.steps.switchToPreviewTab();
|
35
|
+
});
|
36
|
+
|
37
|
+
it('When the user switches to the \'Grading view\' without attempting the question, then correct/incorrect icons should not be displayed for the default list order, "Your answer is incorrect" label should not be displayed and correct answers section with a label \'Correct answers\' should be displayed with correct answers from the correct accordion', () => {
|
38
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
39
|
+
listOrderingPage.steps.switchToGradingView();
|
40
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabelNotExist();
|
41
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
42
|
+
});
|
43
|
+
|
44
|
+
it('When the user attempts the question with responses from the correct accordion, then the user should be awarded full points and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
45
|
+
listOrderingPage.steps.resetQuestionPreview();
|
46
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
47
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
48
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
49
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
50
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
51
|
+
listOrderingPage.steps.verifyPreviewScore(20, 20);
|
52
|
+
listOrderingPage.steps.switchToGradingView();
|
53
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
54
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
55
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
56
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
57
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
58
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
59
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
60
|
+
});
|
61
|
+
|
62
|
+
it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with full points and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
63
|
+
listOrderingPage.steps.resetQuestionPreview();
|
64
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
65
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
66
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
67
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
68
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
69
|
+
listOrderingPage.steps.verifyPreviewScore(20, 20);
|
70
|
+
listOrderingPage.steps.switchToGradingView();
|
71
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
72
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
73
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
74
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
75
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
76
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
77
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
78
|
+
});
|
79
|
+
|
80
|
+
it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone numeration should be displayed', () => {
|
81
|
+
listOrderingPage.steps.resetQuestionPreview();
|
82
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
83
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
84
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
85
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
86
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'sprout', 'plant', 'seed']);
|
87
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
88
|
+
listOrderingPage.steps.switchToGradingView();
|
89
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
90
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
91
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
92
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
93
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
94
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
95
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
96
|
+
});
|
97
|
+
|
98
|
+
it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
99
|
+
listOrderingPage.steps.resetQuestionPreview();
|
100
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
101
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
102
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
103
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
104
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['plant', 'flower', 'sprout', 'seed']);
|
105
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
106
|
+
listOrderingPage.steps.switchToGradingView();
|
107
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
108
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
109
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
110
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
111
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
112
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
113
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
114
|
+
});
|
115
|
+
|
116
|
+
it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed besides response field with correct answer responses, red cross-mark icon should be displayed beside responses from the alternative tab, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
117
|
+
listOrderingPage.steps.resetQuestionPreview();
|
118
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
119
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
120
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
121
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
122
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'sprout', 'flower', 'plant']);
|
123
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
124
|
+
listOrderingPage.steps.switchToGradingView();
|
125
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
126
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
127
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
128
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
129
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
130
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
131
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
132
|
+
});
|
133
|
+
|
134
|
+
it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be besides the common response, \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion should be displayed', () => {
|
135
|
+
listOrderingPage.steps.resetQuestionPreview();
|
136
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
137
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
138
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
139
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
140
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'plant', 'flower', 'sprout']);
|
141
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
142
|
+
listOrderingPage.steps.switchToGradingView();
|
143
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
144
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
145
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
146
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
147
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
148
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
149
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
150
|
+
});
|
151
|
+
|
152
|
+
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, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers along with dropzone cell numeration should be displayed', () => {
|
153
|
+
listOrderingPage.steps.resetQuestionPreview();
|
154
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
155
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
156
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
157
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
158
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'plant', 'seed', 'sprout']);
|
159
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
160
|
+
listOrderingPage.steps.switchToGradingView();
|
161
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
162
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
163
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
164
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
165
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
166
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
167
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
168
|
+
});
|
169
|
+
});
|
170
|
+
});
|
@@ -0,0 +1,230 @@
|
|
1
|
+
import { listOrderingPage } from "../../../../pages/listOrderingPage";
|
2
|
+
import abortEarlySetup from "../../../../support/helpers/abortEarly";
|
3
|
+
import utilities from "../../../../support/helpers/utilities";
|
4
|
+
let options = ['sprout', 'plant', 'flower', 'seed'];
|
5
|
+
let correctAnswerArray = ['seed', 'sprout', 'plant', 'flower'];
|
6
|
+
let alternateCorrectAnswerArray = ['seed', 'flower', 'sprout', 'plant'];
|
7
|
+
|
8
|
+
describe('Create Item page - List ordering: All or nothing scoring with alternative answer - When Correct answer points are more than alternative Answer points', () => {
|
9
|
+
before(() => {
|
10
|
+
cy.loginAs('admin');
|
11
|
+
});
|
12
|
+
|
13
|
+
describe('Question Preview: AutoScored - All or nothing with alternative answer: When Correct Answer points are more than alternative Answer points', () => {
|
14
|
+
abortEarlySetup();
|
15
|
+
before(() => {
|
16
|
+
listOrderingPage.steps.navigateToCreateQuestion('list ordering');
|
17
|
+
cy.barsPreLoaderWait();
|
18
|
+
listOrderingPage.steps.selectOrderingLayoutOption('Reorder as a separate list');
|
19
|
+
listOrderingPage.steps.addTextInQuestionInstructionsInputField('Arrange options in correct order.');
|
20
|
+
listOrderingPage.steps.addInputToOptionsInputField(options);
|
21
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
22
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
23
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
24
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
25
|
+
listOrderingPage.steps.allotPoints(20);
|
26
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
27
|
+
listOrderingPage.steps.addAlternativeAnswerAccordion(1);
|
28
|
+
listOrderingPage.steps.allotPoints(12);
|
29
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
30
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
31
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
32
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
33
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
34
|
+
listOrderingPage.steps.switchToPreviewTab();
|
35
|
+
});
|
36
|
+
|
37
|
+
it('When the user switches to the \'Grading view\' without attempting the question, then correct/incorrect icons should not be displayed for the default list order, "Your answer is incorrect" label should not be displayed and correct answers section with a label \'Correct answers\' should be displayed with correct answers from the correct accordion', () => {
|
38
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
39
|
+
listOrderingPage.steps.switchToGradingView();
|
40
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabelNotExist();
|
41
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
42
|
+
});
|
43
|
+
|
44
|
+
it('CSS of correct answer section', { tags: 'css' }, () => {
|
45
|
+
utilities.verifyCSS(listOrderingPage.correctAnswersLabel(), {
|
46
|
+
'color': css.color.sectionHeading,
|
47
|
+
'font-size': css.fontSize.default,
|
48
|
+
'font-weight': css.fontWeight.bold
|
49
|
+
});
|
50
|
+
utilities.verifyCSS(listOrderingPage.correctAnswerSectionAnswerWrapper(), {
|
51
|
+
'border': `1px solid ${css.color.correctAnswer}`
|
52
|
+
});
|
53
|
+
utilities.verifyCSS(listOrderingPage.correctAnswerSectionAnswerWrapper().find('question-text-wrapper'), {
|
54
|
+
'color': css.color.text,
|
55
|
+
'font-size': css.fontSize.default,
|
56
|
+
'font-weight': css.fontWeight.regular,
|
57
|
+
});
|
58
|
+
});
|
59
|
+
|
60
|
+
it('Accessibility of correct answer section', { tags: 'a11y' }, () => {
|
61
|
+
cy.checkAccessibility(listOrderingPage.previewTabQuestionWrapper());
|
62
|
+
});
|
63
|
+
|
64
|
+
it('When the user attempts the question with responses from the correct accordion, then the user should be awarded full points and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
65
|
+
listOrderingPage.steps.resetQuestionPreview();
|
66
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
67
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
68
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
69
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
70
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(correctAnswerArray);
|
71
|
+
listOrderingPage.steps.verifyPreviewScore(20, 20);
|
72
|
+
listOrderingPage.steps.switchToGradingView();
|
73
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
74
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
75
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
76
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
77
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
78
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
79
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
80
|
+
});
|
81
|
+
|
82
|
+
it('CSS of Correct answer state', { tags: 'css' }, () => {
|
83
|
+
utilities.verifyCSS(listOrderingPage.previewScoreText(), {
|
84
|
+
'color': css.color.whiteText,
|
85
|
+
'background-color': css.color.correctAnswer
|
86
|
+
});
|
87
|
+
listOrderingPage.correctIcon()
|
88
|
+
.verifyPseudoClassBeforeProperty('color', css.color.correctAnswer);
|
89
|
+
utilities.verifyCSS(listOrderingPage.correctIncorrectAnswerBlock(), {
|
90
|
+
'background-color': css.color.correctAnswerLabelBg,
|
91
|
+
'border': `1px solid ${css.color.correctAnswer}`
|
92
|
+
});
|
93
|
+
utilities.verifyCSS(listOrderingPage.correctIncorrectStatusMessageText(), {
|
94
|
+
'color': css.color.text,
|
95
|
+
'font-size': css.fontSize.default,
|
96
|
+
'font-weight': css.fontWeight.regular
|
97
|
+
});
|
98
|
+
});
|
99
|
+
|
100
|
+
it('Accessibility of correct answer state', { tags: 'a11y' }, () => {
|
101
|
+
cy.checkAccessibility(listOrderingPage.previewTabQuestionWrapper());
|
102
|
+
});
|
103
|
+
|
104
|
+
it('When the user attempts the question with responses from the alternative accordion, then the user should be awarded with points specified for alternative accordion (less than full points) and on switching to \'Grading\' view, correct icons should be displayed beside all the correct responses, a status message with text \'Your answer is correct\' and correct answer section should not be displayed', () => {
|
105
|
+
listOrderingPage.steps.resetQuestionPreview();
|
106
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
107
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
108
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
109
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
110
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(alternateCorrectAnswerArray);
|
111
|
+
listOrderingPage.steps.verifyPreviewScore(12, 20);
|
112
|
+
listOrderingPage.steps.switchToGradingView();
|
113
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
114
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
115
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
116
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
117
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
|
118
|
+
listOrderingPage.steps.verifyCorrectAnswerSectionNotExists();
|
119
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
120
|
+
});
|
121
|
+
|
122
|
+
it('When the user attempts the question with partially correct options exclusively from the correct accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone numeration should be displayed', () => {
|
123
|
+
listOrderingPage.steps.resetQuestionPreview();
|
124
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
125
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
126
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
127
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
128
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'sprout', 'plant', 'seed']);
|
129
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
130
|
+
listOrderingPage.steps.switchToGradingView();
|
131
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
132
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
133
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('plant');
|
134
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
135
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
136
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
137
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
138
|
+
});
|
139
|
+
|
140
|
+
it('When the user attempts the question with partially correct options exclusively from the alternative accordion, then the user should be awarded 0 points and on switching to \'Grading\' view, correct icon should be displayed besides the correct answer responses, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
141
|
+
listOrderingPage.steps.resetQuestionPreview();
|
142
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
143
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
144
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
145
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
146
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['plant', 'flower', 'sprout', 'seed']);
|
147
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
148
|
+
listOrderingPage.steps.switchToGradingView();
|
149
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
150
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('flower');
|
151
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
152
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
153
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
154
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
155
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
156
|
+
});
|
157
|
+
|
158
|
+
it('When the user has attempted the question with equal number of correct responses from correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be displayed besides response field with correct answer responses, red cross-mark icon should be displayed beside responses from the alternative tab, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion along with dropzone cell numeration should be displayed', () => {
|
159
|
+
listOrderingPage.steps.resetQuestionPreview();
|
160
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
161
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
162
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
163
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
164
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'sprout', 'flower', 'plant']);
|
165
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
166
|
+
listOrderingPage.steps.switchToGradingView();
|
167
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
168
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('sprout');
|
169
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
170
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
171
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
172
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
173
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
174
|
+
});
|
175
|
+
|
176
|
+
it('Race condition : When the user attempts the question with the common response between correct and alternative accordion, then the user should be awarded with 0 points and on switching to \'Grading\' view, correct icon should be besides the common response, \'Your answer is incorrect\' and correct answer section with all correct answers from the correct accordion should be displayed', () => {
|
177
|
+
listOrderingPage.steps.resetQuestionPreview();
|
178
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
179
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
180
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
181
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
182
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['seed', 'plant', 'flower', 'sprout']);
|
183
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
184
|
+
listOrderingPage.steps.switchToGradingView();
|
185
|
+
listOrderingPage.steps.verifyCorrectOptionIconSeperateList('seed');
|
186
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
187
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
188
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
189
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
190
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
191
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
192
|
+
});
|
193
|
+
|
194
|
+
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, a status message with text \'Your answer is incorrect\' and correct answer section with all correct answers along with dropzone cell numeration should be displayed', () => {
|
195
|
+
listOrderingPage.steps.resetQuestionPreview();
|
196
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('flower');
|
197
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('plant');
|
198
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('seed');
|
199
|
+
listOrderingPage.steps.clickAndDropOptionSeperateList('sprout');
|
200
|
+
listOrderingPage.steps.verifyOptionsInDropzoneOrderAsSeperateList(['flower', 'plant', 'seed', 'sprout']);
|
201
|
+
listOrderingPage.steps.verifyPreviewScore(0, 20);
|
202
|
+
listOrderingPage.steps.switchToGradingView();
|
203
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('flower');
|
204
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('plant');
|
205
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('seed');
|
206
|
+
listOrderingPage.steps.verifyIncorrectOptionIconSeperateList('sprout');
|
207
|
+
listOrderingPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
208
|
+
listOrderingPage.steps.verifyOptionsInCorrectAnswerSection(correctAnswerArray);
|
209
|
+
listOrderingPage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
|
210
|
+
});
|
211
|
+
|
212
|
+
it('CSS of incorrect answer state', { tags: 'css' }, () => {
|
213
|
+
listOrderingPage.incorrectIcon()
|
214
|
+
.verifyPseudoClassBeforeProperty('color', css.color.incorrectAnswer);
|
215
|
+
utilities.verifyCSS(listOrderingPage.correctIncorrectAnswerBlock(), {
|
216
|
+
'background-color': css.color.incorrectAnswerLabelBg,
|
217
|
+
'border': `1px solid ${css.color.incorrectAnswer}`
|
218
|
+
});
|
219
|
+
utilities.verifyCSS(listOrderingPage.correctIncorrectStatusMessageText(), {
|
220
|
+
'color': css.color.text,
|
221
|
+
'font-size': css.fontSize.default,
|
222
|
+
'font-weight': css.fontWeight.regular
|
223
|
+
});
|
224
|
+
});
|
225
|
+
|
226
|
+
it('Accessibility of incorrect answer state', { tags: 'a11y' }, () => {
|
227
|
+
cy.checkAccessibility(listOrderingPage.previewTabQuestionWrapper());
|
228
|
+
});
|
229
|
+
});
|
230
|
+
});
|