itemengine-cypress-automation 1.0.574-IEI-7071-main-96a7dd4.0 → 1.0.574-IEI-7065-Improve-test-coverage-for-essay-response-1a8de95.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.
Files changed (41) hide show
  1. package/cypress/e2e/ILC/EssayResponse/additionalSettings.js +8 -2
  2. package/cypress/e2e/ILC/EssayResponse/additionalSettingsBasic.js +15 -0
  3. package/cypress/e2e/ILC/EssayResponse/createCustomCategory.smoke.js +13 -0
  4. package/cypress/e2e/ILC/EssayResponse/editTabBasicSections.js +155 -5
  5. package/cypress/e2e/ILC/EssayResponse/essayResponseCustomizeFormattingOptions2.js +117 -4
  6. package/cypress/e2e/ILC/EssayResponse/essayResponseCustomizeFormattingOptions3.js +101 -4
  7. package/cypress/e2e/ILC/EssayResponse/essayResponseCustomizeFormattingOptions4.js +114 -0
  8. package/cypress/e2e/ILC/EssayResponse/essayResponseSpecialCharacters.js +12 -2
  9. package/cypress/e2e/ILC/EssayResponse/previewAddTable.js +38 -3
  10. package/cypress/e2e/ILC/EssayResponse/previewContentsForAllViews.smoke.js +41 -23
  11. package/cypress/e2e/ILC/EssayResponse/previewEditTable.js +78 -3
  12. package/cypress/e2e/ILC/EssayResponse/previewHyperlink.js +15 -0
  13. package/cypress/e2e/ILC/EssayResponse/studentViewSettings.js +71 -0
  14. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/allOrNothingAlternativePointsGreaterThanCorrectPoints.js +7 -108
  15. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/allOrNothingCorrectPointsEqualToAlternativePoints.js +7 -108
  16. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +7 -108
  17. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +8 -123
  18. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +8 -123
  19. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +8 -123
  20. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +7 -108
  21. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +6 -93
  22. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +7 -108
  23. package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/responseLevelAlternateAnswersBasicScoring.js +2 -23
  24. package/cypress/e2e/ILC/ShortTextResponseNew/additionalSettings.js +2 -99
  25. package/cypress/e2e/ILC/ShortTextResponseNew/allOrNothingWithAlternativeAnswer.js +245 -0
  26. package/cypress/e2e/ILC/ShortTextResponseNew/editTabBasicSections.js +1 -55
  27. package/cypress/e2e/ILC/ShortTextResponseNew/{Scoring/manuallyAndNonScoredScoring.js → manuallyAndNonScoredScoring.js} +18 -6
  28. package/cypress/e2e/ILC/ShortTextResponseNew/responseAnswersAndAcceptedStudentInput.js +1 -151
  29. package/cypress/e2e/ILC/ShortTextResponseNew/specialCharactersSection.js +3 -3
  30. package/cypress/e2e/ILC/ShortTextResponseNew/studentViewSettings.js +1 -129
  31. package/cypress/pages/components/equationEditorSectionCommonComponent.js +20 -0
  32. package/cypress/pages/components/essayResponseCommonComponents.js +29 -1
  33. package/cypress/pages/components/fillInTheGapsTextCommonComponent.js +0 -36
  34. package/cypress/pages/components/printPreviewComponent.js +1 -8
  35. package/cypress/pages/essayResponsePage.js +3 -1
  36. package/cypress/pages/shortTextResponsePage.js +6 -195
  37. package/package.json +1 -1
  38. package/cypress/e2e/ILC/ShortTextResponseNew/Scoring/allOrNothingAlternativePointsGreaterThanCorrectPoints.js +0 -63
  39. package/cypress/e2e/ILC/ShortTextResponseNew/Scoring/allOrNothingCorrectPointsEqualToAlternativePoints.js +0 -63
  40. package/cypress/e2e/ILC/ShortTextResponseNew/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +0 -87
  41. package/cypress/e2e/ILC/ShortTextResponseNew/Scoring/allOrNothingWeightsBasic.js +0 -163
