itemengine-cypress-automation 1.0.214 → 1.0.215

Sign up to get free protection for your applications and to get access to all the features.
@@ -18,13 +18,14 @@ describe('Create item page - Fill in the gaps with text: All or nothing with alt
18
18
  fillInTheGapsTextPage.steps.addAlternativeAnswerAccordion(1);
19
19
  fillInTheGapsTextPage.steps.enterTextInAnswerInputFieldsSpecifyCorrectAnswerSection([{ responseIndex: 0, responseText: 'Petals' }, { responseIndex: 1, responseText: 'Leaves' }, { responseIndex: 2, responseText: 'Stem' }]);
20
20
  fillInTheGapsTextPage.steps.allotPoints(20);
21
- //fillInTheGapsTextPage.steps.checkAllowStudentToCheckAnswerCheckbox();
21
+ //fillInTheGapsTextPage.steps.checkAllowStudentToCheckAnswerCheckbox();
22
22
  fillInTheGapsTextPage.steps.switchToPreviewTab();
23
23
  });
24
24
 
25
25
  it('When the user selects \'Grading\' view without attempting the question, response area numeration should be displayed, correct answers section should be displayed with correct answers from the alternative accordion and respective response area numeration', () => {
26
26
  fillInTheGapsTextPage.steps.switchToGradingView();
27
27
  fillInTheGapsTextPage.steps.verifyResponseAreaNumeration();
28
+ fillInTheGapsTextPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
28
29
  fillInTheGapsTextPage.steps.verifyCorrectAnswerResponsesInCorrectAnswerSectionAndCount(['Petals', 'Leaves', 'Stem']);
29
30
  });
30
31
 
