itemengine-cypress-automation 1.0.223-minorFix-f2741aa.0 → 1.0.224-31stJulyFixes-fae0339.0
Sign up to get free protection for your applications and to get access to all the features.
- package/cypress/e2e/ILC/AudioResponseNew/customizePlaybackControls.js +1 -1
- package/cypress/e2e/ILC/AudioResponseNew/studentViewSettings.js +12 -5
- package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/allOrNothingScoringForAllViews.smoke.js +370 -0
- package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/gradingViewAndCorrectAnswerView.smoke.js +285 -0
- package/cypress/e2e/ILC/ChartsBar/HorizontalOrientationBarChart/previewContentsForAllViews.smoke.js +629 -0
- package/cypress/e2e/ILC/ChartsBar/Scoring/addAndDeleteBarAllOrNothingScoring.js +4 -2
- package/cypress/e2e/ILC/ChartsBar/Scoring/allOrNothingAlternatePointsGreaterThanCorrectPoints.js +5 -4
- package/cypress/e2e/ILC/ChartsBar/Scoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/allOrNothingCorrectPointsGreaterThanAlternatePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/manuallyAndNonScored.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialDifferentWeightBasic.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +11 -10
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialDifferentWeightsCorrectPointsEqualToAlternativePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialDifferentWeightsCorrectPointsGreaterThanAlternativePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialEqualWeightBasic.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialEqualWeightsAlternativePointsGreaterThanCorrectPoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialEqualWeightsCorrectPointsEqualToAlternativePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/partialEqualWeightsCorrectPointsGreaterThanAlternativePoints.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/Scoring/toleranceThresholdScoring.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/allOrNothingScoringForAllViews.smoke.js +2 -1
- package/cypress/e2e/ILC/ChartsBar/gridSettings.js +8 -5
- package/cypress/e2e/ILC/ChartsBar/selectChartTypeSection.js +12 -12
- package/cypress/e2e/ILC/ChartsLine/editTabScoringSection.js +1 -1
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/allOrNothingBasicForGroupedOptionsLayout.js +0 -1
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perCorrectOptionAlternativePointsGreaterThanCorrectPoints.js +3 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perCorrectOptionBasic.js +2 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/Scoring/perCorrectOptionCorrectPointsGreaterThanAlternativePoints.js +2 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/additionalSettings.js +4 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/additionalSettingsBasic.js +2 -1
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/allOrNothingBasicForAllViews.smoke.js +2 -1
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/clickAndDrop.js +2 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/draggableOptions.js +0 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/pagination.js +2 -2
- package/cypress/e2e/ILC/DragAndDropIntoCategoriesNew/styleAndLayoutCustomizationDraggableOptionsPanel.js +6 -3
- package/cypress/e2e/ILC/DrawingResponse/drawingResponseEditTabBasicSection.js +7 -6
- package/cypress/e2e/ILC/EssayResponse/editCategoryFlyout.js +1 -1
- package/cypress/e2e/ILC/EssayResponse/essayResponseCustomizeFormattingOptions2.js +4 -0
- package/cypress/e2e/ILC/EssayResponse/essayResponseCustomizeFormattingOptions3.js +17 -11
- package/cypress/e2e/ILC/FeedbackScaleNew/additionalSettings.js +11 -11
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/Scoring/partialDifferentWeightsMinimumAndPenaltyScoring.js +8 -8
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/dropdownAndDropdownMenuSection.js +3 -4
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/dropdownSettings.js +3 -1
- package/cypress/e2e/ILC/FillInTheGapsDropdownNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/Scoring/partialDifferentWeightsBasic.js +4 -4
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/allOrNothingForAllViews.smoke.js +2 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDragAndDrop/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +2 -2
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/dropdownAndDropdownMenuSection.js +2 -4
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdownNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/HeaderSection.js +1 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/Scoring/partialDifferentWeightsMinimumAndPenaltyScoring.js +6 -6
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/additionalSettingsBasic.js +1 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/editTabScoringSection.js +3 -3
- package/cypress/e2e/ILC/FillInTheGapsOverImageTextNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialDifferentWeightsMinimumAndPenaltyScoring.js +6 -6
- package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsTextNew/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsTextNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +1 -1
- package/cypress/e2e/ILC/Graphing/layoutAndGridOptions.js +53 -44
- package/cypress/e2e/ILC/Graphing/toolsControlsAndBackgroundSection.js +4 -6
- package/cypress/e2e/ILC/GridFill/customizeLayoutFillImageBackgroundImage.js +2 -2
- package/cypress/e2e/ILC/ImageHighlight/Scoring/manuallyAndNonScored.js +2 -1
- package/cypress/e2e/ILC/ImageHighlight/Scoring/partialDifferentWeightsAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/ImageHighlight/Scoring/singleSelectionPreviewScoring.js +9 -9
- package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/allOrNothingCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/partialDifferentWeightsCorrectPointsEqualToAlternativePoints.js +3 -1
- package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/partialDifferentWeightsCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/ListOrderingDropdown/Scoring/partialEqualWeightsCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/ListOrderingDropdown/minimumScoringPenaltyPointsAndRoundingDropdown.js +3 -3
- package/cypress/e2e/ILC/Matching/Scoring/partialDifferentWeightsScoringBasic.js +6 -6
- package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/Matching/Scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +1 -1
- package/cypress/e2e/ILC/Matching/additionalSettings.js +1 -0
- package/cypress/e2e/ILC/Matching/maximumCapacityPerDropzoneSection.js +8 -56
- package/cypress/e2e/ILC/Matching/minimumScoringPenaltyPointsAndRoundingDropdown.js +4 -4
- package/cypress/e2e/ILC/Matching/specifyCorrectAnswerSection.js +2 -1
- package/cypress/e2e/ILC/Matching/toolSettings.js +1 -1
- package/cypress/e2e/ILC/MultipleSelection/editTabScoringSection.js +1 -1
- package/cypress/e2e/ILC/MultipleSelection/minimumScoringPenaltyPointsAndRoundingDropdown.js +4 -4
- package/cypress/e2e/ILC/MultipleSelection/partialDifferentWeightsBasic.js +6 -6
- package/cypress/e2e/ILC/MultipleSelection/partialDifferentWeightsWithAlternativeAnswer.js +1 -0
- package/cypress/e2e/ILC/MultipleSelection/partialEqualWeightsWithAlternativeAnswer.js +12 -12
- package/cypress/e2e/ILC/MultipleSelection/previewContentsForAllViews.smoke.js +1 -1
- package/cypress/e2e/ILC/MultipleSelectionGridNew/allOrNothingBasicForAllViews.smoke.js +48 -48
- package/cypress/e2e/ILC/MultipleSelectionGridNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +2 -2
- package/cypress/e2e/ILC/NumberLine/LayoutSection.js +22 -25
- package/cypress/e2e/ILC/NumberLine/additionalSettings.js +23 -3
- package/cypress/e2e/ILC/NumberLine/editTabScoringSection.js +96 -7
- package/cypress/e2e/ILC/NumberLine/lineSettingsSection.js +12 -2
- package/cypress/e2e/ILC/NumberLine/numberLineSection.js +4 -6
- package/cypress/e2e/ILC/NumberLine/specifyCorrectAnswerSection.js +1 -2
- package/cypress/e2e/ILC/NumberLine/studentViewSettings.js +3 -2
- package/cypress/e2e/ILC/NumberLine/toolSettings.js +1 -1
- package/cypress/e2e/ILC/NumberLine/verticalNumberLine/layoutSection.js +3 -5
- package/cypress/e2e/ILC/NumberLine/verticalNumberLine/numberLineSection.js +12 -3
- package/cypress/e2e/ILC/NumberLineLabel/specifyCorrectAnswerSection.js +1 -1
- package/cypress/e2e/ILC/NumberLineLabel/toolSettings.js +1 -1
- package/cypress/e2e/ILC/ShortTextResponseNew/allOrNothingBasicForAllViews.smoke.js +2 -1
- package/cypress/e2e/ILC/SingleSelection/allOrNothingBasicForAllViews.smoke.js +2 -1
- package/cypress/e2e/ILC/SingleSelection/allOrNothingWithAlternativeAnswer.js +9 -9
- package/cypress/e2e/ILC/SingleSelection/manuallyAndNonScoredScoring.js +2 -0
- package/cypress/e2e/ILC/SingleSelection/previewContents.smoke.js +1 -1
- package/cypress/e2e/ILC/SingleSelectionGridNew/editTabBasicSection.js +3 -3
- package/cypress/e2e/ILC/SingleSelectionGridNew/minimumScoringPenaltyPointsAndRoundingDropdown.js +2 -2
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodMatchValue.js +20 -0
- package/cypress/e2e/ILC/TextEntryMath/evaluationMethodSymbolsAreEquivalent.js +214 -0
- package/cypress/e2e/ILC/TextEntryMath/specifyCorrectAnswerSection.js +2 -1
- package/cypress/e2e/ILC/TextSelection/textSelectionModesInSpecifyCorrectAnswerSection.js +1 -6
- package/cypress/e2e/ILC/TextSelection/textSelectionModesInSpecifyPossibleOptionsSection.js +1 -2
- package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/audioOverviewAndTranscript.js +3 -2
- package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/customizePlayerLayoutSettings.js +2 -2
- package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/standardAudioPlayerStyle.js +3 -3
- package/cypress/e2e/ILC/VideoResponseNew/studentViewSettingsCompactRecorderStyle.js +3 -1
- package/cypress/e2e/ILC/chartsDotsPlot/additionalSettings.js +6 -6
- package/cypress/e2e/ILC/chartsDotsPlot/editTabScoring.js +4 -4
- package/cypress/e2e/ILC/chartsDotsPlot/minimumScoringPenaltyPointsAndRoundingDropdown.js +5 -5
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/allOrNothingWithAlternatePointsGreaterThanCorrectPoints.js +3 -1
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/allOrNothingWithCorrectPointsEqualToAlternativePoints.js +4 -2
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/allOrNothingWithCorrectPointsGreaterThanAlternativePoints.js +3 -1
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/manualAndNonScoredScoring.js +9 -7
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialDifferentWeightsBasic.js +62 -60
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialDifferentWeightsWithAlternativePointsGreaterThanCorrectPoints.js +29 -27
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialDifferentWeightsWithCorrectPointsEqualToAlternativePoints.js +45 -45
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialDifferentWeightsWithCorrectPointsGreaterThanAlternativePoints.js +28 -28
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialEqualWeightsBasic.js +48 -34
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialEqualWeightsWithAlternativePointsGreaterThanCorrectPoints.js +41 -38
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialEqualWeightsWithCorrectPointsEqualToAlternativePoints.js +26 -26
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/partialEqualWeightsWithCorrectPointsGreaterThanAlternativePoints.js +41 -38
- package/cypress/e2e/ILC/chartsDotsPlot/scoring/toleranceThresholdScoring.js +7 -5
- package/cypress/pages/audioPlayerPage.js +2 -2
- package/cypress/pages/audioResponsePage.js +1 -0
- package/cypress/pages/chartsBarPage.js +177 -76
- package/cypress/pages/chartsDotPlotPage.js +28 -43
- package/cypress/pages/components/additionalSettingsPanel.js +5 -2
- package/cypress/pages/components/barAndLineChartComponent.js +1 -1
- package/cypress/pages/components/chartsCommonComponent.js +28 -0
- package/cypress/pages/components/colorPopupComponent.js +2 -0
- package/cypress/pages/components/createQuestionBasePage.js +1 -0
- package/cypress/pages/components/draggableOptionsSectionComponent.js +1 -0
- package/cypress/pages/components/editCategoryFlyout.js +6 -4
- package/cypress/pages/components/essayResponseCommonComponents.js +1 -1
- package/cypress/pages/components/fillInTheGapsDropdownCommonComponent.js +3 -0
- package/cypress/pages/components/gridQuestionCommonComponent.js +2 -4
- package/cypress/pages/components/imageCanvasComponent.js +7 -5
- package/cypress/pages/components/layoutSectionComponent.js +4 -3
- package/cypress/pages/components/numberLineCommonComponent.js +38 -21
- package/cypress/pages/components/opacityComponent.js +1 -0
- package/cypress/pages/components/optionsWrapperComponent.js +1 -0
- package/cypress/pages/components/questionInstructionsComponent.js +1 -1
- package/cypress/pages/components/responseAreaSettingsPopupComponent.js +8 -0
- package/cypress/pages/components/scoringSectionBaseEditTab.js +5 -2
- package/cypress/pages/components/toolSettingsComponent.js +1 -0
- package/cypress/pages/contentBlocksPage.js +1 -0
- package/cypress/pages/dragAndDropIntoCategoriesPage.js +9 -2
- package/cypress/pages/fillInTheGapsDropdownPage.js +16 -1
- package/cypress/pages/fillInTheGapsOverImageDropdownPage.js +16 -1
- package/cypress/pages/fillInTheGapsOverImageTextPage.js +20 -1
- package/cypress/pages/graphingPage.js +43 -10
- package/cypress/pages/gridFillPage.js +11 -3
- package/cypress/pages/matchingPage.js +2 -0
- package/cypress/pages/numberLineLabelPage.js +1 -1
- package/cypress/pages/numberLinePage.js +25 -24
- package/cypress/pages/readingRulerPage.js +6 -2
- package/cypress/pages/rulerPage.js +1 -0
- package/cypress/pages/shortTextResponsePage.js +3 -1
- package/cypress/pages/singleSelectionPage.js +25 -2
- package/cypress/pages/textSelectionPage.js +1 -1
- package/cypress/pages/videoResponsePage.js +7 -2
- package/package.json +1 -1
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/allSupportedFileTypes.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/barAudioPlayerStyle.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/compactAudioPlayerStyle.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/headerSection.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/previewContents.smoke.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/studentViewSettings.js +0 -0
- /package/cypress/e2e/ILC/{AudioPlayerNew → ToolAudioPlayerNew}/uploadAndAddAudioFile.js +0 -0
- /package/cypress/fixtures/uploads/{sample10Sec.mp3 → sampleAudio.mp3} +0 -0
@@ -0,0 +1,285 @@
|
|
1
|
+
import { chartsBarPage, correctAnswerViewPage, itemPreviewPage, studentViewPage } from "../../../../pages";
|
2
|
+
import { gradingViewPage } from "../../../../pages";
|
3
|
+
import abortEarlySetup from "../../../../support/helpers/abortEarly";
|
4
|
+
import utilities from "../../../../support/helpers/utilities";
|
5
|
+
const css = Cypress.env('css');
|
6
|
+
|
7
|
+
let gradingAndCorrectAnsView = ['Grading view', 'Correct answer view']
|
8
|
+
const views = utilities.getViews(gradingAndCorrectAnsView);
|
9
|
+
var itemReferenceID = "";
|
10
|
+
const barBackgroundColor = ['rgb(46, 169, 89)', 'rgb(6, 117, 244)', 'rgb(219, 124, 0)', 'rgb(156, 105, 39)', 'rgb(219, 60, 0)'];
|
11
|
+
|
12
|
+
|
13
|
+
describe('Create item page - Charts - Bar horizontal orientation: Grading view, Correct answer view contents', () => {
|
14
|
+
before(() => {
|
15
|
+
cy.loginAs('admin');
|
16
|
+
});
|
17
|
+
|
18
|
+
if (views.includes('Grading view')) {
|
19
|
+
describe('Grading view contents', { tags: 'smoke' }, () => {
|
20
|
+
abortEarlySetup();
|
21
|
+
before(() => {
|
22
|
+
chartsBarPage.steps.navigateToCreateQuestion('charts');
|
23
|
+
cy.barsPreLoaderWait();
|
24
|
+
chartsBarPage.steps.selectHorizontalDirectionRadioButton();
|
25
|
+
chartsBarPage.steps.addTextInQuestionInstructionsInputField('Set the bar on the chart for the profits of the years');
|
26
|
+
chartsBarPage.steps.selectAddBarOrPointToolbarOption();
|
27
|
+
chartsBarPage.steps.addBarOrPointInChartInSelectChartTypeSection();
|
28
|
+
chartsBarPage.steps.setGraphTitle('Graph of profits');
|
29
|
+
chartsBarPage.steps.setXAxisLabel('Profit');
|
30
|
+
chartsBarPage.steps.setYAxisLabel('Year');
|
31
|
+
chartsBarPage.steps.setMaxYValue(20);
|
32
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 0, value: 1, range: 20 }, 'horizontal');
|
33
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 1, value: 2, range: 20 }, 'horizontal');
|
34
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 2, value: 3, range: 20 }, 'horizontal');
|
35
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 3, value: 4, range: 20 }, 'horizontal');
|
36
|
+
chartsBarPage.steps.lockBar(1);
|
37
|
+
chartsBarPage.steps.allotPoints(10);
|
38
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 0, value: 2, range: 20 }, 'horizontal');
|
39
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 2, value: 5, range: 20 }, 'horizontal');
|
40
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 3, value: 1, range: 20 }, 'horizontal');
|
41
|
+
chartsBarPage.steps.addBarOrPointInChartInSpecifyCorrectAnswerSection();
|
42
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 4, value: 8, range: 20 }, 'horizontal');
|
43
|
+
chartsBarPage.steps.clickOnSaveQuestionButton();
|
44
|
+
utilities.verifyElementVisibilityState(itemPreviewPage.referenceID(), 'visible');
|
45
|
+
//Global variable issue, not working inside before
|
46
|
+
itemPreviewPage.referenceID()
|
47
|
+
.invoke('text')
|
48
|
+
.then(($refID) => {
|
49
|
+
itemReferenceID = $refID;
|
50
|
+
cy.visit(`/item-engine/demo/render-item/student-view/${utilities.base64Encoding(itemReferenceID)}`);
|
51
|
+
chartsBarPage.steps.addBarOrPointInChartInPreviewTab();
|
52
|
+
chartsBarPage.steps.setBarValueInPreviewTab({ barIndex: 2, value: 5, range: 20 }, 'horizontal');
|
53
|
+
chartsBarPage.steps.setBarValueInPreviewTab({ barIndex: 4, value: 10, range: 20 }, 'horizontal');
|
54
|
+
studentViewPage.steps.submitResponse();
|
55
|
+
studentViewPage.steps.clickOnGoToGradingViewButton();
|
56
|
+
});
|
57
|
+
});
|
58
|
+
|
59
|
+
it('Question instructions should be visible', () => {
|
60
|
+
utilities.verifyInnerText(chartsBarPage.questionInstructionsText(), 'Set the bar on the chart for the profits of the years');
|
61
|
+
utilities.verifyElementVisibilityState(chartsBarPage.questionInstructionsText(), 'visible');
|
62
|
+
});
|
63
|
+
|
64
|
+
it('Graph title, Y axis label and X axis label set by the user should be displayed in the chart', () => {
|
65
|
+
utilities.verifyInnerText(chartsBarPage.previewTabGraphTitle(), 'Graph of profits');
|
66
|
+
utilities.verifyInnerText(chartsBarPage.previewTabXAxisLabelButton(), 'Profit');
|
67
|
+
utilities.verifyInnerText(chartsBarPage.previewTabYAxisLabelButton(), 'Year');
|
68
|
+
});
|
69
|
+
|
70
|
+
it('Toolbar, toolbar options and control actions(Undo, Redo, Reset) should not be displayed', () => {
|
71
|
+
utilities.verifyElementVisibilityState(chartsBarPage.previewTabTool(), 'notExist');
|
72
|
+
utilities.verifyElementVisibilityState(chartsBarPage.previewTabToolBarWrapper(), 'notExist');
|
73
|
+
});
|
74
|
+
|
75
|
+
it('The response submitted by the student should be displayed in grading view', () => {
|
76
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 0, barValue: 1, range: 20 });
|
77
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 1, barValue: 2, range: 20 });
|
78
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 2, barValue: 5, range: 20 });
|
79
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 3, barValue: 4, range: 20 });
|
80
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 4, barValue: 10, range: 20 });
|
81
|
+
});
|
82
|
+
|
83
|
+
it('The locked bar should have lock icon displayed in it', () => {
|
84
|
+
chartsBarPage.steps.verifyBarIsLockedInPreviewTab(1);
|
85
|
+
});
|
86
|
+
|
87
|
+
it('Correct and Incorrect icons should be displayed in each bar graph and locked bar should not have any correct or incorrect icon', () => {
|
88
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(0, 'incorrect');
|
89
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconNotExistsInPreviewTab(1);
|
90
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(2, 'correct');
|
91
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(3, 'incorrect');
|
92
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(4, 'incorrect');
|
93
|
+
});
|
94
|
+
|
95
|
+
it('\'Your answer is incorrect\' label should be displayed', () => {
|
96
|
+
chartsBarPage.steps.verifyCorrectIncorrectAnswerLabel('incorrect');
|
97
|
+
});
|
98
|
+
|
99
|
+
it('All the bar graphs in grading view should be non-editable', () => {
|
100
|
+
chartsBarPage.steps.verifyDragHandleNotVisible();
|
101
|
+
for (let index = 0; index < 5; index++) {
|
102
|
+
utilities.triggerMouseover(utilities.getNthElement(chartsBarPage.previewTabBar(), index));
|
103
|
+
utilities.verifyElementVisibilityState(chartsBarPage.barAndPointTooltipWrapper(), 'notExist');
|
104
|
+
}
|
105
|
+
});
|
106
|
+
|
107
|
+
it('Correct answer label should be displayed', () => {
|
108
|
+
utilities.verifyInnerText(chartsBarPage.correctAnswersLabel(), 'Correct answers');
|
109
|
+
utilities.verifyElementVisibilityState(chartsBarPage.correctAnswersLabel(), 'visible');
|
110
|
+
});
|
111
|
+
|
112
|
+
it('Correct answer should be displayed in the correct answer section', () => {
|
113
|
+
chartsBarPage.steps.verifyBarHeightInCorrectAnswerSection({ barIndex: 0, barValue: 2, range: 20 });
|
114
|
+
chartsBarPage.steps.verifyBarHeightInCorrectAnswerSection({ barIndex: 1, barValue: 2, range: 20 });
|
115
|
+
chartsBarPage.steps.verifyBarHeightInCorrectAnswerSection({ barIndex: 2, barValue: 5, range: 20 });
|
116
|
+
chartsBarPage.steps.verifyBarHeightInCorrectAnswerSection({ barIndex: 3, barValue: 1, range: 20 });
|
117
|
+
chartsBarPage.steps.verifyBarHeightInCorrectAnswerSection({ barIndex: 4, barValue: 8, range: 20 });
|
118
|
+
chartsBarPage.steps.verifyBarCorrectIconInCorrectAnswerSection(0);
|
119
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconNotExistsInCorrectAnswerSection(1);
|
120
|
+
chartsBarPage.steps.verifyBarCorrectIconInCorrectAnswerSection(2);
|
121
|
+
chartsBarPage.steps.verifyBarCorrectIconInCorrectAnswerSection(3);
|
122
|
+
chartsBarPage.steps.verifyBarCorrectIconInCorrectAnswerSection(4);
|
123
|
+
chartsBarPage.steps.verifyGraphTitleInCorrectAnswerSection('Graph of profits');
|
124
|
+
chartsBarPage.steps.verifyXAxisLabelInCorrectAnswerSection('Profit');
|
125
|
+
chartsBarPage.steps.verifyYAxisLabelInCorrectAnswerSection('Year');
|
126
|
+
});
|
127
|
+
|
128
|
+
it('Points and the total score should be displayed', () => {
|
129
|
+
gradingViewPage.steps.verifyGradingViewScore(0, 10);
|
130
|
+
});
|
131
|
+
|
132
|
+
it('CSS of grading view', { tags: 'css' }, () => {
|
133
|
+
utilities.verifyCSS(chartsBarPage.previewTabGraphTitle(), {
|
134
|
+
'color': css.color.text,
|
135
|
+
'font-size': css.fontSize.default,
|
136
|
+
'font-weight': css.fontWeight.bold
|
137
|
+
});
|
138
|
+
utilities.verifyCSS(chartsBarPage.previewTabYAxisLabelButton(), {
|
139
|
+
'color': css.color.text,
|
140
|
+
'font-size': css.fontSize.default,
|
141
|
+
'font-weight': css.fontWeight.bold
|
142
|
+
});
|
143
|
+
utilities.verifyCSS(chartsBarPage.previewTabXAxisLabelButton(), {
|
144
|
+
'color': css.color.text,
|
145
|
+
'font-size': css.fontSize.default,
|
146
|
+
'font-weight': css.fontWeight.bold
|
147
|
+
});
|
148
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(0), {
|
149
|
+
'background-color': barBackgroundColor[0]
|
150
|
+
});
|
151
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(1), {
|
152
|
+
'background-color': barBackgroundColor[1]
|
153
|
+
});
|
154
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(2), {
|
155
|
+
'background-color': barBackgroundColor[2]
|
156
|
+
});
|
157
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(3), {
|
158
|
+
'background-color': barBackgroundColor[3]
|
159
|
+
});
|
160
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(4), {
|
161
|
+
'background-color': barBackgroundColor[4]
|
162
|
+
});
|
163
|
+
utilities.verifyCSS(chartsBarPage.barLockIcon(), {
|
164
|
+
'background-color': css.color.defaultBackground,
|
165
|
+
});
|
166
|
+
});
|
167
|
+
|
168
|
+
it('Accessibility of grading view', { tags: 'a11y' }, () => {
|
169
|
+
cy.checkAccessibility(chartsBarPage.previewTabBar().parents('[class*="question-preview-wrapper"]'));
|
170
|
+
});
|
171
|
+
});
|
172
|
+
}
|
173
|
+
|
174
|
+
if (views.includes('Correct answer view')) {
|
175
|
+
describe('Correct answer view contents', { tags: 'smoke' }, () => {
|
176
|
+
abortEarlySetup();
|
177
|
+
before(() => {
|
178
|
+
chartsBarPage.steps.navigateToCreateQuestion('charts');
|
179
|
+
cy.barsPreLoaderWait();
|
180
|
+
chartsBarPage.steps.selectHorizontalDirectionRadioButton();
|
181
|
+
chartsBarPage.steps.addTextInQuestionInstructionsInputField('Set the bar on the chart for the profits of the years');
|
182
|
+
chartsBarPage.steps.selectAddBarOrPointToolbarOption();
|
183
|
+
chartsBarPage.steps.addBarOrPointInChartInSelectChartTypeSection();
|
184
|
+
chartsBarPage.steps.setGraphTitle('Graph of profits');
|
185
|
+
chartsBarPage.steps.setXAxisLabel('Profit');
|
186
|
+
chartsBarPage.steps.setYAxisLabel('Year');
|
187
|
+
chartsBarPage.steps.setMaxYValue(20);
|
188
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 0, value: 1, range: 20 }, 'horizontal');
|
189
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 1, value: 2, range: 20 }, 'horizontal');
|
190
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 2, value: 3, range: 20 }, 'horizontal');
|
191
|
+
chartsBarPage.steps.setBarValueInSelectChartTypeSection({ barIndex: 3, value: 4, range: 20 }, 'horizontal');
|
192
|
+
chartsBarPage.steps.lockBar(1);
|
193
|
+
chartsBarPage.steps.allotPoints(10);
|
194
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 0, value: 2, range: 20 }, 'horizontal');
|
195
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 2, value: 5, range: 20 }, 'horizontal');
|
196
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 3, value: 1, range: 20 }, 'horizontal');
|
197
|
+
chartsBarPage.steps.addBarOrPointInChartInSpecifyCorrectAnswerSection();
|
198
|
+
chartsBarPage.steps.setBarValueInSpecifyCorrectAnswerSection({ barIndex: 4, value: 8, range: 20 }, 'horizontal');
|
199
|
+
chartsBarPage.steps.clickOnSaveQuestionButton();
|
200
|
+
utilities.verifyElementVisibilityState(itemPreviewPage.referenceID(), 'visible');
|
201
|
+
//Global variable issue, not working inside before
|
202
|
+
itemPreviewPage.referenceID()
|
203
|
+
.invoke('text')
|
204
|
+
.then(($refID) => {
|
205
|
+
itemReferenceID = $refID
|
206
|
+
cy.visit(`/item-engine/demo/render-item/correct-answer-view/${utilities.base64Encoding(itemReferenceID)}`);
|
207
|
+
});
|
208
|
+
});
|
209
|
+
|
210
|
+
it('Question instructions should be visible', () => {
|
211
|
+
utilities.verifyInnerText(chartsBarPage.questionInstructionsText(), 'Set the bar on the chart for the profits of the years');
|
212
|
+
utilities.verifyElementVisibilityState(chartsBarPage.questionInstructionsText(), 'visible');
|
213
|
+
});
|
214
|
+
|
215
|
+
it('Graph title, Y axis label and X axis label set by the user should be displayed in the chart', () => {
|
216
|
+
utilities.verifyInnerText(chartsBarPage.previewTabGraphTitle(), 'Graph of profits');
|
217
|
+
utilities.verifyInnerText(chartsBarPage.previewTabXAxisLabelButton(), 'Profit');
|
218
|
+
utilities.verifyInnerText(chartsBarPage.previewTabYAxisLabelButton(), 'Year');
|
219
|
+
});
|
220
|
+
|
221
|
+
it('Toolbar and control actions(Undo, Redo, Reset) should not be displayed', () => {
|
222
|
+
utilities.verifyElementVisibilityState(chartsBarPage.previewTabTool(), 'notExist');
|
223
|
+
utilities.verifyElementVisibilityState(chartsBarPage.previewTabToolBarWrapper(), 'notExist');
|
224
|
+
});
|
225
|
+
|
226
|
+
it('The correct answer set by user should be displayed in the correct answer view', () => {
|
227
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 0, barValue: 2, range: 20 });
|
228
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 1, barValue: 2, range: 20 });
|
229
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 2, barValue: 5, range: 20 });
|
230
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 3, barValue: 1, range: 20 });
|
231
|
+
chartsBarPage.steps.verifyBarHeightInPreviewTab({ barIndex: 4, barValue: 8, range: 20 });
|
232
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(0, 'correct');
|
233
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconNotExistsInPreviewTab(1);
|
234
|
+
chartsBarPage.steps.verifyBarIsLockedInPreviewTab(1);
|
235
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(2, 'correct');
|
236
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(3, 'correct');
|
237
|
+
chartsBarPage.steps.verifyBarCorrectIncorrectIconInPreviewTab(4, 'correct');
|
238
|
+
});
|
239
|
+
|
240
|
+
it('The points alloted to the question should be displayed', () => {
|
241
|
+
correctAnswerViewPage.steps.verifyAvailablePoints(10);
|
242
|
+
});
|
243
|
+
|
244
|
+
it('CSS of correct answer section', { tags: 'css' }, () => {
|
245
|
+
utilities.verifyCSS(chartsBarPage.previewTabGraphTitle(), {
|
246
|
+
'color': css.color.text,
|
247
|
+
'font-size': css.fontSize.default,
|
248
|
+
'font-weight': css.fontWeight.bold
|
249
|
+
});
|
250
|
+
utilities.verifyCSS(chartsBarPage.previewTabYAxisLabelButton(), {
|
251
|
+
'color': css.color.text,
|
252
|
+
'font-size': css.fontSize.default,
|
253
|
+
'font-weight': css.fontWeight.bold
|
254
|
+
});
|
255
|
+
utilities.verifyCSS(chartsBarPage.previewTabXAxisLabelButton(), {
|
256
|
+
'color': css.color.text,
|
257
|
+
'font-size': css.fontSize.default,
|
258
|
+
'font-weight': css.fontWeight.bold
|
259
|
+
});
|
260
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(0), {
|
261
|
+
'background-color': barBackgroundColor[0]
|
262
|
+
});
|
263
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(1), {
|
264
|
+
'background-color': barBackgroundColor[1]
|
265
|
+
});
|
266
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(2), {
|
267
|
+
'background-color': barBackgroundColor[2]
|
268
|
+
});
|
269
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(3), {
|
270
|
+
'background-color': barBackgroundColor[3]
|
271
|
+
});
|
272
|
+
utilities.verifyCSS(chartsBarPage.previewTabBar().eq(4), {
|
273
|
+
'background-color': barBackgroundColor[4]
|
274
|
+
});
|
275
|
+
utilities.verifyCSS(chartsBarPage.barLockIcon(), {
|
276
|
+
'background-color': css.color.defaultBackground,
|
277
|
+
});
|
278
|
+
});
|
279
|
+
|
280
|
+
it('Accessibility of correct answer section', { tags: 'a11y' }, () => {
|
281
|
+
cy.checkAccessibility(chartsBarPage.previewTabBar().parents('[class*="question-preview-wrapper"]'));
|
282
|
+
});
|
283
|
+
});
|
284
|
+
}
|
285
|
+
});
|