@@ -1,163 +0,0 @@
1
- import { shortTextResponsePage } from "../../../../pages/shortTextResponsePage";
2
- import abortEarlySetup from "../../../../support/helpers/abortEarly";
3
- const css = Cypress.env('css');
4
-
5
- describe('Create item page - Short text response: All or nothing with alternative answer', () => {
6
- before(() => {
7
- cy.loginAs('admin');
8
- });
9
-
10
- describe('Question preview: Auto scored - All or nothing with alternative answer - When \'Correct answer\' points is equal to \'Alternative answer\' points', () => {
11
- abortEarlySetup();
12
- before(() => {
13
- shortTextResponsePage.steps.navigateToCreateQuestion('short text response');
14
- cy.barsPreLoaderWait();
15
- shortTextResponsePage.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.');
16
- shortTextResponsePage.steps.enterTextInAnswerInputFieldSpecifyCorrectAnswerSection('Buildings');
17
- shortTextResponsePage.steps.allotPoints(20);
18
- shortTextResponsePage.steps.switchToPreviewTab();
19
- });
20
-
21
- it('When the user switches to \'Grading\' view without attempting the question, then incorrect border and correct answer section should not be displayed', () => {
22
- shortTextResponsePage.steps.switchToGradingView();
23
- shortTextResponsePage.steps.verifyCorrectIncorrectBorderNotExist();
24
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
25
- shortTextResponsePage.steps.switchToStudentView();
26
- });
27
-
28
- it('When the user attempts the question correctly, then the user should be awarded with points specified and on switching to \'Grading\' view, correct icon should be displayed beside response input field, correct answer border should be displayed and correct answer section should not be displayed', () => {
29
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Buildings');
30
- shortTextResponsePage.steps.verifyPreviewScore(20, 20);
31
- shortTextResponsePage.steps.switchToGradingView();
32
- shortTextResponsePage.steps.verifyCorrectIcon();
33
- shortTextResponsePage.steps.verifyCorrectAttemptBorder();
34
- shortTextResponsePage.steps.verifyCorrectAnswerWrapperNotExist();
35
- shortTextResponsePage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
36
- });
37
-
38
- it('When the user attempts the question incorrectly, then the user should be awarded 0 points and on switching to \'Grading\' view, incorrect icon should be displayed beside response input field, incorrect answer border and correct answer section should be displayed in question preview', () => {
39
- shortTextResponsePage.steps.resetQuestionPreview();
40
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Incorrect');
41
- shortTextResponsePage.steps.verifyPreviewScore(0, 20);
42
- shortTextResponsePage.steps.switchToGradingView();
43
- shortTextResponsePage.steps.verifyIncorrectIcon();
44
- shortTextResponsePage.steps.verifyIncorrectAttemptBorder();
45
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
46
- shortTextResponsePage.steps.verifyQuestionPreviewStateWhenSwitchingBackToStudentView();
47
- });
48
- });
49
-
50
- describe('Question preview: Auto scored - \'Round negative scores to zero\' penalty scoring', () => {
51
- abortEarlySetup();
52
- before(() => {
53
- shortTextResponsePage.steps.navigateToCreateQuestion('short text response');
54
- cy.barsPreLoaderWait();
55
- shortTextResponsePage.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.');
56
- shortTextResponsePage.steps.enterTextInAnswerInputFieldSpecifyCorrectAnswerSection('Buildings');
57
- shortTextResponsePage.steps.allotPoints(20);
58
- shortTextResponsePage.steps.expandPenaltyScoringDropdown();
59
- shortTextResponsePage.steps.selectOptionFromPenaltyScoringDropdown('Penalty points for the entire question');
60
- shortTextResponsePage.steps.allotPenaltyPoints(5);
61
- shortTextResponsePage.steps.switchToPreviewTab();
62
- });
63
-
64
- it('When the user sets penalty scoring to \'Penalty points for the entire question\', allots penalty points,\'Round negative scores to zero\' is checked and attempts the question incorrectly, then the user should not be awarded with negative points', () => {
65
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Incorrect');
66
- shortTextResponsePage.steps.verifyPreviewScore(0, 20);
67
- shortTextResponsePage.steps.switchToGradingView();
68
- shortTextResponsePage.steps.verifyIncorrectIcon();
69
- shortTextResponsePage.steps.verifyIncorrectAttemptBorder();
70
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
71
-
72
- });
73
-
74
- it('When the user sets penalty scoring to \'Penalty points for the entire question\', allots penalty points,\'Round negative scores to zero\' is unchecked and attempts the question incorrectly, then the user should not be awarded with negative points', () => {
75
- shortTextResponsePage.steps.switchToEditTab();
76
- shortTextResponsePage.steps.uncheckRoundNegativeScoresToZeroCheckbox();
77
- shortTextResponsePage.steps.switchToPreviewTab();
78
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Incorrect');
79
- shortTextResponsePage.steps.verifyPreviewScore(-5, 20);
80
- shortTextResponsePage.steps.switchToGradingView();
81
- shortTextResponsePage.steps.verifyIncorrectIcon();
82
- shortTextResponsePage.steps.verifyIncorrectAttemptBorder();
83
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
84
- });
85
-
86
- it('When the user attempts the question correctly, then the user should be awarded 20 points and on switching to \'Grading\' view, correct icon should be displayed beside response input field, correct answer border should be displayed in question preview', () => {
87
- shortTextResponsePage.steps.resetQuestionPreview();
88
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Buildings');
89
- shortTextResponsePage.steps.verifyPreviewScore(20, 20);
90
- shortTextResponsePage.steps.switchToGradingView();
91
- shortTextResponsePage.steps.verifyCorrectIcon();
92
- shortTextResponsePage.steps.verifyCorrectAttemptBorder();
93
- shortTextResponsePage.steps.verifyCorrectAnswerWrapperNotExist();
94
- });
95
- });
96
-
97
- describe('Question preview: Auto scored - minimum scoring', () => {
98
- abortEarlySetup();
99
- before(() => {
100
- shortTextResponsePage.steps.navigateToCreateQuestion('short text response');
101
- cy.barsPreLoaderWait();
102
- shortTextResponsePage.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.');
103
- shortTextResponsePage.steps.enterTextInAnswerInputFieldSpecifyCorrectAnswerSection('Buildings');
104
- shortTextResponsePage.steps.allotPoints(20);
105
- shortTextResponsePage.steps.expandMinimumScoringDropdown();
106
- shortTextResponsePage.steps.selectOptionFromMinimumScoringDropdown('Award minimum score');
107
- shortTextResponsePage.steps.allotMinimumPoints(5);
108
- shortTextResponsePage.steps.switchToPreviewTab();
109
- });
110
-
111
- it('When the user sets minimum scoring to \'Award minimum score\', allots minimum points going to student view without attempting the question, then the user should be awarded with minimum points', () => {
112
- shortTextResponsePage.steps.verifyPreviewScore(5, 20);
113
- shortTextResponsePage.steps.switchToGradingView();
114
- shortTextResponsePage.steps.verifyCorrectIncorrectBorderNotExist();
115
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
116
- });
117
-
118
- it('When the user sets minimum scoring to \'Award minimum score\', allots minimum points and attempts the question incorrectly, then the user should be awarded with minimum points', () => {
119
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Incorrect');
120
- shortTextResponsePage.steps.verifyPreviewScore(5, 20);
121
- shortTextResponsePage.steps.switchToGradingView();
122
- shortTextResponsePage.steps.verifyIncorrectIcon();
123
- shortTextResponsePage.steps.verifyIncorrectAttemptBorder();
124
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
125
- });
126
-
127
- it('When the user sets minimum scoring to \'Award minimum score\', allots minimum points and attempts the question correctly, then the user should be awarded with 20 points', () => {
128
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Buildings');
129
- shortTextResponsePage.steps.verifyPreviewScore(20, 20);
130
- shortTextResponsePage.steps.switchToGradingView();
131
- shortTextResponsePage.steps.verifyCorrectIcon();
132
- shortTextResponsePage.steps.verifyCorrectAttemptBorder();
133
- });
134
-
135
- it('When the user sets minimum scoring to \'Award minimum score only if attempted\', allots minimum points going to student view without attempting the question, then the user should be awarded with minimum points', () => {
136
- shortTextResponsePage.steps.switchToEditTab();
137
- shortTextResponsePage.steps.expandMinimumScoringDropdown();
138
- shortTextResponsePage.steps.selectOptionFromMinimumScoringDropdown('Award minimum score only if attempted');
139
- shortTextResponsePage.steps.allotMinimumPoints(5);
140
- shortTextResponsePage.steps.switchToPreviewTab();
141
- shortTextResponsePage.steps.verifyPreviewScore(0, 20);
142
- shortTextResponsePage.steps.switchToGradingView();
143
- shortTextResponsePage.steps.verifyCorrectIncorrectBorderNotExist();
144
- });
145
-
146
- it('When the user sets minimum scoring to \'Award minimum score only if attempted\', allots minimum points and attempts the question incorrectly, then the user should be awarded with minimum points', () => {
147
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Incorrect');
148
- shortTextResponsePage.steps.verifyPreviewScore(5, 20);
149
- shortTextResponsePage.steps.switchToGradingView();
150
- shortTextResponsePage.steps.verifyIncorrectIcon();
151
- shortTextResponsePage.steps.verifyIncorrectAttemptBorder();
152
- shortTextResponsePage.steps.verifyCorrectAnswerResponseInCorrectAnswerWrapper('Buildings');
153
- });
154
-
155
- it('When the user sets minimum scoring to \'Award minimum score only if attempted\', allots minimum points and attempts the question correctly, then the user should be awarded with 20 points', () => {
156
- shortTextResponsePage.steps.enterTextInAnswerInputFieldPreviewTab('Buildings');
157
- shortTextResponsePage.steps.verifyPreviewScore(20, 20);
158
- shortTextResponsePage.steps.switchToGradingView();
159
- shortTextResponsePage.steps.verifyCorrectIcon();
160
- shortTextResponsePage.steps.verifyCorrectAttemptBorder();
161
- });
162
- });
163
- });