@@ -24,6 +24,7 @@ describe('Create item page - Fill in the gaps with text: All or nothing with alt
24
24
  it('When the user selects \'Grading\' view without attempting the question, response area numeration should be displayed, correct answers section should be displayed with correct answers from the correct accordion and respective response area numeration', () => {
25
25
  fillInTheGapsTextPage.steps.switchToGradingView();
26
26
  fillInTheGapsTextPage.steps.verifyResponseAreaNumeration();
27
+ fillInTheGapsTextPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
27
28
  fillInTheGapsTextPage.steps.verifyCorrectAnswerResponsesInCorrectAnswerSectionAndCount(['Flower', 'Leaf', 'Stem']);
28
29
  });
29
30
 
@@ -26,6 +26,7 @@ describe('Create item page - Fill in the gaps with text: All or nothing with alt
26
26
  it('When the user selects \'Grading\' view without attempting the question, response area numeration should be displayed, correct answers section should be displayed with correct answers from the correct accordion and respective response area numeration', () => {
27
27
  fillInTheGapsTextPage.steps.switchToGradingView();
28
28
  fillInTheGapsTextPage.steps.verifyResponseAreaNumeration();
29
+ fillInTheGapsTextPage.steps.verifyCorrectIncorrectStatusMessageNotExists();
29
30
  fillInTheGapsTextPage.steps.verifyCorrectAnswerResponsesInCorrectAnswerSectionAndCount(['Flower', 'Leaf', 'Stem']);
30
31
  });
31
32
 
@@ -44,6 +44,7 @@ describe('Fill In the gaps with text - Additional settings', () => {
44
44
  fillInTheGapsTextPage.steps.selectFontSizeOptionFromFontSizeDropdown(option);
45
45
  utilities.verifyInnerText(fillInTheGapsTextPage.fontSizeDropdown(), `${option}`);
46
46
  fillInTheGapsTextPage.steps.switchToPreviewTab();
47
+ fillInTheGapsTextPage.steps.enterTextInAnswerInputFieldsPreviewTab([{ responseIndex: 0, responseText: 'Flower' }]);
47
48
  utilities.verifyCSS(fillInTheGapsTextPage.questionInstructionsText(), {
48
49
  'font-size': fontSizes[option]
49
50
  });
@@ -85,9 +85,9 @@ describe('Create item page - Fill in the gaps with text: Scoring section', () =>
85
85
 
86
86
  it('When the user adds one more response area, then points per response should get updated accordingly', () => {
87
87
  fillInTheGapsTextPage.steps.addResponseArea();
88
- fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(0, 1.33);
89
- fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(1, 1.33);
90
- fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(2, 1.33);
88
+ fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(0, 1.3333);
89
+ fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(1, 1.3333);
90
+ fillInTheGapsTextPage.steps.verifyPointsDisplayedOnResponseAccordion(2, 1.3333);
91
91
  });
92
92
 
93
93
  it('When the user deletes a response token, then points per response should get updated accordingly', () => {
@@ -178,8 +178,14 @@ const steps = {
178
178
  autoScoredScoringSectionMultiResponseType.pointsInputField()
179
179
  .eq(indexNumber)
180
180
  .should('not.be.disabled')
181
+ autoScoredScoringSectionMultiResponseType.pointsInputField()
182
+ .eq(indexNumber)
181
183
  .clear()
182
- .type(`${points}`, { delay: 500 })
184
+ autoScoredScoringSectionMultiResponseType.pointsInputField()
185
+ .eq(indexNumber)
186
+ .type(`${points}`, { delay: 500 });
187
+ autoScoredScoringSectionMultiResponseType.pointsInputField()
188
+ .eq(indexNumber)
183
189
  .blur()
184
190
  .should('have.value', points);
185
191
  });
@@ -39,6 +39,7 @@ const steps = {
39
39
  },
40
40
 
41
41
  switchToPreviewTab: () => {
42
+ cy.wait(500);
42
43
  createQuestionBasePage.previewTab()
43
44
  .click()
44
45
  .should('have.attr', 'aria-selected', 'true');
@@ -112,7 +113,7 @@ const tests = {
112
113
  });
113
114
 
114
115
  it('\'Save\' button should be displayed', () => {
115
- let exceptionQuestions = ['Scientific calculator', 'Desmos graphing calculator', 'Desmos four-function calculator', 'Desmos geometry tool', 'Desmos matrix calculator', 'Passage', 'Reading ruler', 'Audio player', 'Ruler', 'Protractor', 'GeoGebra graphing calculator', 'GeoGebra scientific calculator', 'GeoGebra 3D graphing calculator', 'GeoGebra geometry calculator', 'GeoGebra CAS calculator', 'GeoGebra probability calculator','Compass']
116
+ let exceptionQuestions = ['Scientific calculator', 'Desmos graphing calculator', 'Desmos four-function calculator', 'Desmos geometry tool', 'Desmos matrix calculator', 'Passage', 'Reading ruler', 'Audio player', 'Ruler', 'Protractor', 'GeoGebra graphing calculator', 'GeoGebra scientific calculator', 'GeoGebra 3D graphing calculator', 'GeoGebra geometry calculator', 'GeoGebra CAS calculator', 'GeoGebra probability calculator', 'Compass']
116
117
  if (exceptionQuestions.includes(questionType)) {
117
118
  utilities.verifyInnerText(createQuestionBasePage.saveQuestionButton(), 'Save');
118
119
  }
@@ -106,6 +106,8 @@ const steps = {
106
106
  .clear();
107
107
  utilities.getNthElement(fillInTheGapsTextCommonComponent.answerInputFieldSpecifyCorrectAnswerSection(), responseIndex)
108
108
  .type(responseText, { delay: 500 });
109
+ utilities.getNthElement(fillInTheGapsTextCommonComponent.answerInputFieldSpecifyCorrectAnswerSection(), responseIndex)
110
+ .click();
109
111
  utilities.getNthElement(fillInTheGapsTextCommonComponent.answerInputFieldSpecifyCorrectAnswerSection(), responseIndex)
110
112
  .blur();
111
113
  });
@@ -90,11 +90,11 @@ const steps = {
90
90
  scoringSectionBaseEditTab.minimumPointsInputField()
91
91
  .type(`${points}`)
92
92
  scoringSectionBaseEditTab.minimumPointsInputField()
93
- .should('have.value', points)
93
+ .should('have.value', points);
94
94
  scoringSectionBaseEditTab.minimumPointsInputField()
95
- .blur();
95
+ .click();
96
96
  scoringSectionBaseEditTab.minimumPointsInputField()
97
- .should('have.value', points)
97
+ .blur();
98
98
  },
99
99
 
100
100
  /**
@@ -361,11 +361,19 @@ const tests = {
361
361
 
362
362
  it('If the user enters points more than the allocated points in Minimum points input field, an error message \'Error: Minimum score cannot be greater than allocated points.: *points in points field*\' should be displayed', () => {
363
363
  scoringSectionBaseEditTab.steps.allotMinimumPoints(20);
364
+ scoringSectionBaseEditTab.minimumPointsInputField()
365
+ .focus();
366
+ scoringSectionBaseEditTab.minimumPointsInputField()
367
+ .blur();
364
368
  utilities.verifyInnerText(commonComponents.errorMessage().last(), 'Error: Minimum score cannot be greater than allocated points.: 10');
365
369
  });
366
370
 
367
371
  it('The error message should disappear once the user removes the entered points from the Minimum score awarded (if attempted) input field', () => {
368
372
  scoringSectionBaseEditTab.steps.clearMinimumPointsField();
373
+ scoringSectionBaseEditTab.minimumPointsInputField()
374
+ .click();
375
+ scoringSectionBaseEditTab.minimumPointsInputField()
376
+ .blur();
369
377
  utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'notExist');
370
378
  });
371
379
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.214",
3
+ "version": "1.0.215",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {