itemengine-cypress-automation 1.0.72 → 1.0.73

Sign up to get free protection for your applications and to get access to all the features.
Files changed (90) hide show
  1. package/cypress/e2e/ILC/AudioResponse/{audioResponseMinimalPreviewSection.js → audioResponseMinimalPreviewSection.smoke.js} +263 -254
  2. package/cypress/e2e/ILC/AudioResponse/{audioResponseStandardPreviewSection.js → audioResponseStandardPreviewSection.smoke.js} +100 -97
  3. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/groupedOptionsAllOrNothing.smoke.js +121 -0
  4. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/{groupedOptionsPartialScoreForEachCell.js → groupedOptionsPartialScoreForEachCell.smoke.js} +1 -1
  5. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/{groupedOptionsPartialScoreForEachResponse.js → groupedOptionsPartialScoreForEachResponse.smoke.js} +1 -1
  6. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/standardAllOrNothing.smoke.js +164 -0
  7. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/{standardTotalScoreDividedBetweenResponse.js → standardTotalScoreDividedBetweenResponse.smoke.js} +21 -18
  8. package/cypress/e2e/ILC/EditTabSettingPage/ItemPreviewSettingsTabContent.js +753 -0
  9. package/cypress/e2e/ILC/EssayResponse/essayResponseCreateCustomCategory.smoke.js +943 -0
  10. package/cypress/e2e/ILC/EssayResponse/{essayResponseCustomizeFormattingOptions1.js → essayResponseCustomizeFormattingOptions1.smoke.js} +113 -110
  11. package/cypress/e2e/ILC/EssayResponse/essayResponseEquationEditor.smoke.js +581 -0
  12. package/cypress/e2e/ILC/EssayResponse/essayResponseGradingViewAndCorrectAnswerViewContents.smoke.js +111 -0
  13. package/cypress/e2e/ILC/EssayResponse/{essayResponsePreviewContentsForAllViews.js → essayResponsePreviewContentsForAllViews.smoke.js} +6 -3
  14. package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedEditTab.smoke.js +81 -0
  15. package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/{fillInTheGapsDragAndDropGroupedOptionsAllOrNothingScoring.js → fillInTheGapsDragAndDropGroupedOptionsAllOrNothingScoring.smoke.js} +25 -22
  16. package/cypress/e2e/ILC/FillInTheGapsDropdown/{fillInTheGapsDropdownAllOrNothingScoring.js → fillInTheGapsDropdownAllOrNothingScoring.smoke.js} +16 -14
  17. package/cypress/e2e/ILC/{fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAddResponseContainer.js → FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAddResponseContainer.smoke.js} +80 -74
  18. package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAllOrNothingScoring.smoke.js +361 -0
  19. package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownEditAriaLabelCheckbox.smoke.js +137 -0
  20. package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownImageProperties.smoke.js +171 -0
  21. package/cypress/e2e/ILC/{fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPreviewTab.js → FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPreviewTab.smoke.js} +1 -1
  22. package/cypress/e2e/ILC/FillInTheGapsOverImageText/{fillInTheGapsOverImageTextAllOrNothingScoring.js → fillInTheGapsOverImageTextAllOrNothingScoring.smoke.js} +32 -29
  23. package/cypress/e2e/ILC/FillInTheGapsOverImageText/{fillInTheGapsOverImageTextCheckAnswerForAllViews.js → fillInTheGapsOverImageTextCheckAnswerForAllViews.smoke.js} +5 -3
  24. package/cypress/e2e/ILC/FillInTheGapsOverImageText/fillInTheGapsOverImageTextEditAriaLabelCheckbox.smoke.js +137 -0
  25. package/cypress/e2e/ILC/FillInTheGapsOverImageText/fillInTheGapsOverImageTextEditTabBasicSection.smoke.js +146 -0
  26. package/cypress/e2e/ILC/FillInTheGapsOverImageText/{fillInTheGapsOverImageTextPreviewContentsForAllViews.js → fillInTheGapsOverImageTextPreviewContentsForAllViews.smoke.js} +5 -3
  27. package/cypress/e2e/ILC/FillInTheGapsOverImageText/{fillInTheGapsOverImageTextPreviewTab.js → fillInTheGapsOverImageTextPreviewTab.smoke.js} +1 -1
  28. package/cypress/e2e/ILC/FillInTheGapsOverImageText/{fillInTheGapsOverImageTextShowCorrectAnswerForAllView.js → fillInTheGapsOverImageTextShowCorrectAnswerForAllView.smoke.js} +6 -4
  29. package/cypress/e2e/ILC/FillInTheGapsText/{fillInTheGapsTextAutoScoredScoring.js → fillInTheGapsTextAutoScoredScoring.smoke.js} +12 -9
  30. package/cypress/e2e/ILC/Highlight/HighlightScoring/{allOrNothingScoring.js → allOrNothingScoring.smoke.js} +36 -34
  31. package/cypress/e2e/ILC/Highlight/HighlightScoring/highlightBasicScoringForTextSelectionTypes.smoke.js +462 -0
  32. package/cypress/e2e/ILC/Highlight/highlightColorLibraryFlyout.smoke.js +148 -0
  33. package/cypress/e2e/ILC/Highlight/highlightQuestionInstructionsAndQuestion.smoke.js +185 -0
  34. package/cypress/e2e/ILC/HighlightImage/highlightImageEditTabBasic.smoke.js +138 -0
  35. package/cypress/e2e/ILC/HighlightImage/{highlightImagePreviewTab.js → highlightImagePreviewTab.smoke.js} +1 -1
  36. package/cypress/e2e/ILC/HighlightImage/{highlightImageToolsFunctionalityPreviewTab.js → highlightImageToolsFunctionalityPreviewTab.smoke.js} +4 -4
  37. package/cypress/e2e/ILC/ListMatching/ListMatchingScoring/groupedOptionsAllOrNothingScoring.smoke.js +122 -0
  38. package/cypress/e2e/ILC/ListMatching/{listMatchingAlternateAnswer.js → listMatchingAlternateAnswer.smoke.js} +47 -43
  39. package/cypress/e2e/ILC/ListMatching/listMatchingGroupedOptionsSection.smoke.js +211 -0
  40. package/cypress/e2e/ILC/ListMatching/listMatchingQuestionInstructionsAndStemsSection.smoke.js +254 -0
  41. package/cypress/e2e/ILC/ListMatching/listMatchingStandardOptionsSetCorrectAnswerCheckboxesPreviewTab.smoke.js +191 -0
  42. package/cypress/e2e/ILC/ListOrdering/ListOrderingScoring/{allOrNothingScoring.js → allOrNothingScoring.smoke.js} +34 -32
  43. package/cypress/e2e/ILC/ListSorting/ListSortingScoring/{allOrNothingScoring.js → allOrNothingScoring.smoke.js} +41 -38
  44. package/cypress/e2e/ILC/ListSorting/listSortingSetCorrectAnswerCheckboxes.smoke.js +269 -0
  45. package/cypress/e2e/ILC/MultipleSelectionGrid/{multipleSelectionGridAutoScoredScoring.js → multipleSelectionGridAutoScoredScoring.smoke.js} +36 -34
  46. package/cypress/e2e/ILC/ShortTextResponse/shortTextResponseAutoScoredScoring.smoke.js +407 -0
  47. package/cypress/e2e/ILC/SingleSelectionGrid/{singleSelectionGridAutoScoredScoring.js → singleSelectionGridAutoScoredScoring.smoke.js} +32 -29
  48. package/cypress/e2e/ILC/UploadResponse/{uploadResponsePreview.js → uploadResponsePreview.smoke.js} +64 -59
  49. package/cypress/e2e/ILC/VideoResponse/{videoResponsePreviewTab.js → videoResponsePreviewTab.smoke.js} +290 -281
  50. package/cypress/pages/components/additionalSettingsPanel.js +0 -27
  51. package/cypress/pages/components/autoScoredSetCorrectAnswerSection.js +1 -1
  52. package/cypress/pages/components/autoScoredSpecifyCorrectAnswerSection.js +321 -0
  53. package/cypress/pages/components/createQuestionBasePage.js +1 -7
  54. package/cypress/pages/components/essayResponseCommonComponents.js +0 -6
  55. package/cypress/pages/components/fillInTheGapsCommonComponents.js +0 -13
  56. package/cypress/pages/components/index.js +2 -1
  57. package/cypress/pages/components/mcqAdditionalSettingsBase.js +0 -10
  58. package/cypress/pages/components/scoringSectionBase.js +3 -2
  59. package/cypress/pages/createItemPage.js +3 -79
  60. package/cypress/pages/dialogBoxBase.js +8 -23
  61. package/cypress/pages/index.js +1 -4
  62. package/cypress/pages/itemPreviewSettingsPage.js +446 -0
  63. package/cypress/pages/multipleSelectionPage.js +113 -64
  64. package/cypress/pages/selectQuestionResourceToolPage.js +0 -5
  65. package/cypress/pages/shortTextResponsePage.js +0 -6
  66. package/cypress/pages/singleSelectionPage.js +0 -1
  67. package/package.json +2 -2
  68. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/groupedOptionsAllOrNothing.js +0 -116
  69. package/cypress/e2e/ILC/DragAndDropIntoCategories/dragAndDropIntoCategoriesScoring/standardAllOrNothing.js +0 -160
  70. package/cypress/e2e/ILC/EssayResponse/essayResponseCreateCustomCategory.js +0 -932
  71. package/cypress/e2e/ILC/EssayResponse/essayResponseEquationEditor.js +0 -572
  72. package/cypress/e2e/ILC/EssayResponse/essayResponseGradingViewAndCorrectAnswerViewContents.js +0 -106
  73. package/cypress/e2e/ILC/FillInTheGapsDragAndDrop/fillInTheGapsDragAndDropGroupedEditTab.js +0 -76
  74. package/cypress/e2e/ILC/FillInTheGapsOverImageText/fillInTheGapsOverImageTextEditAriaLabelCheckbox.js +0 -134
  75. package/cypress/e2e/ILC/FillInTheGapsOverImageText/fillInTheGapsOverImageTextEditTabBasicSection.js +0 -133
  76. package/cypress/e2e/ILC/Highlight/HighlightScoring/highlightBasicScoringForTextSelectionTypes.js +0 -457
  77. package/cypress/e2e/ILC/Highlight/highlightColorLibraryFlyout.js +0 -143
  78. package/cypress/e2e/ILC/Highlight/highlightQuestionInstructionsAndQuestion.js +0 -178
  79. package/cypress/e2e/ILC/HighlightImage/highlightImageEditTabBasic.js +0 -125
  80. package/cypress/e2e/ILC/ListMatching/ListMatchingScoring/groupedOptionsAllOrNothingScoring.js +0 -117
  81. package/cypress/e2e/ILC/ListMatching/listMatchingGroupedOptionsSection.js +0 -207
  82. package/cypress/e2e/ILC/ListMatching/listMatchingQuestionInstructionsAndStemsSection.js +0 -246
  83. package/cypress/e2e/ILC/ListMatching/listMatchingStandardOptionsSetCorrectAnswerCheckboxesPreviewTab.js +0 -185
  84. package/cypress/e2e/ILC/ListSorting/listSortingAdditionalSettings.js +0 -820
  85. package/cypress/e2e/ILC/ListSorting/listSortingAutoScoredScoring.js +0 -936
  86. package/cypress/e2e/ILC/ListSorting/listSortingSetCorrectAnswerCheckboxes.js +0 -263
  87. package/cypress/e2e/ILC/ShortTextResponse/shortTextResponseAutoScoredScoring.js +0 -402
  88. package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAllOrNothingScoring.js +0 -356
  89. package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownEditAriaLabelCheckbox.js +0 -134
  90. package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownImageProperties.js +0 -156
@@ -0,0 +1,191 @@
1
+ import { listMatchingPage } from "../../../pages";
2
+ import abortEarlySetup from "../../../support/helpers/abortEarly";
3
+ const grepTags = Cypress.env('grepTags');
4
+ let stems = ['Stem 1', 'Stem 2', 'Stem 3'];
5
+ let optionsForResponses = ['Correct answer for stem 1', 'Correct answer for stem 2', 'Correct answer for stem 3'];
6
+
7
+ describe('Create Item page - List Matching: Randomize options, Reuse options, Hide drag handle functionalities for \'Standard\' response option layout in preview tab', () => {
8
+ before(() => {
9
+ cy.loginAs('admin');
10
+ });
11
+
12
+ describe('Randomize options - Functionality : Preview tab', { tags: 'smoke' }, () => {
13
+ let optionsArray = [];
14
+ let stemsArray = [];
15
+ abortEarlySetup();
16
+ before(() => {
17
+ cy.log('Navigating to List Matching question type');
18
+ listMatchingPage.steps.navigateToCreateQuestion('list matching');
19
+ cy.barsPreLoaderWait();
20
+ listMatchingPage.steps.addInputToAllStemFields(stems);
21
+ listMatchingPage.steps.addInputToOptionsForDragAndDropFields(optionsForResponses);
22
+ listMatchingPage.steps.allotPoints('10');
23
+ listMatchingPage.steps.switchToPreviewTab();
24
+ });
25
+
26
+ it('When the \'Randomize options\' functionality is disabled, then the draggable options in the response container should be displayed in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
27
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
28
+ });
29
+
30
+ it('When the \'Randomize options\' functionality is disabled, the stem fields should be displayed in the order in which the user has set them in the Stems section', () => {
31
+ listMatchingPage.steps.verifyStemFieldsInPreviewTab(stems);
32
+ });
33
+
34
+ it('When the user enables the \'Randomize options\' functionality, then the draggable options in the response container should be displayed in a random order', () => {
35
+ listMatchingPage.steps.switchToEditTab();
36
+ listMatchingPage.steps.checkRandomizeOptionsCheckbox();
37
+ cy.log('Added wait here to prevent cypress from switching to preview tab just after checking randomize options checkbox');
38
+ cy.wait(1000);
39
+ listMatchingPage.steps.switchToPreviewTab();
40
+ listMatchingPage.steps.verifyRandomizeOptionOrder(optionsForResponses, 'List matching');
41
+ optionsArray = listMatchingPage.steps.getOptionsArray('List Matching');
42
+ });
43
+
44
+ it('When the user enables the \'Randomize options\' functionality, then the stem fields should be displayed in a random order', () => {
45
+ listMatchingPage.steps.verifyRandomizedStemsOrder(stems);
46
+ stemsArray = listMatchingPage.steps.getStemsArray();
47
+ });
48
+
49
+ it('When the user switches to \'Edit tab\' and does not modify any question properties, then the order of the draggable options should not change in the response container', () => {
50
+ listMatchingPage.steps.switchToEditTab();
51
+ listMatchingPage.steps.switchToPreviewTab();
52
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsArray);
53
+ });
54
+
55
+ it('When the user switches to \'Edit tab\' and does not modify any question properties, then the order of the stem fields should not change in the response container', () => {
56
+ listMatchingPage.steps.switchToEditTab();
57
+ listMatchingPage.steps.switchToPreviewTab();
58
+ listMatchingPage.steps.verifyStemFieldsInPreviewTab(stemsArray);
59
+ });
60
+
61
+ it('When the user switches to \'Edit tab\' and modifies any of question properties, then the order of the draggable options should change in the response container', () => {
62
+ listMatchingPage.steps.switchToEditTab();
63
+ listMatchingPage.steps.allotPoints(5);
64
+ cy.log('Added wait here to prevent cypress from switching to preview tab just after modifying the question');
65
+ cy.wait(1000);
66
+ listMatchingPage.steps.switchToPreviewTab();
67
+ listMatchingPage.steps.verifyRandomizeOptionOrder(optionsForResponses, 'List matching');
68
+ listMatchingPage.steps.verifyRerandomizedOptionsOrder(optionsArray, 'List matching')
69
+ });
70
+
71
+ it('When the user switches to \'Edit tab\' and modifies any of question properties, then the order of the stem fields should change in the response container', () => {
72
+ listMatchingPage.steps.switchToEditTab();
73
+ listMatchingPage.steps.selectPartialEqualWeightsCheckbox();
74
+ cy.log('Added wait here to prevent cypress from switching to preview tab just after modifying the question');
75
+ cy.wait(1000);
76
+ listMatchingPage.steps.switchToPreviewTab();
77
+ listMatchingPage.steps.verifyRandomizedStemsOrder(stems);
78
+ listMatchingPage.steps.verifyRerandomizedStemsOrder(stemsArray);
79
+ });
80
+
81
+ it('When the user disables the \'Randomize options\' functionality, then the draggable options in the response container should be displayed in the order in which the user has set them in the \'Options for drag & drop\' section', () => {
82
+ listMatchingPage.steps.switchToEditTab();
83
+ listMatchingPage.steps.uncheckRandomizeOptionsCheckbox();
84
+ listMatchingPage.steps.switchToPreviewTab();
85
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
86
+ });
87
+
88
+ it('When the user has disabled the \'Randomize options\' functionality, then the stem fields should be displayed in the order in which the user has set them in the set correct answer section', () => {
89
+ listMatchingPage.steps.verifyStemFieldsInPreviewTab(stems)
90
+ });
91
+ });
92
+
93
+ if (!grepTags || !grepTags.includes('smoke')) {
94
+ describe('Reuse options - Functionality: Preview tab', () => {
95
+ abortEarlySetup();
96
+ before(() => {
97
+ cy.log('Navigating to List Matching question type');
98
+ listMatchingPage.steps.navigateToCreateQuestion('list matching');
99
+ cy.barsPreLoaderWait();
100
+ listMatchingPage.steps.addInputToOptionsForDragAndDropFields(optionsForResponses);
101
+ });
102
+
103
+ it('When the \'Reuse options\' functionality is disabled, then on attempting the question, the draggable options should get removed from the response container', () => {
104
+ listMatchingPage.steps.switchToPreviewTab();
105
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 0);
106
+ listMatchingPage.steps.verifyFilledOptionResponseAreaInPreviewTab(0, 'Correct answer for stem 1')
107
+ listMatchingPage.steps.verifyOptionsInPreviewTab([optionsForResponses[1], optionsForResponses[2]]);
108
+ });
109
+
110
+ it('When the \'Reuse options\' functionality is enabled, then on attempting the question, the draggable options should persist in the response container', () => {
111
+ listMatchingPage.steps.switchToEditTab();
112
+ listMatchingPage.steps.checkReuseOptionsCheckbox();
113
+ listMatchingPage.steps.switchToPreviewTab();
114
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 0);
115
+ listMatchingPage.steps.verifyFilledOptionResponseAreaInPreviewTab(0, 'Correct answer for stem 1');
116
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
117
+ });
118
+
119
+ it('The user should be able to use the same draggable option for multiple response areas', () => {
120
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 0);
121
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 1);
122
+ listMatchingPage.steps.verifyFilledOptionResponseAreaInPreviewTab(0, 'Correct answer for stem 1');
123
+ listMatchingPage.steps.verifyFilledOptionResponseAreaInPreviewTab(1, 'Correct answer for stem 1');
124
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
125
+ });
126
+
127
+ it('When the user removes the option from the response area and moves it into the grouped container, only one option should be displayed in the respective group', () => {
128
+ listMatchingPage.steps.clickAndDropOptionFromResponseAreaToDraggableOptionsContainerInPreviewTab(0);
129
+ listMatchingPage.steps.clickAndDropOptionFromResponseAreaToDraggableOptionsContainerInPreviewTab(1);
130
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
131
+ });
132
+
133
+ it('When the user disables the \'Reuse options\' functionality, then on attempting the question, the draggable options should get removed from the response container', () => {
134
+ listMatchingPage.steps.switchToEditTab();
135
+ listMatchingPage.steps.uncheckReuseOptionsCheckbox();
136
+ listMatchingPage.steps.switchToPreviewTab();
137
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 0);
138
+ listMatchingPage.steps.verifyFilledOptionResponseAreaInPreviewTab(0, 'Correct answer for stem 1');
139
+ listMatchingPage.steps.verifyOptionsInPreviewTab([optionsForResponses[1], optionsForResponses[2]]);
140
+ });
141
+ });
142
+ }
143
+
144
+ if (!grepTags || !grepTags.includes('smoke')) {
145
+ describe('Reuse options - Scoring', () => {
146
+ abortEarlySetup();
147
+ before(() => {
148
+ cy.log('Navigating to List Matching question type');
149
+ listMatchingPage.steps.navigateToCreateQuestion('list matching');
150
+ cy.barsPreLoaderWait();
151
+ listMatchingPage.steps.addInputToOptionsForDragAndDropFields(optionsForResponses);
152
+ listMatchingPage.steps.checkReuseOptionsCheckbox();
153
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInSetCorrectAnswerSection('Correct answer for stem 1', 0);
154
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInSetCorrectAnswerSection('Correct answer for stem 1', 1);
155
+ listMatchingPage.steps.allotPoints(5);
156
+ listMatchingPage.steps.switchToPreviewTab();
157
+ });
158
+
159
+ it('When the user has set same answer options in the \'Set correct answer\' section, then the user should be awarded full points on attempting the question with reused options', () => {
160
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 0);
161
+ listMatchingPage.steps.clickAndDropOptionInStemResponseAreaInPreviewTab('Correct answer for stem 1', 1);
162
+ listMatchingPage.previewScoreText()
163
+ .verifyInnerText('5/5');
164
+ listMatchingPage.steps.verifyOptionsInPreviewTab(optionsForResponses);
165
+ });
166
+ });
167
+ }
168
+
169
+ if (!grepTags || !grepTags.includes('smoke')) {
170
+ describe('Hide drag handle - Functionality: Preview tab', () => {
171
+ abortEarlySetup();
172
+ before(() => {
173
+ cy.log('Navigating to List Matching question type');
174
+ listMatchingPage.steps.navigateToCreateQuestion('list matching');
175
+ cy.barsPreLoaderWait();
176
+ });
177
+
178
+ it('When the \'Hide drag handle\' functionality is disabled, then the draggable options displayed in response container of the preview tab should have a drag handle', () => {
179
+ listMatchingPage.steps.switchToPreviewTab();
180
+ listMatchingPage.steps.verifyDragIconVisibleInOptionsInPreviewTab('list matching');
181
+ });
182
+
183
+ it('When the \'Hide drag handle\' functionality is enabled, then the draggable options displayed in response container of the preview tab should not have a drag handle', () => {
184
+ listMatchingPage.steps.switchToEditTab();
185
+ listMatchingPage.steps.checkHideDragHandleCheckbox();
186
+ listMatchingPage.steps.switchToPreviewTab();
187
+ listMatchingPage.steps.verifyDragIconNotVisibleInOptionsInPreviewTab('list matching');
188
+ });
189
+ });
190
+ }
191
+ });
@@ -1,7 +1,7 @@
1
1
  import { listOrderingPage } from "../../../../pages/listOrderingPage";
