itemengine-cypress-automation 1.0.249-repoUpdated26thSept-d6c4173.0 → 1.0.250-30SeptUpdates-a6d872b.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (156) hide show
  1. package/cypress/e2e/ILC/AudioResponseNew/additionalSettingsBasic.js +1 -1
  2. package/cypress/e2e/ILC/AudioResponseNew/gradingViewAndCorrectAnswerViewContents.smoke.js +2 -3
  3. package/cypress/e2e/ILC/AudioResponseNew/headerSection.js +1 -1
  4. package/cypress/e2e/ILC/AudioResponseNew/previewContentsForAllViews.smoke.js +1 -2
  5. package/cypress/e2e/ILC/BrainingCampManipulative/additionalSettings.js +1 -1
  6. package/cypress/e2e/ILC/BrainingCampManipulative/gradingViewAndCorrectAnswerViewContents.smoke.js +1 -2
  7. package/cypress/e2e/ILC/BrainingCampManipulative/headerSection.js +1 -2
  8. package/cypress/e2e/ILC/BrainingCampManipulative/previewTabContent.smoke.js +1 -1
  9. package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/allOrNothingScoringForAllViews.smoke.js +1 -1
  10. package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/gradingViewAndCorrectAnswerView.smoke.js +2 -3
  11. package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/previewContentsForAllViews.smoke.js +1 -1
  12. package/cypress/e2e/ILC/ChartsBar/chartFunctionalitySpecifyCorrectAnswerSection.js +2 -2
  13. package/cypress/e2e/ILC/ChartsBar/gradingViewAndCorrectAnswerView.smoke.js +3 -4
  14. package/cypress/e2e/ILC/ChartsBar/headerSection.js +2 -2
  15. package/cypress/e2e/ILC/ChartsBar/previewContentsForAllViews.smoke.js +1 -1
  16. package/cypress/e2e/ILC/ChartsBar/selectChartTypeSection.js +8 -8
  17. package/cypress/e2e/ILC/ChartsBar/studentViewSettings.js +0 -1
  18. package/cypress/e2e/ILC/ChartsLine/allOrNothingScoringForAllViews.smoke.js +1 -1
  19. package/cypress/e2e/ILC/ChartsLine/chartFunctionalitySpecifyCorrectAnswerSection.js +2 -2
  20. package/cypress/e2e/ILC/ChartsLine/gradingViewAndCorrectAnswerView.smoke.js +2 -3
  21. package/cypress/e2e/ILC/ChartsLine/previewContentsForAllViews.smoke.js +1 -1
  22. package/cypress/e2e/ILC/Compass/compassPreviewContent.smoke.js +1 -1
  23. package/cypress/e2e/ILC/ContentBlocks/previewContents.smoke.js +1 -1
  24. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/allOrNothingBasicForAllViews.smoke.js +1 -1
  25. package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/previewContentsForAllViews.smoke.js +1 -2
  26. package/cypress/e2e/ILC/DrawingResponse/drawingResponseCustomizeAdditionalOptions.js +3 -5
  27. package/cypress/e2e/ILC/DrawingResponse/drawingResponseGradingViewAndCorrectAnswerViewContents.smoke.js +2 -6
  28. package/cypress/e2e/ILC/DrawingResponse/drawingResponsePageHeaderSection.js +1 -1
  29. package/cypress/e2e/ILC/DrawingResponse/drawingResponsePreviewTabContents.smoke.js +2 -4
  30. package/cypress/e2e/ILC/EssayResponse/additionalSettings.js +4 -4
  31. package/cypress/e2e/ILC/EssayResponse/gradingViewAndCorrectAnswerViewContents.smoke.js +2 -3
  32. package/cypress/e2e/ILC/EssayResponse/previewContentsForAllViews.smoke.js +1 -1
  33. package/cypress/e2e/ILC/EssayResponseBasic/previewContentsForAllViews.smoke.js +1 -1
  34. package/cypress/e2e/ILC/FeedbackScaleNew/previewContentsForAllViews.smoke.js +1 -1
  35. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/additionalSettings.js +1 -1
  36. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/allOrNothingForAllViews.smoke.js +1 -1
  37. package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/previewContentsForAllViews.smoke.js +1 -1
  38. package/cypress/e2e/ILC/FillInTheGapsDropdownNew/Scoring/responseLevelAlternateAnswerBasicScoring.js +75 -0
  39. package/cypress/e2e/ILC/FillInTheGapsDropdownNew/dropdownAlternateAnswerPopup.js +162 -0
  40. package/cypress/e2e/ILC/ImageHighlight/additionalSettingsBasic.js +0 -2
  41. package/cypress/e2e/ILC/ImageHighlight/imageHighlightStyle.js +1 -1
  42. package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/manuallyAndNonScored.js +2 -2
  43. package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/partialDifferentWeightsBasic.js +1 -1
  44. package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/HorizontalOrientation/specifyCorrectAnswerSection.js +2 -2
  45. package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +1 -1
  46. package/cypress/e2e/ILC/ListOrderingReorderAsASeperateList/specifyCorrectAnswerSection.js +1 -1
  47. package/cypress/e2e/ILC/Matching/allOrNothingScoringForAllViews.smoke.js +1 -1
  48. package/cypress/e2e/ILC/MatchingDropdown/editTabBasicSection.js +1 -1
  49. package/cypress/e2e/ILC/NumberLine/Scoring/manualAndNonScoredScoring.js +1 -1
  50. package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingAlternatePointsGreaterThanCorrectPoints.js +7 -7
  51. package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +7 -7
  52. package/cypress/e2e/ILC/TextEntryMath/Scoring/allOrNothingCorrectPointsGreaterThanAlternatePoints.js +8 -8
  53. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +8 -8
  54. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsCorrectPointsEqualToAlternativePoints.js +8 -8
  55. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsCorrectPointsGreaterThanAlternativePoints.js +8 -8
  56. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialDifferentWeightsScoringBasic.js +8 -8
  57. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsAlternativePointsGreaterThanCorrectPoints.js +8 -8
  58. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsCorrectPointsEqualToAlternativePoints.js +8 -8
  59. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsCorrectPointsGreaterThanAlternativePoints.js +9 -9
  60. package/cypress/e2e/ILC/TextEntryMath/Scoring/partialEqualWeightsScoringBasic.js +6 -6
  61. package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViews.smoke.js +4 -4
  62. package/cypress/e2e/ILC/TextEntryMath/allOrNothingBasicForAllViewsFormulaTemplate.smoke.js +4 -4
  63. package/cypress/e2e/ILC/TextEntryMath/customSettings.js +1373 -0
  64. package/cypress/e2e/ILC/TextEntryMath/editTabBasicSection.js +4 -4
  65. package/cypress/e2e/ILC/TextSelection/ScoringSentence/allOrNothingAlternatePointsMoreThanCorrectPoints.js +161 -0
  66. package/cypress/e2e/ILC/TextSelection/ScoringSentence/allOrNothingCorrectPointsEqualToAlternatePoints.js +162 -0
  67. package/cypress/e2e/ILC/TextSelection/ScoringSentence/allOrNothingCorrectPointsMoreThanAlternatePoints.js +161 -0
  68. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialDifferentWeightsBasic.js +420 -0
  69. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +242 -0
  70. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +242 -0
  71. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +242 -0
  72. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialEqualWeightsBasic.js +130 -0
  73. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +224 -0
  74. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +195 -0
  75. package/cypress/e2e/ILC/TextSelection/ScoringSentence/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +224 -0
  76. package/cypress/e2e/ILC/TextSelection/ScoringWord/allOrNothingAlternatePointsMoreThanCorrectPoints.js +161 -0
  77. package/cypress/e2e/ILC/TextSelection/ScoringWord/allOrNothingCorrectPointsEqualToAlternatePoints.js +162 -0
  78. package/cypress/e2e/ILC/TextSelection/ScoringWord/allOrNothingCorrectPointsMoreThanAlternatePoints.js +161 -0
  79. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialDifferentWeightsBasic.js +420 -0
  80. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +242 -0
  81. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +242 -0
  82. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +242 -0
  83. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialEqualWeightsBasic.js +130 -0
  84. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +225 -0
  85. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +196 -0
  86. package/cypress/e2e/ILC/TextSelection/ScoringWord/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +225 -0
  87. package/cypress/e2e/ILC/chartsDotsPlot/allOrNothingForAllViews.smoke.js +1 -1
  88. package/cypress/e2e/ILC/chartsDotsPlot/gradingViewAndCorrectAnswerView.smoke.js +2 -3
  89. package/cypress/e2e/ILC/chartsDotsPlot/previewContentsForAllViews.smoke.js +2 -2
  90. package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +1 -1
  91. package/cypress/e2e/ILC/chartsDotsPlot/selectChartTypeSection.js +2 -2
  92. package/cypress/e2e/ILC/chartsDotsPlot/specifyCorrectAnswerSection.js +2 -2
  93. package/cypress/pages/audioResponsePage.js +0 -10
  94. package/cypress/pages/chartsBarPage.js +0 -13
  95. package/cypress/pages/chartsDotPlotPage.js +4 -85
  96. package/cypress/pages/chartsLinePage.js +2 -2
  97. package/cypress/pages/components/allowTeachersToDownloadStudentResponseComponent.js +1 -0
  98. package/cypress/pages/components/autoScoredSpecifyCorrectAnswerSection.js +11 -30
  99. package/cypress/pages/components/barAndLineChartComponent.js +0 -10
  100. package/cypress/pages/components/chartsCommonComponent.js +1 -25
  101. package/cypress/pages/components/colorPopupComponent.js +0 -31
  102. package/cypress/pages/components/connectorStyleStyleAndLayoutCustomizationComponent.js +0 -1
  103. package/cypress/pages/components/createQuestionBasePage.js +2 -8
  104. package/cypress/pages/components/customizeSpecialCharacterComponent.js +1 -1
  105. package/cypress/pages/components/draggableOptionContainer.js +1 -1
  106. package/cypress/pages/components/equationEditorFlyout.js +0 -36
  107. package/cypress/pages/components/essayResponseCommonComponents.js +2 -2
  108. package/cypress/pages/components/fillInTheGapsDropdownCommonComponent.js +2 -15
  109. package/cypress/pages/components/fillInTheGapsTextCommonComponent.js +1 -2
  110. package/cypress/pages/components/gridQuestionCommonComponent.js +26 -34
  111. package/cypress/pages/components/imageCanvasComponent.js +7 -9
  112. package/cypress/pages/components/index.js +0 -1
  113. package/cypress/pages/components/listOrderingCommonStyleAndLayoutComponent.js +0 -12
  114. package/cypress/pages/components/mcqAdditionalSettingsBase.js +0 -1
  115. package/cypress/pages/components/optionsWrapperComponent.js +3 -3
  116. package/cypress/pages/components/scoringSectionBaseEditTab.js +2 -2
  117. package/cypress/pages/contentBlocksPage.js +1 -1
  118. package/cypress/pages/createItemPage.js +7 -6
  119. package/cypress/pages/dragAndDropIntoCategoriesPage.js +0 -41
  120. package/cypress/pages/essayResponsePage.js +0 -1
  121. package/cypress/pages/feedbackScalePage.js +0 -1
  122. package/cypress/pages/fillInTheGapsDragAndDropPage.js +1 -1
  123. package/cypress/pages/fillInTheGapsDropdownPage.js +79 -0
  124. package/cypress/pages/graphingPage.js +0 -1
  125. package/cypress/pages/gridFillPage.js +45 -112
  126. package/cypress/pages/imageHighlightPage.js +0 -10
  127. package/cypress/pages/itemPreviewSettingsPage.js +1 -4
  128. package/cypress/pages/listOrderingPage.js +0 -10
  129. package/cypress/pages/matchingPage.js +5 -142
  130. package/cypress/pages/multipleSelectionPage.js +0 -13
  131. package/cypress/pages/numberLineLabelPage.js +1 -1
  132. package/cypress/pages/numberLinePage.js +1 -1
  133. package/cypress/pages/protractorPage.js +1 -3
  134. package/cypress/pages/shortTextResponsePage.js +1 -3
  135. package/cypress/pages/simpleCalculatorPage.js +2 -2
  136. package/cypress/pages/singleSelectionPage.js +0 -10
  137. package/cypress/pages/textEntryMathPage.js +1 -8
  138. package/cypress/pages/textEntryMathWithImagePage.js +16 -38
  139. package/cypress/pages/textSelectionPage.js +34 -43
  140. package/cypress/pages/videoResponsePage.js +0 -5
  141. package/package.json +1 -1
  142. package/cypress/pages/components/customizeHighlightPropertiesComponent.js +0 -318
  143. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringGeneric}/basicScoringForAllTextSelectionTypes.smoke.js +0 -0
  144. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringGeneric}/manuallyAndNonScored.js +0 -0
  145. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringGeneric}/singleSelectionPreviewScoring.js +0 -0
  146. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/allOrNothingAlternatePointsMoreThanCorrectPoints.js +0 -0
  147. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/allOrNothingCorrectPointsEqualToAlternatePoints.js +0 -0
  148. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/allOrNothingCorrectPointsMoreThanAlternatePoints.js +0 -0
  149. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialDifferentWeightsBasic.js +0 -0
  150. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +0 -0
  151. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +0 -0
  152. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +0 -0
  153. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialEqualWeightsBasic.js +0 -0
  154. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +0 -0
  155. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +0 -0
  156. /package/cypress/e2e/ILC/TextSelection/{Scoring → ScoringParagraph}/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +0 -0
@@ -0,0 +1,1373 @@
1
+ import { equationEditorCategoriesAndSymbols } from "../../../fixtures/equationEditorCategoriesAndSymbols ";
2
+ import { textEntryMathPage } from "../../../pages";
3
+ import { equationEditorFlyout } from "../../../pages/components";
4
+ import abortEarlySetup from "../../../support/helpers/abortEarly";
5
+
6
+ describe('Create Item page - Text entry math: Evaluation methods - Custom settings', () => {
7
+ before(() => {
8
+ cy.loginAs('admin');
9
+ });
10
+
11
+ describe(`Text entry math: Symbols are equivalent`, () => {
12
+ abortEarlySetup();
13
+ before(() => {
14
+ textEntryMathPage.steps.navigateToCreateQuestion('Text Entry Math');
15
+ cy.barsPreLoaderWait();
16
+ textEntryMathPage.steps.addTextInQuestionInstructionsInputField('Equivalent structure: Response inputted needs to be in set structure / format to be marked correct');
17
+ textEntryMathPage.steps.clearQuestionInputField();
18
+ textEntryMathPage.steps.addInputToQuestionInputField('Enter response according to set structure')
19
+ textEntryMathPage.steps.addResponseArea();
20
+ textEntryMathPage.steps.allotPoints(20);
21
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
22
+ textEntryMathPage.steps.selectEvaluationMethod('Symbols are equivalent');
23
+ textEntryMathPage.steps.expandAdditionalSettings();
24
+ textEntryMathPage.steps.selectEquationEditorSectionCategories([equationEditorCategoriesAndSymbols.trig.displayName, equationEditorCategoriesAndSymbols.greek.displayName, equationEditorCategoriesAndSymbols.calculus.displayName]);
25
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
26
+ equationEditorFlyout.steps.clearAll();
27
+ equationEditorFlyout.steps.enterQuadraticEquation()
28
+ // textEntryMathPage.steps.selectModalVisibilityTypeButton();
29
+ });
30
+
31
+ //Case sensitive
32
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with same casing then the answer should be treated as correct', () => {
33
+ textEntryMathPage.steps.switchToPreviewTab();
34
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
35
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['y', 'x'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
36
+ equationEditorFlyout.steps.clickOnOkButton();
37
+ textEntryMathPage.steps.switchToGradingView();
38
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
39
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
40
+ });
41
+
42
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with different casing then the answer should be treated as correct', () => {
43
+ textEntryMathPage.steps.resetQuestionPreview();
44
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
45
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
46
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
47
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
48
+ equationEditorFlyout.steps.clickOnOkButton();
49
+ textEntryMathPage.steps.switchToGradingView();
50
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
51
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
52
+ });
53
+
54
+ it('When user checks \'Case sensitive\' checkbox user attempts the question with same casing then the answer should be treated as correct', () => {
55
+ textEntryMathPage.steps.switchToEditTab();
56
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
57
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
58
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Case sensitive');
59
+ textEntryMathPage.steps.switchToPreviewTab();
60
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
61
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['y', 'x'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
62
+ equationEditorFlyout.steps.clickOnOkButton();
63
+ textEntryMathPage.steps.switchToGradingView();
64
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
65
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
66
+ });
67
+
68
+ it('When \'Case sensitive\' checkbox is checked and user attempts the question with different casing then the answer should be treated as incorrect', () => {
69
+ textEntryMathPage.steps.resetQuestionPreview();
70
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
71
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
72
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
73
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
74
+ equationEditorFlyout.steps.clickOnOkButton();
75
+ textEntryMathPage.steps.switchToGradingView();
76
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
77
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
78
+ });
79
+
80
+ //Accept interval notation
81
+ it('When \'Accept interval notation\' checkbox is unchecked and user attempts the question with different interval notations then the answer should be treated as incorrect', () => {
82
+ textEntryMathPage.steps.switchToEditTab();
83
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
84
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
85
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Case sensitive');
86
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
87
+ equationEditorFlyout.steps.clearAll();
88
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
89
+ equationEditorFlyout.steps.clickOnOkButton();
90
+ textEntryMathPage.steps.switchToPreviewTab();
91
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
92
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4)');
93
+ equationEditorFlyout.steps.clickOnOkButton();
94
+ textEntryMathPage.steps.switchToGradingView();
95
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
96
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
97
+ });
98
+
99
+ it('When \'Accept interval notation\' checkbox is unchecked and user attempts the question with same interval notation then the answer should be treated as correct', () => {
100
+ textEntryMathPage.steps.resetQuestionPreview();
101
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
102
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
103
+ equationEditorFlyout.steps.clickOnOkButton();
104
+ textEntryMathPage.steps.switchToGradingView();
105
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
106
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
107
+ });
108
+
109
+ it('When user checks \'Accept interval notation\' checkbox user attempts the question with same notation then the answer should be treated as correct', () => {
110
+ textEntryMathPage.steps.switchToEditTab();
111
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
112
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
113
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Accept interval notation');
114
+ textEntryMathPage.steps.switchToPreviewTab();
115
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
116
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
117
+ equationEditorFlyout.steps.clickOnOkButton();
118
+ textEntryMathPage.steps.switchToGradingView();
119
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
120
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
121
+ });
122
+
123
+ it('When \'Accept interval notation\' checkbox is checked and user attempts the question with different notation then the answer should be treated as correct', () => {
124
+ textEntryMathPage.steps.resetQuestionPreview();
125
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
126
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4)');
127
+ equationEditorFlyout.steps.clickOnOkButton();
128
+ textEntryMathPage.steps.switchToGradingView();
129
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
130
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
131
+ });
132
+
133
+ //Check for equality across sides
134
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
135
+ textEntryMathPage.steps.switchToEditTab();
136
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
137
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
138
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Accept interval notation');
139
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
140
+ equationEditorFlyout.steps.clearAll();
141
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
142
+ equationEditorFlyout.steps.clickOnOkButton();
143
+ textEntryMathPage.steps.switchToPreviewTab();
144
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
145
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
146
+ equationEditorFlyout.steps.clickOnOkButton();
147
+ textEntryMathPage.steps.switchToGradingView();
148
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
149
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
150
+ });
151
+
152
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation differently but maintaining the equality then the answer should be treated as correct', () => {
153
+ textEntryMathPage.steps.resetQuestionPreview();
154
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
155
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6=6');
156
+ equationEditorFlyout.steps.clickOnOkButton();
157
+ textEntryMathPage.steps.switchToGradingView();
158
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
159
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
160
+ });
161
+
162
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation using variables maintaining the equality then the answer should be treated as correct', () => {
163
+ textEntryMathPage.steps.resetQuestionPreview();
164
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
165
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5x');
166
+ equationEditorFlyout.steps.clickOnOkButton();
167
+ textEntryMathPage.steps.switchToGradingView();
168
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
169
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
170
+ });
171
+
172
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the question with different variables across equation the then the answer should be treated as incorrect', () => {
173
+ textEntryMathPage.steps.resetQuestionPreview();
174
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
175
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5y');
176
+ equationEditorFlyout.steps.clickOnOkButton();
177
+ textEntryMathPage.steps.switchToGradingView();
178
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
179
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
180
+ });
181
+
182
+ it('When user checks \'Check for equality across sides\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
183
+ textEntryMathPage.steps.switchToEditTab();
184
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
185
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
186
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Check for equality across sides');
187
+ textEntryMathPage.steps.switchToPreviewTab();
188
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
189
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
190
+ equationEditorFlyout.steps.clickOnOkButton();
191
+ textEntryMathPage.steps.switchToGradingView();
192
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
193
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
194
+ });
195
+
196
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as incorrect', () => {
197
+ textEntryMathPage.steps.resetQuestionPreview();
198
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
199
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6=6');
200
+ equationEditorFlyout.steps.clickOnOkButton();
201
+ textEntryMathPage.steps.switchToGradingView();
202
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
203
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
204
+ });
205
+
206
+ it('When user checks \'Check for equality across sides\' checkbox user attempts the question with variables then the answer should be treated as incorrect', () => {
207
+ textEntryMathPage.steps.resetQuestionPreview();
208
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
209
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5x');
210
+ equationEditorFlyout.steps.clickOnOkButton();
211
+ textEntryMathPage.steps.switchToGradingView();
212
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
213
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
214
+ });
215
+
216
+ //Exclude LaTeX text from validation
217
+ it('When \'Exclude LaTeX text from validation\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
218
+ textEntryMathPage.steps.switchToEditTab();
219
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
220
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
221
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Check for equality across sides');
222
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
223
+ equationEditorFlyout.steps.clearAll();
224
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
225
+ equationEditorFlyout.steps.clickOnOkButton();
226
+ textEntryMathPage.steps.switchToPreviewTab();
227
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
228
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
229
+ equationEditorFlyout.steps.clickOnOkButton();
230
+ textEntryMathPage.steps.switchToGradingView();
231
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
232
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
233
+ });
234
+
235
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the equation differently then the answer should be treated as correct', () => {
236
+ textEntryMathPage.steps.resetQuestionPreview();
237
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
238
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50');
239
+ equationEditorFlyout.steps.clickOnOkButton();
240
+ textEntryMathPage.steps.switchToGradingView();
241
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
242
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
243
+ });
244
+
245
+ it('When \'Exclude LaTeX text from validation\' checkbox is unchecked and user attempts the equation using un-necessary then the answer should be treated as incorrect', () => {
246
+ textEntryMathPage.steps.resetQuestionPreview();
247
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
248
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50+0');
249
+ equationEditorFlyout.steps.clickOnOkButton();
250
+ textEntryMathPage.steps.switchToGradingView();
251
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
252
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
253
+ });
254
+
255
+ it('When user checks \'Exclude LaTeX text from validation\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
256
+ textEntryMathPage.steps.switchToEditTab();
257
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
258
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
259
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Exclude LaTeX text from validation');
260
+ textEntryMathPage.steps.switchToPreviewTab();
261
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
262
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
263
+ equationEditorFlyout.steps.clickOnOkButton();
264
+ textEntryMathPage.steps.switchToGradingView();
265
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
266
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
267
+ });
268
+
269
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the equation differently then the answer should be treated as incorrect', () => {
270
+ textEntryMathPage.steps.resetQuestionPreview();
271
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
272
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50');
273
+ equationEditorFlyout.steps.clickOnOkButton();
274
+ textEntryMathPage.steps.switchToGradingView();
275
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
276
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
277
+ });
278
+
279
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the question with variables then the answer should be treated as correct', () => {
280
+ textEntryMathPage.steps.resetQuestionPreview();
281
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
282
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50+0');
283
+ equationEditorFlyout.steps.clickOnOkButton();
284
+ textEntryMathPage.steps.switchToGradingView();
285
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
286
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
287
+ });
288
+
289
+ //Interpret alphabets as variables
290
+ it('When \'Interpret alphabets as variables\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
291
+ textEntryMathPage.steps.switchToEditTab();
292
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
293
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
294
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Exclude LaTeX text from validation');
295
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
296
+ equationEditorFlyout.steps.clearAll();
297
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50kg');
298
+ equationEditorFlyout.steps.clickOnOkButton();
299
+ textEntryMathPage.steps.switchToPreviewTab();
300
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
301
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50kg');
302
+ equationEditorFlyout.steps.clickOnOkButton();
303
+ textEntryMathPage.steps.switchToGradingView();
304
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
305
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
306
+ });
307
+
308
+ it('When \'Interpret alphabets as variables\' checkbox is unchecked and user attempts the expression differently then the answer should be treated as correct', () => {
309
+ textEntryMathPage.steps.resetQuestionPreview();
310
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
311
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50k*g');
312
+ equationEditorFlyout.steps.clickOnOkButton();
313
+ textEntryMathPage.steps.switchToGradingView();
314
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
315
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
316
+ });
317
+
318
+ it('When \'Interpret alphabets as variables\' checkbox is unchecked and user attempts the equation using operation then the answer should be treated as correct', () => {
319
+ textEntryMathPage.steps.resetQuestionPreview();
320
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
321
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(20+30)k*g');
322
+ equationEditorFlyout.steps.clickOnOkButton();
323
+ textEntryMathPage.steps.switchToGradingView();
324
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
325
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
326
+ });
327
+
328
+ it('When user checks \'Interpret alphabets as variables\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
329
+ textEntryMathPage.steps.switchToEditTab();
330
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
331
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
332
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Interpret alphabets as variables');
333
+ textEntryMathPage.steps.switchToPreviewTab();
334
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
335
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50kg');
336
+ equationEditorFlyout.steps.clickOnOkButton();
337
+ textEntryMathPage.steps.switchToGradingView();
338
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
339
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
340
+ });
341
+
342
+ it('When \'Interpret alphabets as variables\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as correct', () => {
343
+ textEntryMathPage.steps.resetQuestionPreview();
344
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
345
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(20+30)k*g');
346
+ equationEditorFlyout.steps.clickOnOkButton();
347
+ textEntryMathPage.steps.switchToGradingView();
348
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
349
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
350
+ });
351
+
352
+ it('When user checks \'Interpret alphabets as variables\' checkbox user attempts the question with variables then the answer should be treated as incorrect', () => {
353
+ textEntryMathPage.steps.resetQuestionPreview();
354
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
355
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50+0');
356
+ equationEditorFlyout.steps.clickOnOkButton();
357
+ textEntryMathPage.steps.switchToGradingView();
358
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
359
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
360
+ });
361
+
362
+ //Interpret e as Euler's number
363
+ it('When \'Interpret e as Euler\'s number\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
364
+ textEntryMathPage.steps.switchToEditTab();
365
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
366
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
367
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Interpret alphabets as variables');
368
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
369
+ equationEditorFlyout.steps.clearAll();
370
+ equationEditorFlyout.steps.enterTextInPreviewInputField('e+20');
371
+ equationEditorFlyout.steps.clickOnOkButton();
372
+ textEntryMathPage.steps.switchToPreviewTab();
373
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
374
+ equationEditorFlyout.steps.enterTextInPreviewInputField('e+20');
375
+ equationEditorFlyout.steps.clickOnOkButton();
376
+ textEntryMathPage.steps.switchToGradingView();
377
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
378
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
379
+ });
380
+
381
+ it('When \'Interpret e as Euler\'s number\' checkbox is unchecked and user attempts the expression differently then the answer should be treated as incorrect', () => {
382
+ textEntryMathPage.steps.resetQuestionPreview();
383
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
384
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2.718281828459045+20');
385
+ equationEditorFlyout.steps.clickOnOkButton();
386
+ textEntryMathPage.steps.switchToGradingView();
387
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
388
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
389
+ });
390
+
391
+ it('When \'Interpret e as Euler\'s number\' checkbox is unchecked and user attempts the equation using variables then the answer should be treated as incorrect', () => {
392
+ textEntryMathPage.steps.resetQuestionPreview();
393
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
394
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2+0.718281828459045+10+10');
395
+ equationEditorFlyout.steps.clickOnOkButton();
396
+ textEntryMathPage.steps.switchToGradingView();
397
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
398
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
399
+ });
400
+
401
+ it('When user checks \'Interpret e as Euler\'s number\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
402
+ textEntryMathPage.steps.switchToEditTab();
403
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
404
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
405
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Interpret e as Euler\'s number');
406
+ textEntryMathPage.steps.switchToPreviewTab();
407
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
408
+ equationEditorFlyout.steps.clearAll();
409
+ equationEditorFlyout.steps.enterTextInPreviewInputField('e+20');
410
+ equationEditorFlyout.steps.clickOnOkButton();
411
+ textEntryMathPage.steps.switchToGradingView();
412
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
413
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
414
+ });
415
+
416
+ it('When \'Interpret e as Euler\'s number\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as correct', () => {
417
+ textEntryMathPage.steps.resetQuestionPreview();
418
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
419
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2.718281828459045+20');
420
+ equationEditorFlyout.steps.clickOnOkButton();
421
+ textEntryMathPage.steps.switchToGradingView();
422
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
423
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
424
+ });
425
+
426
+ it('When user checks \'Interpret e as Euler\'s number\' checkbox user attempts the question with variables then the answer should be treated as correct', () => {
427
+ textEntryMathPage.steps.resetQuestionPreview();
428
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
429
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2+0.718281828459045+10+10');
430
+ equationEditorFlyout.steps.clickOnOkButton();
431
+ textEntryMathPage.steps.switchToGradingView();
432
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
433
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
434
+ });
435
+
436
+ //Interpret i as imaginary
437
+ it('When \'Interpret i as imaginary\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
438
+ textEntryMathPage.steps.switchToEditTab();
439
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
440
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
441
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Interpret e as Euler\'s number');
442
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
443
+ equationEditorFlyout.steps.clearAll();
444
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6i^2');
445
+ equationEditorFlyout.steps.clickOnOkButton();
446
+ textEntryMathPage.steps.switchToPreviewTab();
447
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
448
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6i^2');
449
+ equationEditorFlyout.steps.clickOnOkButton();
450
+ textEntryMathPage.steps.switchToGradingView();
451
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
452
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
453
+ });
454
+
455
+ it('When \'Interpret i as imaginary\' checkbox is unchecked and user attempts the expression differently then the answer should be treated as incorrect', () => {
456
+ textEntryMathPage.steps.resetQuestionPreview();
457
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
458
+ equationEditorFlyout.steps.enterTextInPreviewInputField('-6');
459
+ equationEditorFlyout.steps.clickOnOkButton();
460
+ textEntryMathPage.steps.switchToGradingView();
461
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
462
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
463
+ });
464
+
465
+ it('When \'Interpret i as imaginary\' checkbox is unchecked and user attempts the equation using variables then the answer should be treated as correct', () => {
466
+ textEntryMathPage.steps.resetQuestionPreview();
467
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
468
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6*i*i');
469
+ equationEditorFlyout.steps.clickOnOkButton();
470
+ textEntryMathPage.steps.switchToGradingView();
471
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
472
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
473
+ });
474
+
475
+ it('When user checks \'Interpret i as imaginary\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
476
+ textEntryMathPage.steps.switchToEditTab();
477
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
478
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
479
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
480
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Interpret i as imaginary');
481
+ textEntryMathPage.steps.switchToPreviewTab();
482
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
483
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6i^2');
484
+ equationEditorFlyout.steps.clickOnOkButton();
485
+ textEntryMathPage.steps.switchToGradingView();
486
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
487
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
488
+ });
489
+
490
+ it('When \'Interpret i as imaginary\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as correct', () => {
491
+ textEntryMathPage.steps.resetQuestionPreview();
492
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
493
+ equationEditorFlyout.steps.enterTextInPreviewInputField('-6');
494
+ equationEditorFlyout.steps.clickOnOkButton();
495
+ textEntryMathPage.steps.switchToGradingView();
496
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
497
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
498
+ });
499
+
500
+ it('When user checks \'Interpret i as imaginary\' checkbox user attempts the question with variables then the answer should be treated as correct', () => {
501
+ textEntryMathPage.steps.resetQuestionPreview();
502
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
503
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6*i^4');
504
+ equationEditorFlyout.steps.clickOnOkButton();
505
+ textEntryMathPage.steps.switchToGradingView();
506
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
507
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
508
+ });
509
+
510
+ it('When user checks \'Interpret i as imaginary\' checkbox user attempts the question with variables then the answer should be treated as correct', () => {
511
+ textEntryMathPage.steps.resetQuestionPreview();
512
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
513
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['six'] }, { categoryName: 'intermediate', symbolName: ['sqrt'] }]);
514
+ equationEditorFlyout.steps.enterTextAtInputFieldCursor('-1{rightarrow}');
515
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'intermediate', symbolName: ['sqrt'] }]);
516
+ equationEditorFlyout.steps.enterTextAtInputFieldCursor('-1');
517
+ equationEditorFlyout.steps.clickOnOkButton();
518
+ textEntryMathPage.steps.switchToGradingView();
519
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
520
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
521
+ });
522
+ });
523
+
524
+ describe(`Text entry math: Value is equivalent`, () => {
525
+ abortEarlySetup();
526
+ before(() => {
527
+ textEntryMathPage.steps.navigateToCreateQuestion('Text Entry Math');
528
+ cy.barsPreLoaderWait();
529
+ textEntryMathPage.steps.addTextInQuestionInstructionsInputField('Value is equivalent: Response inputted needs to be equivalent but can be represented differently to be marked correct');
530
+ textEntryMathPage.steps.clearQuestionInputField();
531
+ textEntryMathPage.steps.addInputToQuestionInputField('Enter response according to set structure')
532
+ textEntryMathPage.steps.addResponseArea();
533
+ textEntryMathPage.steps.allotPoints(20);
534
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
535
+ textEntryMathPage.steps.selectEvaluationMethod('Value is equivalent');
536
+ textEntryMathPage.steps.expandAdditionalSettings();
537
+ textEntryMathPage.steps.selectEquationEditorSectionCategories([equationEditorCategoriesAndSymbols.trig.displayName, equationEditorCategoriesAndSymbols.greek.displayName, equationEditorCategoriesAndSymbols.calculus.displayName]);
538
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
539
+ equationEditorFlyout.steps.clearAll();
540
+ equationEditorFlyout.steps.enterQuadraticEquation()
541
+ // textEntryMathPage.steps.selectModalVisibilityTypeButton();
542
+ });
543
+
544
+ //Case sensitive
545
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with same casing then the answer should be treated as correct', () => {
546
+ textEntryMathPage.steps.switchToPreviewTab();
547
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
548
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['y', 'x'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
549
+ equationEditorFlyout.steps.clickOnOkButton();
550
+ textEntryMathPage.steps.switchToGradingView();
551
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
552
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
553
+ });
554
+
555
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with different casing then the answer should be treated as correct', () => {
556
+ textEntryMathPage.steps.resetQuestionPreview();
557
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
558
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
559
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
560
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
561
+ equationEditorFlyout.steps.clickOnOkButton();
562
+ textEntryMathPage.steps.switchToGradingView();
563
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
564
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
565
+ });
566
+
567
+ it('When user checks \'Case sensitive\' checkbox user attempts the question with same casing then the answer should be treated as correct', () => {
568
+ textEntryMathPage.steps.switchToEditTab();
569
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
570
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
571
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Case sensitive');
572
+ textEntryMathPage.steps.switchToPreviewTab();
573
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
574
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['y', 'x'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
575
+ equationEditorFlyout.steps.clickOnOkButton();
576
+ textEntryMathPage.steps.switchToGradingView();
577
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
578
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
579
+ });
580
+
581
+ it('When \'Case sensitive\' checkbox is checked and user attempts the question with different casing then the answer should be treated as incorrect', () => {
582
+ textEntryMathPage.steps.resetQuestionPreview();
583
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
584
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
585
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
586
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
587
+ equationEditorFlyout.steps.clickOnOkButton();
588
+ textEntryMathPage.steps.switchToGradingView();
589
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
590
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
591
+ });
592
+
593
+ //Check for equality across sides
594
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
595
+ textEntryMathPage.steps.switchToEditTab();
596
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
597
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
598
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Case sensitive');
599
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
600
+ equationEditorFlyout.steps.clearAll();
601
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
602
+ equationEditorFlyout.steps.clickOnOkButton();
603
+ textEntryMathPage.steps.switchToPreviewTab();
604
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
605
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
606
+ equationEditorFlyout.steps.clickOnOkButton();
607
+ textEntryMathPage.steps.switchToGradingView();
608
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
609
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
610
+ });
611
+
612
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as correct', () => {
613
+ textEntryMathPage.steps.resetQuestionPreview();
614
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
615
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6=6');
616
+ equationEditorFlyout.steps.clickOnOkButton();
617
+ textEntryMathPage.steps.switchToGradingView();
618
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
619
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
620
+ });
621
+
622
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation using variables then the answer should be treated as correct', () => {
623
+ textEntryMathPage.steps.resetQuestionPreview();
624
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
625
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5x');
626
+ equationEditorFlyout.steps.clickOnOkButton();
627
+ textEntryMathPage.steps.switchToGradingView();
628
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
629
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
630
+ });
631
+
632
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the question with different variables across equation the then the answer should be treated as incorrect', () => {
633
+ textEntryMathPage.steps.resetQuestionPreview();
634
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
635
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5xy');
636
+ equationEditorFlyout.steps.clickOnOkButton();
637
+ textEntryMathPage.steps.switchToGradingView();
638
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
639
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
640
+ });
641
+
642
+ it('When user checks \'Check for equality across sides\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
643
+ textEntryMathPage.steps.switchToEditTab();
644
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
645
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
646
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Check for equality across sides');
647
+ textEntryMathPage.steps.switchToPreviewTab();
648
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
649
+ equationEditorFlyout.steps.enterTextInPreviewInputField('5=5');
650
+ equationEditorFlyout.steps.clickOnOkButton();
651
+ textEntryMathPage.steps.switchToGradingView();
652
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
653
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
654
+ });
655
+
656
+ it('When \'Check for equality across sides\' checkbox is unchecked and user attempts the equation differently then the answer should be treated as incorrect', () => {
657
+ textEntryMathPage.steps.resetQuestionPreview();
658
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
659
+ equationEditorFlyout.steps.enterTextInPreviewInputField('6=6');
660
+ equationEditorFlyout.steps.clickOnOkButton();
661
+ textEntryMathPage.steps.switchToGradingView();
662
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
663
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
664
+ });
665
+
666
+ it('When user checks \'Check for equality across sides\' checkbox user attempts the question with variables then the answer should be treated as incorrect', () => {
667
+ textEntryMathPage.steps.resetQuestionPreview();
668
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
669
+ equationEditorFlyout.steps.enterTextInPreviewInputField('3x+2x=5x');
670
+ equationEditorFlyout.steps.clickOnOkButton();
671
+ textEntryMathPage.steps.switchToGradingView();
672
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
673
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
674
+ });
675
+
676
+ //Exclude LaTeX text from validation
677
+ it('When \'Exclude LaTeX text from validation\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
678
+ textEntryMathPage.steps.switchToEditTab();
679
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
680
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
681
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Check for equality across sides');
682
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
683
+ equationEditorFlyout.steps.clearAll();
684
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
685
+ equationEditorFlyout.steps.clickOnOkButton();
686
+ textEntryMathPage.steps.switchToPreviewTab();
687
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
688
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
689
+ equationEditorFlyout.steps.clickOnOkButton();
690
+ textEntryMathPage.steps.switchToGradingView();
691
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
692
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
693
+ });
694
+
695
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the equation differently then the answer should be treated as correct', () => {
696
+ textEntryMathPage.steps.resetQuestionPreview();
697
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
698
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50');
699
+ equationEditorFlyout.steps.clickOnOkButton();
700
+ textEntryMathPage.steps.switchToGradingView();
701
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
702
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
703
+ });
704
+
705
+ it('When \'Exclude LaTeX text from validation\' checkbox is unchecked and user attempts the equation using un-necessary then the answer should be treated as incorrect', () => {
706
+ textEntryMathPage.steps.resetQuestionPreview();
707
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
708
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50+0');
709
+ equationEditorFlyout.steps.clickOnOkButton();
710
+ textEntryMathPage.steps.switchToGradingView();
711
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
712
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
713
+ });
714
+
715
+ it('When user checks \'Exclude LaTeX text from validation\' checkbox user attempts the question with same equation then the answer should be treated as correct', () => {
716
+ textEntryMathPage.steps.switchToEditTab();
717
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
718
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
719
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Exclude LaTeX text from validation');
720
+ textEntryMathPage.steps.switchToPreviewTab();
721
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
722
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50cm');
723
+ equationEditorFlyout.steps.clickOnOkButton();
724
+ textEntryMathPage.steps.switchToGradingView();
725
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
726
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
727
+ });
728
+
729
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the equation differently then the answer should be treated as correct', () => {
730
+ textEntryMathPage.steps.resetQuestionPreview();
731
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
732
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50');
733
+ equationEditorFlyout.steps.clickOnOkButton();
734
+ textEntryMathPage.steps.switchToGradingView();
735
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
736
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
737
+ });
738
+
739
+ it('When \'Exclude LaTeX text from validation\' checkbox is checked and user attempts the question with variables then the answer should be treated as correct', () => {
740
+ textEntryMathPage.steps.resetQuestionPreview();
741
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
742
+ equationEditorFlyout.steps.enterTextInPreviewInputField('50+0');
743
+ equationEditorFlyout.steps.clickOnOkButton();
744
+ textEntryMathPage.steps.switchToGradingView();
745
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
746
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
747
+ });
748
+ });
749
+
750
+ describe(`Text entry math: Match value`, () => {
751
+ abortEarlySetup();
752
+ before(() => {
753
+ textEntryMathPage.steps.navigateToCreateQuestion('Text Entry Math');
754
+ cy.barsPreLoaderWait();
755
+ textEntryMathPage.steps.addTextInQuestionInstructionsInputField('Match value: Response inputted needs to be equal and represented the same way to be marked correct');
756
+ textEntryMathPage.steps.clearQuestionInputField();
757
+ textEntryMathPage.steps.addInputToQuestionInputField('Enter response according to set structure')
758
+ textEntryMathPage.steps.addResponseArea();
759
+ textEntryMathPage.steps.allotPoints(20);
760
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
761
+ textEntryMathPage.steps.selectEvaluationMethod('Match value');
762
+ textEntryMathPage.steps.expandAdditionalSettings();
763
+ textEntryMathPage.steps.selectEquationEditorSectionCategories([equationEditorCategoriesAndSymbols.trig.displayName, equationEditorCategoriesAndSymbols.greek.displayName, equationEditorCategoriesAndSymbols.calculus.displayName]);
764
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
765
+ equationEditorFlyout.steps.clearAll();
766
+ equationEditorFlyout.steps.enterQuadraticEquation()
767
+ // textEntryMathPage.steps.selectModalVisibilityTypeButton();
768
+ });
769
+
770
+ //Case sensitive
771
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with same casing then the answer should be treated as correct', () => {
772
+ textEntryMathPage.steps.switchToPreviewTab();
773
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
774
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['x', 'y'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
775
+ equationEditorFlyout.steps.clickOnOkButton();
776
+ textEntryMathPage.steps.switchToGradingView();
777
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
778
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
779
+ });
780
+
781
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with different casing then the answer should be treated as correct', () => {
782
+ textEntryMathPage.steps.resetQuestionPreview();
783
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
784
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
785
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
786
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
787
+ equationEditorFlyout.steps.clickOnOkButton();
788
+ textEntryMathPage.steps.switchToGradingView();
789
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
790
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
791
+ });
792
+
793
+ it('When user checks \'Case sensitive\' checkbox user attempts the question with same casing then the answer should be treated as correct', () => {
794
+ textEntryMathPage.steps.switchToEditTab();
795
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
796
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
797
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Case sensitive');
798
+ textEntryMathPage.steps.switchToPreviewTab();
799
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
800
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['x', 'y'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
801
+ equationEditorFlyout.steps.clickOnOkButton();
802
+ textEntryMathPage.steps.switchToGradingView();
803
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
804
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
805
+ });
806
+
807
+ it('When \'Case sensitive\' checkbox is checked and user attempts the question with different casing then the answer should be treated as incorrect', () => {
808
+ textEntryMathPage.steps.resetQuestionPreview();
809
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
810
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
811
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
812
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
813
+ equationEditorFlyout.steps.clickOnOkButton();
814
+ textEntryMathPage.steps.switchToGradingView();
815
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
816
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
817
+ });
818
+
819
+ //Accept interval notation
820
+ it('When \'Accept interval notation\' checkbox is unchecked and user attempts the question with different interval notations then the answer should be treated as incorrect', () => {
821
+ textEntryMathPage.steps.switchToEditTab();
822
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
823
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
824
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Case sensitive');
825
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
826
+ equationEditorFlyout.steps.clearAll();
827
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
828
+ equationEditorFlyout.steps.clickOnOkButton();
829
+ textEntryMathPage.steps.switchToPreviewTab();
830
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
831
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4)');
832
+ equationEditorFlyout.steps.clickOnOkButton();
833
+ textEntryMathPage.steps.switchToGradingView();
834
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
835
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
836
+ });
837
+
838
+ it('When \'Accept interval notation\' checkbox is unchecked and user attempts the question with same interval notation then the answer should be treated as incorrect', () => {
839
+ textEntryMathPage.steps.resetQuestionPreview();
840
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
841
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
842
+ equationEditorFlyout.steps.clickOnOkButton();
843
+ textEntryMathPage.steps.switchToGradingView();
844
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
845
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
846
+ });
847
+
848
+ it('When user checks \'Accept interval notation\' checkbox user attempts the question with same notation then the answer should be treated as correct', () => {
849
+ textEntryMathPage.steps.switchToEditTab();
850
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
851
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
852
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Accept interval notation');
853
+ textEntryMathPage.steps.switchToPreviewTab();
854
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
855
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4]');
856
+ equationEditorFlyout.steps.clickOnOkButton();
857
+ textEntryMathPage.steps.switchToGradingView();
858
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
859
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
860
+ });
861
+
862
+ it('When \'Accept interval notation\' checkbox is checked and user attempts the question with different notation then the answer should be treated as correct', () => {
863
+ textEntryMathPage.steps.resetQuestionPreview();
864
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
865
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2-(3+4)');
866
+ equationEditorFlyout.steps.clickOnOkButton();
867
+ textEntryMathPage.steps.switchToGradingView();
868
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
869
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
870
+ });
871
+
872
+ //Accept expressions in any order
873
+ it('When \'Accept expressions in any order\' checkbox is unchecked and user attempts the question with same order then the answer should be treated as correct', () => {
874
+ textEntryMathPage.steps.switchToEditTab();
875
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
876
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
877
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Accept interval notation');
878
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
879
+ equationEditorFlyout.steps.clearAll();
880
+ equationEditorFlyout.steps.enterTextInPreviewInputField('[x-3][x+3]');
881
+ equationEditorFlyout.steps.clickOnOkButton();
882
+ textEntryMathPage.steps.switchToPreviewTab();
883
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
884
+ equationEditorFlyout.steps.enterTextInPreviewInputField('[x-3][x+3]');
885
+ equationEditorFlyout.steps.clickOnOkButton();
886
+ textEntryMathPage.steps.switchToGradingView();
887
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
888
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
889
+ });
890
+
891
+ it('When \'Accept expressions in any order\' checkbox is unchecked and user attempts the question with different order then the answer should be treated as incorrect', () => {
892
+ textEntryMathPage.steps.resetQuestionPreview();
893
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
894
+ equationEditorFlyout.steps.enterTextInPreviewInputField('[x+3][x-3]');
895
+ equationEditorFlyout.steps.clickOnOkButton();
896
+ textEntryMathPage.steps.switchToGradingView();
897
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
898
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
899
+ });
900
+
901
+ it('When \'Accept expressions in any order\' is checked and user attempts the question with same order then the answer should be treated as correct', () => {
902
+ textEntryMathPage.steps.switchToEditTab();
903
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
904
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
905
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Accept expressions in any order');
906
+ textEntryMathPage.steps.switchToPreviewTab();
907
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
908
+ equationEditorFlyout.steps.enterTextInPreviewInputField('[x-3][x+3]');
909
+ equationEditorFlyout.steps.clickOnOkButton();
910
+ textEntryMathPage.steps.switchToGradingView();
911
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
912
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
913
+ });
914
+
915
+ it('When \'Accept expressions in any order\' checkbox is checked and user attempts the question with different order then the answer should be treated as correct', () => {
916
+ textEntryMathPage.steps.resetQuestionPreview();
917
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
918
+ equationEditorFlyout.steps.enterTextInPreviewInputField('[x+3][x-3]');
919
+ equationEditorFlyout.steps.clickOnOkButton();
920
+ textEntryMathPage.steps.switchToGradingView();
921
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
922
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
923
+ });
924
+
925
+ //Exclude from possible correct answers
926
+ it('When \'Exclude from possible correct answers\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
927
+ textEntryMathPage.steps.switchToEditTab();
928
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
929
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
930
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Accept expressions in any order');
931
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
932
+ equationEditorFlyout.steps.clearAll();
933
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
934
+ equationEditorFlyout.steps.clickOnOkButton();
935
+ textEntryMathPage.steps.switchToPreviewTab();
936
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
937
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
938
+ equationEditorFlyout.steps.clickOnOkButton();
939
+ textEntryMathPage.steps.switchToGradingView();
940
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
941
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
942
+ });
943
+
944
+ it('When \'Exclude from possible correct answers\' checkbox is unchecked and user attempts the question with different expression then the answer should be treated as incorrect', () => {
945
+ textEntryMathPage.steps.resetQuestionPreview();
946
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
947
+ equationEditorFlyout.steps.enterTextInPreviewInputField('x+12y');
948
+ equationEditorFlyout.steps.clickOnOkButton();
949
+ textEntryMathPage.steps.switchToGradingView();
950
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
951
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
952
+ });
953
+
954
+ it('When \'Exclude from possible correct answers\' is checked and user attempts the question with same expression then the answer should be treated as incorrect', () => {
955
+ textEntryMathPage.steps.switchToEditTab();
956
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
957
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
958
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Exclude from possible correct answers');
959
+ textEntryMathPage.steps.switchToPreviewTab();
960
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
961
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
962
+ equationEditorFlyout.steps.clickOnOkButton();
963
+ textEntryMathPage.steps.switchToGradingView();
964
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
965
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
966
+ });
967
+
968
+ it('When \'Exclude from possible correct answers\' checkbox is checked and user attempts the question with different expression then the answer should be treated as correct', () => {
969
+ textEntryMathPage.steps.resetQuestionPreview();
970
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
971
+ equationEditorFlyout.steps.enterTextInPreviewInputField('x+12y');
972
+ equationEditorFlyout.steps.clickOnOkButton();
973
+ textEntryMathPage.steps.switchToGradingView();
974
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
975
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
976
+ });
977
+
978
+ //Ignore zeros after decimal
979
+ it('When \'Ignore zeros after decimal\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
980
+ textEntryMathPage.steps.switchToEditTab();
981
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
982
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
983
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Exclude from possible correct answers');
984
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
985
+ equationEditorFlyout.steps.clearAll();
986
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
987
+ equationEditorFlyout.steps.clickOnOkButton();
988
+ textEntryMathPage.steps.switchToPreviewTab();
989
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
990
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
991
+ equationEditorFlyout.steps.clickOnOkButton();
992
+ textEntryMathPage.steps.switchToGradingView();
993
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
994
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
995
+ });
996
+
997
+ it('When \'Ignore zeros after decimal\' checkbox is unchecked and user attempts the question with decimals then the answer should be treated as incorrect', () => {
998
+ textEntryMathPage.steps.resetQuestionPreview();
999
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1000
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12.0x+1.00y');
1001
+ equationEditorFlyout.steps.clickOnOkButton();
1002
+ textEntryMathPage.steps.switchToGradingView();
1003
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1004
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1005
+ });
1006
+
1007
+ it('When \'Ignore zeros after decimal\' is checked and user attempts the question with same expression then the answer should be treated as correct', () => {
1008
+ textEntryMathPage.steps.switchToEditTab();
1009
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1010
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1011
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Ignore zeros after decimal');
1012
+ textEntryMathPage.steps.switchToPreviewTab();
1013
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1014
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
1015
+ equationEditorFlyout.steps.clickOnOkButton();
1016
+ textEntryMathPage.steps.switchToGradingView();
1017
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1018
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1019
+ });
1020
+
1021
+ it('When \'Ignore zeros after decimal\' checkbox is checked and user attempts the question with decimals then the answer should be treated as correct', () => {
1022
+ textEntryMathPage.steps.resetQuestionPreview();
1023
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1024
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12.0x+1.00y');
1025
+ equationEditorFlyout.steps.clickOnOkButton();
1026
+ textEntryMathPage.steps.switchToGradingView();
1027
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1028
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1029
+ });
1030
+
1031
+ it.skip('When \'Ignore zeros after decimal\' checkbox is checked and user attempts the question with decimals then the answer should be treated as correct', () => {
1032
+ textEntryMathPage.steps.resetQuestionPreview();
1033
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1034
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12.0002x+1.2y');
1035
+ equationEditorFlyout.steps.clickOnOkButton();
1036
+ textEntryMathPage.steps.switchToGradingView();
1037
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1038
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1039
+ });
1040
+
1041
+ //Ignore unit coefficient
1042
+ it('When \'Ignore unit coefficient\' checkbox is unchecked and user attempts the question with same equation then the answer should be treated as correct', () => {
1043
+ textEntryMathPage.steps.switchToEditTab();
1044
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1045
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1046
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Ignore zeros after decimal');
1047
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
1048
+ equationEditorFlyout.steps.clearAll();
1049
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
1050
+ equationEditorFlyout.steps.clickOnOkButton();
1051
+ textEntryMathPage.steps.switchToPreviewTab();
1052
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1053
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
1054
+ equationEditorFlyout.steps.clickOnOkButton();
1055
+ textEntryMathPage.steps.switchToGradingView();
1056
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1057
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1058
+ });
1059
+
1060
+ it('When \'Ignore unit coefficient\' checkbox is unchecked and user attempts the question with unit coefficient then the answer should be treated as incorrect', () => {
1061
+ textEntryMathPage.steps.resetQuestionPreview();
1062
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1063
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+1y');
1064
+ equationEditorFlyout.steps.clickOnOkButton();
1065
+ textEntryMathPage.steps.switchToGradingView();
1066
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1067
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1068
+ });
1069
+
1070
+ it('When \'Ignore unit coefficient\' is checked and user attempts the question with same expression then the answer should be treated as correct', () => {
1071
+ textEntryMathPage.steps.switchToEditTab();
1072
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1073
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1074
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Ignore unit coefficient');
1075
+ textEntryMathPage.steps.switchToPreviewTab();
1076
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1077
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+y');
1078
+ equationEditorFlyout.steps.clickOnOkButton();
1079
+ textEntryMathPage.steps.switchToGradingView();
1080
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1081
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1082
+ });
1083
+
1084
+ it('When \'Ignore unit coefficient\' checkbox is checked and user attempts the question with decimals then the answer should be treated as correct', () => {
1085
+ textEntryMathPage.steps.resetQuestionPreview();
1086
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1087
+ equationEditorFlyout.steps.enterTextInPreviewInputField('12x+1y');
1088
+ equationEditorFlyout.steps.clickOnOkButton();
1089
+ textEntryMathPage.steps.switchToGradingView();
1090
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1091
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1092
+ });
1093
+
1094
+ //Check for parenthesis groups
1095
+ it('When \'Check for parenthesis groups\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
1096
+ textEntryMathPage.steps.switchToEditTab();
1097
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1098
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1099
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Ignore unit coefficient');
1100
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
1101
+ equationEditorFlyout.steps.clearAll();
1102
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1103
+ equationEditorFlyout.steps.clickOnOkButton();
1104
+ textEntryMathPage.steps.switchToPreviewTab();
1105
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1106
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1107
+ equationEditorFlyout.steps.clickOnOkButton();
1108
+ textEntryMathPage.steps.switchToGradingView();
1109
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1110
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1111
+ });
1112
+
1113
+ it('When \'Check for parenthesis groups\' checkbox is unchecked and user attempts the question with expression with different parenthesis then the answer should be treated as incorrect', () => {
1114
+ textEntryMathPage.steps.resetQuestionPreview();
1115
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1116
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b+c)');
1117
+ equationEditorFlyout.steps.clickOnOkButton();
1118
+ textEntryMathPage.steps.switchToGradingView();
1119
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1120
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1121
+ });
1122
+
1123
+ it('When \'Check for parenthesis groups\' is checked and user attempts the question with different parenthesis then the answer should be treated as correct', () => {
1124
+ textEntryMathPage.steps.switchToEditTab();
1125
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1126
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1127
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Check for parenthesis groups');
1128
+ textEntryMathPage.steps.switchToPreviewTab();
1129
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1130
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b+c)');
1131
+ equationEditorFlyout.steps.clickOnOkButton();
1132
+ textEntryMathPage.steps.switchToGradingView();
1133
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1134
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1135
+ });
1136
+
1137
+ it('When \'Check for parenthesis groups\' checkbox is checked and user attempts the question with same parenthesis then the answer should be treated as correct', () => {
1138
+ textEntryMathPage.steps.resetQuestionPreview();
1139
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1140
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1141
+ equationEditorFlyout.steps.clickOnOkButton();
1142
+ textEntryMathPage.steps.switchToGradingView();
1143
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1144
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1145
+ });
1146
+
1147
+ it('When \'Check for parenthesis groups\' checkbox is checked and user attempts the question with different parenthesis then the answer should be treated as correct', () => {
1148
+ textEntryMathPage.steps.resetQuestionPreview();
1149
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1150
+ equationEditorFlyout.steps.enterTextInPreviewInputField('a+(b+c)');
1151
+ equationEditorFlyout.steps.clickOnOkButton();
1152
+ textEntryMathPage.steps.switchToGradingView();
1153
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1154
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1155
+ });
1156
+ });
1157
+
1158
+ describe('Evaluation methods: Match exact', () => {
1159
+ abortEarlySetup();
1160
+ before(() => {
1161
+ textEntryMathPage.steps.navigateToCreateQuestion('Text Entry Math');
1162
+ cy.barsPreLoaderWait();
1163
+ textEntryMathPage.steps.addTextInQuestionInstructionsInputField('Match exact: Response entered needs to be an exact match to be marked correct');
1164
+ textEntryMathPage.steps.clearQuestionInputField();
1165
+ textEntryMathPage.steps.addInputToQuestionInputField('Enter the correct value in the response field');
1166
+ textEntryMathPage.steps.addResponseArea();
1167
+ textEntryMathPage.steps.expandAdditionalSettings();
1168
+ textEntryMathPage.steps.selectEquationEditorSectionCategories([equationEditorCategoriesAndSymbols.trig.displayName, equationEditorCategoriesAndSymbols.greek.displayName, equationEditorCategoriesAndSymbols.calculus.displayName]);
1169
+ textEntryMathPage.steps.allotPoints(20);
1170
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1171
+ textEntryMathPage.steps.selectEvaluationMethod('Match exact');
1172
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
1173
+ equationEditorFlyout.steps.clearAll();
1174
+ equationEditorFlyout.steps.enterQuadraticEquation()
1175
+ // textEntryMathPage.steps.selectModalVisibilityTypeButton();
1176
+ });
1177
+
1178
+ //Case sensitive
1179
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with same casing then the answer should be treated as correct', () => {
1180
+ textEntryMathPage.steps.switchToPreviewTab();
1181
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1182
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['x', 'y'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
1183
+ equationEditorFlyout.steps.clickOnOkButton();
1184
+ textEntryMathPage.steps.switchToGradingView();
1185
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1186
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1187
+ });
1188
+
1189
+ it('When \'Case sensitive\' checkbox is unchecked and user attempts the question with different casing then the answer should be treated as correct', () => {
1190
+ textEntryMathPage.steps.resetQuestionPreview();
1191
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1192
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
1193
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
1194
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
1195
+ equationEditorFlyout.steps.clickOnOkButton();
1196
+ textEntryMathPage.steps.switchToGradingView();
1197
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1198
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1199
+ });
1200
+
1201
+ it('When user checks \'Case sensitive\' checkbox user attempts the question with same casing then the answer should be treated as correct', () => {
1202
+ textEntryMathPage.steps.switchToEditTab();
1203
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1204
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1205
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Case sensitive');
1206
+ textEntryMathPage.steps.switchToPreviewTab();
1207
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1208
+ equationEditorFlyout.steps.enterEquation([{ categoryName: 'numPad', symbolName: ['two'] }, { categoryName: 'intermediate', symbolName: ['x', 'square', 'y', 'square'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }, { categoryName: 'intermediate', symbolName: ['x', 'y'] }, { categoryName: 'numPad', symbolName: ['add', 'four'] }]);
1209
+ equationEditorFlyout.steps.clickOnOkButton();
1210
+ textEntryMathPage.steps.switchToGradingView();
1211
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1212
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1213
+ });
1214
+
1215
+ it('When \'Case sensitive\' checkbox is checked and user attempts the question with different casing then the answer should be treated as incorrect', () => {
1216
+ textEntryMathPage.steps.resetQuestionPreview();
1217
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1218
+ equationEditorFlyout.steps.enterTextInPreviewInputField('2X^2');
1219
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Y^2');
1220
+ equationEditorFlyout.steps.enterTextInPreviewInputField('+4XY+4');
1221
+ equationEditorFlyout.steps.clickOnOkButton();
1222
+ textEntryMathPage.steps.switchToGradingView();
1223
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1224
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1225
+ });
1226
+
1227
+ //Ignore spaces before and after
1228
+ it('When \'Ignore spaces before and after\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
1229
+ textEntryMathPage.steps.switchToEditTab();
1230
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1231
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1232
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Case sensitive');
1233
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
1234
+ equationEditorFlyout.steps.clearAll();
1235
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1236
+ equationEditorFlyout.steps.clickOnOkButton();
1237
+ textEntryMathPage.steps.switchToPreviewTab();
1238
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1239
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1240
+ equationEditorFlyout.steps.clickOnOkButton();
1241
+ textEntryMathPage.steps.switchToGradingView();
1242
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1243
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1244
+ });
1245
+
1246
+ it('When \'Ignore spaces before and after\' checkbox is unchecked and user attempts the question with expression with extra spaces then the answer should be treated as incorrect', () => {
1247
+ textEntryMathPage.steps.resetQuestionPreview();
1248
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1249
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c ');
1250
+ equationEditorFlyout.steps.clickOnOkButton();
1251
+ textEntryMathPage.steps.switchToGradingView();
1252
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1253
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1254
+ });
1255
+
1256
+ it('When \'Ignore spaces before and after\' checkbox is unchecked and user attempts the question with expression with extra spaces in-between the equation then the answer should be treated as incorrect', () => {
1257
+ textEntryMathPage.steps.resetQuestionPreview();
1258
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1259
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b) +c');
1260
+ equationEditorFlyout.steps.clickOnOkButton();
1261
+ textEntryMathPage.steps.switchToGradingView();
1262
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1263
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1264
+ });
1265
+
1266
+ it('When \'Ignore spaces before and after\' is checked and user attempts the question with extra spaces then the answer should be treated as correct', () => {
1267
+ textEntryMathPage.steps.switchToEditTab();
1268
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1269
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1270
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Ignore spaces before and after');
1271
+ textEntryMathPage.steps.switchToPreviewTab();
1272
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1273
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c ');
1274
+ equationEditorFlyout.steps.clickOnOkButton();
1275
+ textEntryMathPage.steps.switchToGradingView();
1276
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1277
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1278
+ });
1279
+
1280
+ it('When \'Ignore spaces before and after\' checkbox is checked and user attempts the question with no extra spaces then the answer should be treated as correct', () => {
1281
+ textEntryMathPage.steps.resetQuestionPreview();
1282
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1283
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b)+c');
1284
+ equationEditorFlyout.steps.clickOnOkButton();
1285
+ textEntryMathPage.steps.switchToGradingView();
1286
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1287
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1288
+ });
1289
+
1290
+ it('When \'Ignore spaces before and after\' checkbox is unchecked and user attempts the question with expression with extra spaces in-between the equation then the answer should be treated as incorrect', () => {
1291
+ textEntryMathPage.steps.resetQuestionPreview();
1292
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1293
+ equationEditorFlyout.steps.enterTextInPreviewInputField('(a+b) +c');
1294
+ equationEditorFlyout.steps.clickOnOkButton();
1295
+ textEntryMathPage.steps.switchToGradingView();
1296
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1297
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1298
+ });
1299
+
1300
+ //Ignore extra spaces
1301
+ it('When \'Ignore extra spaces\' checkbox is unchecked and user attempts the question with same expression then the answer should be treated as correct', () => {
1302
+ textEntryMathPage.steps.switchToEditTab();
1303
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1304
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1305
+ textEntryMathPage.steps.uncheckCustomSettingsCheckbox('Ignore spaces before and after');
1306
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldSpecifyCorrectAnswerSection(0);
1307
+ equationEditorFlyout.steps.clearAll();
1308
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1');
1309
+ equationEditorFlyout.steps.clickOnOkButton();
1310
+ textEntryMathPage.steps.switchToPreviewTab();
1311
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1312
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1');
1313
+ equationEditorFlyout.steps.clickOnOkButton();
1314
+ textEntryMathPage.steps.switchToGradingView();
1315
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1316
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1317
+ });
1318
+
1319
+ it('When \'Ignore extra spaces\' checkbox is unchecked and user attempts the question with expression with extra spaces then the answer should be treated as incorrect', () => {
1320
+ textEntryMathPage.steps.resetQuestionPreview();
1321
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1322
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1 ');
1323
+ equationEditorFlyout.steps.clickOnOkButton();
1324
+ textEntryMathPage.steps.switchToGradingView();
1325
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1326
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1327
+ });
1328
+
1329
+ it('When \'Ignore extra spaces\' checkbox is unchecked and user attempts the question with expression with extra spaces in-between the equation then the answer should be treated as correct', () => {
1330
+ textEntryMathPage.steps.resetQuestionPreview();
1331
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1332
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1');
1333
+ equationEditorFlyout.steps.clickOnOkButton();
1334
+ textEntryMathPage.steps.switchToGradingView();
1335
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1336
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1337
+ });
1338
+
1339
+ it('When \'Ignore extra spaces\' is checked and user attempts the question with extra spaces then the answer should be treated as incorrect', () => {
1340
+ textEntryMathPage.steps.switchToEditTab();
1341
+ textEntryMathPage.steps.expandResponseAccordionSpecifyCorrectAnswer(0);
1342
+ textEntryMathPage.steps.clickOnCustomSettingsAccordion();
1343
+ textEntryMathPage.steps.checkCustomSettingsCheckbox('Ignore extra spaces');
1344
+ textEntryMathPage.steps.switchToPreviewTab();
1345
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1346
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1 ');
1347
+ equationEditorFlyout.steps.clickOnOkButton();
1348
+ textEntryMathPage.steps.switchToGradingView();
1349
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1350
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1351
+ });
1352
+
1353
+ it('When \'Ignore extra spaces\' checkbox is checked and user attempts the question with no extra spaces then the answer should be treated as incorrect', () => {
1354
+ textEntryMathPage.steps.resetQuestionPreview();
1355
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1356
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1 ');
1357
+ equationEditorFlyout.steps.clickOnOkButton();
1358
+ textEntryMathPage.steps.switchToGradingView();
1359
+ textEntryMathPage.steps.verifyIncorrectResponseIcon(0);
1360
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
1361
+ });
1362
+
1363
+ it('When \'Ignore extra spaces\' checkbox is unchecked and user attempts the question with expression with extra spaces in-between the equation then the answer should be treated as correct', () => {
1364
+ textEntryMathPage.steps.resetQuestionPreview();
1365
+ textEntryMathPage.steps.focusInResponseAnswerInputFieldPreviewTab(0);
1366
+ equationEditorFlyout.steps.enterTextInPreviewInputField('Correct 1');
1367
+ equationEditorFlyout.steps.clickOnOkButton();
1368
+ textEntryMathPage.steps.switchToGradingView();
1369
+ textEntryMathPage.steps.verifyCorrectResponseIcon(0);
1370
+ textEntryMathPage.steps.verifyCorrectIncorrectAnswerLabel('correct');
1371
+ });
1372
+ });
1373
+ });