2
2
  import abortEarlySetup from "../../../../support/helpers/abortEarly";
3
3
  import utilities from "../../../../support/helpers/utilities";
4
-
4
+ const grepTags = Cypress.env('grepTags');
5
5
  let options = ['sprout', 'plant', 'flower', 'seed'];
6
6
  let correctAnswerArray = ['seed', 'sprout', 'plant', 'flower'];
7
7
  let alternateCorrectAnswerArray = ['seed', 'flower', 'sprout', 'plant'];
@@ -11,39 +11,41 @@ describe('Create Item page - List ordering: All or nothing scoring', () => {
11
11
  cy.loginAs('admin');
12
12
  });
13
13
 
14
- describe('Show correct answer', () => {
15
- abortEarlySetup();
16
- before(() => {
17
- cy.log('Navigating to list ordering question type');
18
- listOrderingPage.steps.navigateToCreateQuestion('list ordering');
19
- cy.barsPreLoaderWait();
20
- listOrderingPage.steps.addQuestionInstructions();
21
- listOrderingPage.steps.addInputToOptionsInputField(options);
22
- });
23
-
24
- listOrderingPage.tests.verifyShowCorrectAnswerAndPointsInPreviewTabWhenNoCorrectAnswerIsSet()
25
-
26
- it('When the user has set correct answer options and alloted points \'Show correct answer\' checkbox should be displayed and it should be unchecked by default and points for the question should be displayed beside it', () => {
27
- listOrderingPage.steps.switchToEditTab();
28
- listOrderingPage.steps.clickAndReorderOptionInSetCorrectAnswerSection('seed', 0);
29
- listOrderingPage.steps.clickAndReorderOptionInSetCorrectAnswerSection('sprout', 1);
30
- listOrderingPage.steps.verifyOptionsTextContentInSetCorrectAnswerSection(correctAnswerArray);
31
- listOrderingPage.steps.allotPoints('15');
32
- listOrderingPage.steps.switchToPreviewTab();
33
- listOrderingPage.steps.verifyDefaultShowCorrectAnswerCheckboxAndLabel();
34
- listOrderingPage.steps.verifyPreviewTabScoreText(0, 15);
14
+ if (!grepTags || !grepTags.includes('smoke')) {
15
+ describe('Show correct answer', () => {
16
+ abortEarlySetup();
17
+ before(() => {
18
+ cy.log('Navigating to list ordering question type');
19
+ listOrderingPage.steps.navigateToCreateQuestion('list ordering');
20
+ cy.barsPreLoaderWait();
21
+ listOrderingPage.steps.addQuestionInstructions();
22
+ listOrderingPage.steps.addInputToOptionsInputField(options);
23
+ });
24
+
25
+ listOrderingPage.tests.verifyShowCorrectAnswerAndPointsInPreviewTabWhenNoCorrectAnswerIsSet()
26
+
27
+ it('When the user has set correct answer options and alloted points \'Show correct answer\' checkbox should be displayed and it should be unchecked by default and points for the question should be displayed beside it', () => {
28
+ listOrderingPage.steps.switchToEditTab();
29
+ listOrderingPage.steps.clickAndReorderOptionInSetCorrectAnswerSection('seed', 0);
30
+ listOrderingPage.steps.clickAndReorderOptionInSetCorrectAnswerSection('sprout', 1);
31
+ listOrderingPage.steps.verifyOptionsTextContentInSetCorrectAnswerSection(correctAnswerArray);
32
+ listOrderingPage.steps.allotPoints('15');
33
+ listOrderingPage.steps.switchToPreviewTab();
34
+ listOrderingPage.steps.verifyDefaultShowCorrectAnswerCheckboxAndLabel();
35
+ listOrderingPage.steps.verifyPreviewTabScoreText(0, 15);
36
+ });
37
+
38
+ it('When the user attempts question in preview tab and switches to edit tab, then on re-switching to the preview tab users response should not persist', () => {
39
+ listOrderingPage.steps.clickAndReorderOptionInPrevewTab('seed', 0);
40
+ listOrderingPage.steps.clickAndReorderOptionInPrevewTab('sprout', 1);
41
+ listOrderingPage.steps.verifyTextContentOfOptionsInPreviewTab(correctAnswerArray)
42
+ listOrderingPage.steps.resetQuestionPreview(options);
43
+ listOrderingPage.steps.verifyCorrectAnswerContainerDoesNotExist();
44
+ });
35
45
  });
46
+ }
36
47
 
37
- it('When the user attempts question in preview tab and switches to edit tab, then on re-switching to the preview tab users response should not persist', () => {
38
- listOrderingPage.steps.clickAndReorderOptionInPrevewTab('seed', 0);
39
- listOrderingPage.steps.clickAndReorderOptionInPrevewTab('sprout', 1);
40
- listOrderingPage.steps.verifyTextContentOfOptionsInPreviewTab(correctAnswerArray)
41
- listOrderingPage.steps.resetQuestionPreview(options);
42
- listOrderingPage.steps.verifyCorrectAnswerContainerDoesNotExist();
43
- });
44
- });
45
-
46
- describe('Question Preview: AutoScored - All or Nothing scoring', () => {
48
+ describe('Question Preview: AutoScored - All or Nothing scoring', { tags: 'smoke' }, () => {
47
49
  abortEarlySetup();
48
50
  before(() => {
49
51
  cy.log('Navigating to list ordering question type');
@@ -4,51 +4,54 @@ import utilities from "../../../../support/helpers/utilities";
4
4
 
5
5
  let options = ['plant', 'sprout', 'flower', 'seed'];
6
6
  let correctAnswerArray = ['seed', 'sprout', 'plant', 'flower'];
7
+ const grepTags = Cypress.env('grepTags');
7
8
 
8
9
  describe('Create item page - List sorting: All or nothing scoring', () => {
9
10
  before(() => {
10
11
  cy.loginAs('admin');
11
12
  });
12
13
 
13
- describe('Show correct answer', () => {
14
- abortEarlySetup();
15
- before(() => {
16
- cy.log('Navigating to list sorting question type');
17
- listSortingPage.steps.navigateToCreateQuestion('list sorting');
18
- cy.barsPreLoaderWait();
19
- listSortingPage.steps.addQuestionInstructions();
20
- listSortingPage.steps.addInputToOptionsInputField(options);
21
- });
22
-
23
- //Failing due to - https://redmine.zeuslearning.com/issues/539911
24
- listSortingPage.tests.verifyShowCorrectAnswerAndPointsInPreviewTabWhenNoCorrectAnswerIsSet()
25
-
26
- it('When the user has set correct answer options and alloted points \'Show correct answer\' checkbox should be displayed and it should be unchecked by default and points for the question should be displayed beside it', () => {
27
- listSortingPage.steps.switchToEditTab();
28
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('seed', 0);
29
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('sprout', 1);
30
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('plant', 2);
31
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('flower', 3);
32
- listSortingPage.steps.verifyTargetOptionsTextContentInSetCorrectAnswerSection(correctAnswerArray);
33
- listSortingPage.steps.allotPoints('15');
34
- listSortingPage.steps.switchToPreviewTab();
35
- listSortingPage.steps.verifyDefaultShowCorrectAnswerCheckboxAndLabel();
36
- listSortingPage.steps.verifyPreviewTabScoreText(0, 15);
14
+ if (!grepTags || !grepTags.includes('smoke')) {
15
+ describe('Show correct answer', () => {
16
+ abortEarlySetup();
17
+ before(() => {
18
+ cy.log('Navigating to list sorting question type');
19
+ listSortingPage.steps.navigateToCreateQuestion('list sorting');
20
+ cy.barsPreLoaderWait();
21
+ listSortingPage.steps.addQuestionInstructions();
22
+ listSortingPage.steps.addInputToOptionsInputField(options);
23
+ });
24
+
25
+ //Failing due to - https://redmine.zeuslearning.com/issues/539911
26
+ listSortingPage.tests.verifyShowCorrectAnswerAndPointsInPreviewTabWhenNoCorrectAnswerIsSet()
27
+
28
+ it('When the user has set correct answer options and alloted points \'Show correct answer\' checkbox should be displayed and it should be unchecked by default and points for the question should be displayed beside it', () => {
29
+ listSortingPage.steps.switchToEditTab();
30
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('seed', 0);
31
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('sprout', 1);
32
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('plant', 2);
33
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInSetCorrectAnswerSection('flower', 3);
34
+ listSortingPage.steps.verifyTargetOptionsTextContentInSetCorrectAnswerSection(correctAnswerArray);
35
+ listSortingPage.steps.allotPoints('15');
36
+ listSortingPage.steps.switchToPreviewTab();
37
+ listSortingPage.steps.verifyDefaultShowCorrectAnswerCheckboxAndLabel();
38
+ listSortingPage.steps.verifyPreviewTabScoreText(0, 15);
39
+ });
40
+
41
+ it('When the user attempts question in preview tab and switches to edit tab, then on re-switching to the preview tab users response should not persist', () => {
42
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('seed', 0);
43
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('sprout', 1);
44
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('plant', 2);
45
+ listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('flower', 3);
46
+ listSortingPage.steps.verifyTargetOptionsTextContentInPreviewTab(correctAnswerArray)
47
+ listSortingPage.steps.resetQuestionPreview();
48
+ listSortingPage.steps.verifySourceOptionsTextContentInPreviewTab(options);
49
+ listSortingPage.steps.verifyCorrectAnswerContainerDoesNotExist();
50
+ });
37
51
  });
52
+ }
38
53
 
39
- it('When the user attempts question in preview tab and switches to edit tab, then on re-switching to the preview tab users response should not persist', () => {
40
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('seed', 0);
41
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('sprout', 1);
42
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('plant', 2);
43
- listSortingPage.steps.clickAndDropOptionFromSourceToTargetInPreviewTab('flower', 3);
44
- listSortingPage.steps.verifyTargetOptionsTextContentInPreviewTab(correctAnswerArray)
45
- listSortingPage.steps.resetQuestionPreview();
46
- listSortingPage.steps.verifySourceOptionsTextContentInPreviewTab(options);
47
- listSortingPage.steps.verifyCorrectAnswerContainerDoesNotExist();
48
- });
49
- });
50
-
51
- describe('Question Preview: AutoScored - All or Nothing', () => {
54
+ describe('Question Preview: AutoScored - All or Nothing', { tags: 'smoke' }, () => {
52
55
  abortEarlySetup();
53
56
  before(() => {
54
57
  cy.log('Navigating to list sorting question type');
@@ -184,5 +187,5 @@ describe('Create item page - List sorting: All or nothing scoring', () => {
184
187
  listSortingPage.tests.verifyCSSAndA11yOfFullScoreTextAndCorrectAnswerLabel()
185
188
 
186
189
  listSortingPage.tests.verifyMinimumScoreAwardedIfAttemptedFunctionalityForIncorrectAnswer('20');
187
- });
190
+ });
188
191
  });