itemengine-cypress-automation 1.0.376-IEI-5742-and-IEI-5816-manualAndNonScoredScript-83d9dd2.0 → 1.0.377

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -111,10 +111,10 @@ describe('Create item page - Grid fill: Customize layout section - \'Fill Image\
111
111
  gridFillPage.steps.verifyFilledImageFileNameLabel('highlightImage.jpg');
112
112
  });
113
113
 
114
- it('When the user adds the image more than of 10MB, then error should be displayed', () => {
114
+ it('When the user adds the image more than of 10MB, then the file should not be uploaded', () => {
115
115
  gridFillPage.steps.uploadFilledImageFile('20mbFile.png');
116
- utilities.verifyElementVisibilityState(gridFillPage.errorMessage(), 'visible');
117
- utilities.verifyInnerText(gridFillPage.errorMessage(), 'Error: The file could not be uploaded. The file is 21 MB exceeding the maximum size of 10 MB.');
116
+ gridFillPage.steps.verifyFilledImageFileNameLabel('highlightImage.jpg');
117
+ gridFillPage.steps.verifyErrorMessageDoesNotHaveText();
118
118
  });
119
119
 
120
120
  it('Delete button should appear beside uploaded file\'s name', () => {
@@ -319,10 +319,9 @@ describe('Create item page - Grid fill: Customize layout section - \'Fill Image\
319
319
  gridFillPage.steps.verifyBackgroundImageIsNotDisplayedInEditTabGrids();
320
320
  });
321
321
 
322
- it('When the user adds the image more than of 10MB, then error should be displayed', () => {
322
+ it('When the user adds the image more than of 10MB, then error should not be displayed', () => {
323
323
  gridFillPage.steps.uploadFile('20mbFile.png');
324
- utilities.verifyElementVisibilityState(gridFillPage.errorMessage(), 'visible');
325
- utilities.verifyInnerText(gridFillPage.errorMessage(), 'Error: The file could not be uploaded. The file is 21 MB exceeding the maximum size of 10 MB.');
324
+ gridFillPage.steps.verifyErrorMessageIsNotDisplayed();
326
325
  });
327
326
  });
328
327
 
@@ -44,14 +44,12 @@ describe('Create item page - Grid fill: Header section and Saving question', ()
44
44
  describe('Validation error messages', () => {
45
45
  dialogBoxBase.tests.verifyRequiredFieldsWarningPopupOnClickingSaveButton(['Please set points']);
46
46
 
47
- it('Validation error messages should be displayed below required input fields', () => {
47
+ it('Validation error messages and error icons should not be displayed below required input fields', () => {
48
48
  gridFillPage.steps.verifyQuestionInstructionsErrorMessageIsNotDisplayed();
49
- utilities.verifyInnerText(gridFillPage.errorMessage(), 'Error: Please set a correct answer.');
50
49
  gridFillPage.steps.verifyPointsFieldErrorMessageIsNotDisplayed();
51
- gridFillPage.steps.verifySpecifyCorrectAnswerErrorIconIsVisible();
50
+ gridFillPage.steps.verifySpecifyCorrectAnswerErrorIconNotExists();
52
51
  });
53
52
 
54
- //failed due to https://redmine.zeuslearning.com/issues/564243
55
53
  it('Validation error messages should disappear when required input fields are filled', () => {
56
54
  gridFillPage.steps.addTextInQuestionInstructionsInputField('Grid fill');
57
55
  gridFillPage.steps.selectCellSpecifyCorrectAnswerSection(0, 0);
@@ -30,7 +30,6 @@ describe('Create Item page - Grid fill: Specify Correct answer, Alternative corr
30
30
  gridFillPage.tests.verifyAutoScoredAddAlternativeAnswerButtonAndValidation();
31
31
 
32
32
  it('When user has added points and selected grid cells in the \'Correct\' accordion, then the user should be able to add alternative answer for the question using \'Add alternative answer\' button', () => {
33
- gridFillPage.steps.closeWarningPopup();
34
33
  gridFillPage.steps.selectCellSpecifyCorrectAnswerSection(0, 0);
35
34
  gridFillPage.steps.allotPoints(20);
36
35
  gridFillPage.steps.addAlternativeAnswerAccordion(1);
@@ -60,11 +59,10 @@ describe('Create Item page - Grid fill: Specify Correct answer, Alternative corr
60
59
  gridFillPage.steps.verifyAlternativeAnswerAccordionNotExists(2);
61
60
  });
62
61
 
63
- //Make changes once https://redmine.zeuslearning.com/issues/579214 is resolved
64
- it('\'Error: Please set a correct answer.\' error message should be displayed', () => {
62
+ it('\'Error: Please set a correct answer.\' error message should not be displayed', () => {
65
63
  gridFillPage.steps.addInputToCellShadeCountInputField(5);
66
64
  gridFillPage.steps.clearCellShadeCountInputField();
67
- utilities.verifyInnerText(gridFillPage.errorMessage(), 'Error: Please set a correct answer.');
65
+ gridFillPage.steps.verifyErrorMessageIsNotDisplayed();
68
66
  });
69
67
 
70
68
  it('When user has given an input in \'Cell shade count\' then user should be able to add another alternate accordion', () => {
@@ -283,7 +283,8 @@ describe('Create item page - Image highlight: Partial different weights', () =>
283
283
  });
284
284
  });
285
285
 
286
- describe('Question preview: Auto scored - Partial different weights: Penalty scoring with \'Round negative score to zero\' unchecked', () => {
286
+ //Failing due to https://weldnorthed.atlassian.net/browse/IEI-5839
287
+ describe.skip('Question preview: Auto scored - Partial different weights: Penalty scoring with \'Round negative score to zero\' unchecked', () => {
287
288
  abortEarlySetup();
288
289
  before(() => {
289
290
  imageHighlightPage.steps.navigateToCreateQuestion('image highlight');
@@ -32,7 +32,8 @@ describe('Create question page - Highlight image: Header section and Saving ques
32
32
  imageHighlightPage.tests.verifyTabsSection();
33
33
  });
34
34
 
35
- describe('Cancel button', () => {
35
+ //Failing due to https://weldnorthed.atlassian.net/browse/IEI-5837
36
+ describe.skip('Cancel button', () => {
36
37
  abortEarlySetup();
37
38
  before(() => {
38
39
  imageHighlightPage.steps.navigateToCreateQuestion('image highlight');
@@ -270,10 +270,10 @@ describe('Image highlight - Student view settings', () => {
270
270
  imageHighlightPage.steps.highlightARegionInSpecifyCorrectAnswerSection(1);
271
271
  });
272
272
 
273
- it('When user tries to select more number of options than the maximum number of options dropdown, then error message \'Error: maximum # options can be selected.\' should be displayed and user should not be able to select the option', () => {
273
+ it('When user tries to select more number of options than the maximum number of options dropdown, then error message should not be displayed', () => {
274
274
  imageHighlightPage.steps.clickOnARegionInSpecifyCorrectAnswerSection(2);
275
275
  imageHighlightPage.steps.verifyRegionIsNotHighlightedInSetCorrectAnswerSection(2);
276
- utilities.verifyInnerText(imageHighlightPage.maximumOptionsCanBeSelectedErrorMessage(), 'Error: maximum 2 options can be selected.');
276
+ imageHighlightPage.steps.verifyErrorMessageIsNotDisplayed();
277
277
  });
278
278
 
279
279
  it('\'Show student the maximum number of possible selections\' label and checkbox should be displayed. By default the checkbox should be unchecked', () => {
@@ -94,7 +94,6 @@ describe('Create Item page - Text Selection', () => {
94
94
  textSelectionPage.steps.clickOnOptionInSpecifyPossibleOptionsSection(paragraphTextArray[0]);
95
95
  textSelectionPage.steps.clickOnOptionInSpecifyPossibleOptionsSection(paragraphTextArray[1]);
96
96
  textSelectionPage.steps.clickOnOptionInSpecifyPossibleOptionsSection(paragraphTextArray[2]);
97
- textSelectionPage.steps.switchToPreviewTab();
98
97
  });
99
98
 
100
99
  it('When the user selects \'Grading\' view without setting the answer, correct answers section and answer status banner should not be displayed', () => {
@@ -71,7 +71,7 @@ describe('Create Item page - Text selection: Text selection modes in specify pos
71
71
  textSelectionPage.steps.verifyOptionCounterTextAndValue(1);
72
72
  });
73
73
 
74
- it('When user clears all selected options with the \'Clear\' button, then all the selected options should be deselected and the specify possible options field should be in errored state with the error message \'Error: Minimum one highlight option is required.\'', () => {
74
+ it('When user clears all selected options with the \'Clear\' button, then all the selected options should be deselected and the specify possible options field should not be in errored state with the error message', () => {
75
75
  cy.log('Pre-step: Selecting multiple texts to create options');
76
76
  textSelectionPage.steps.selectOptionInSpecifyPossibleOptionsSection('Custom', customTextArray[0]);
77
77
  textSelectionPage.steps.selectOptionInSpecifyPossibleOptionsSection('Custom', customTextArray[1]);
@@ -211,19 +211,16 @@ describe('Create Item page - Text selection: Text selection modes in specify pos
211
211
  textSelectionPage.steps.verifyOptionIsNotSelectedInSpecifyPossibleOptionsSection(paragraphTextArray[2]);
212
212
  });
213
213
 
214
- it('When user clicks on \'Confirm\' button of the Clear popup, then the popup should be closed and all the selected options should be deselected and the specify possible options field should be in errored state with the error message \'Error: Minimum one highlight option is required.\'', () => {
214
+ it('When user clicks on \'Confirm\' button of the Clear popup, then the popup should be closed and all the selected options should be deselected and the specify possible options field should not be in errored state with the error message', () => {
215
215
  cy.log('Pre-step: Again clicking on Clear button to open Clear popup');
216
216
  textSelectionPage.steps.clickOnClearOptionsButtonInSpecifyPossibleOptionSection();
217
217
  textSelectionPage.steps.clickOnAcceptButtonInDialogBox();
218
218
  for (let arrayIndex = 0; arrayIndex < paragraphTextArray.length; arrayIndex++) {
219
219
  textSelectionPage.steps.verifyOptionIsNotSelectedInSpecifyPossibleOptionsSection(paragraphTextArray[arrayIndex]);
220
220
  }
221
- utilities.verifyInnerText(textSelectionPage.errorMessage(), 'Error: Minimum one highlight option is required.');
222
- textSelectionPage.steps.verifyErroredStateOfSpecifyPossibleOptionsSection();
221
+ textSelectionPage.steps.verifyErrorMessageIsNotDisplayed();
223
222
  });
224
223
 
225
- textSelectionPage.tests.verifyErrorMessageCSSAndA11y();
226
-
227
224
  it('When user click on a deselected option, the option should be selected and the error message should disappear and option counter should display 1 count', () => {
228
225
  textSelectionPage.steps.selectOptionInSpecifyPossibleOptionsSection('Paragraph', paragraphTextArray[0]);
229
226
  utilities.verifyElementVisibilityState(textSelectionPage.errorMessage(), 'notExist');
@@ -286,8 +283,7 @@ describe('Create Item page - Text selection: Text selection modes in specify pos
286
283
  it('When user clears all selected options with the \'Clear\' button, then all the selected options should be deselected and the specify possible options field should be in errored state with the error message \'Error: Minimum one highlight option is required.\'', () => {
287
284
  textSelectionPage.steps.clearSelectedOptionsInSpecifyPossibleOptionSection();
288
285
  utilities.verifyElementVisibilityState(textSelectionPage.selectedOptionSpecifyPossibleOptions(), 'notExist');
289
- utilities.verifyInnerText(textSelectionPage.errorMessage(), 'Error: Minimum one highlight option is required.');
290
- textSelectionPage.steps.verifyErroredStateOfSpecifyPossibleOptionsSection();
286
+ textSelectionPage.steps.verifyErrorMessageIsNotDisplayed();
291
287
  });
292
288
 
293
289
  textSelectionPage.tests.verifyErrorMessageCSSAndA11y();
@@ -355,18 +351,17 @@ describe('Create Item page - Text selection: Text selection modes in specify pos
355
351
  textSelectionPage.steps.verifyHoverStateOfDeselectedOptionInSpecifyPossibleOptionsSection(wordTextArray[2], 'blue');
356
352
  });
357
353
 
358
- it('When user clears all selected options with the \'Clear\' button, then all the selected options should be deselected and the specify possible options field should be in errored state with the error message \'Error: Minimum one highlight option is required.\'', () => {
354
+ it('When user clears all selected options with the \'Clear\' button, then all the selected options should be deselected and the specify possible options field should not be in errored state with the error message', () => {
359
355
  textSelectionPage.steps.clearSelectedOptionsInSpecifyPossibleOptionSection();
360
356
  for (let arrayIndex = 0; arrayIndex < sentenceTextArray.length; arrayIndex++) {
361
357
  textSelectionPage.steps.verifyOptionIsNotSelectedInSpecifyPossibleOptionsSection(wordTextArray[arrayIndex]);
362
358
  }
363
- utilities.verifyInnerText(textSelectionPage.errorMessage(), 'Error: Minimum one highlight option is required.');
364
- textSelectionPage.steps.verifyErroredStateOfSpecifyPossibleOptionsSection();
359
+ textSelectionPage.steps.verifyErrorMessageIsNotDisplayed();
365
360
  });
366
361
 
367
362
  textSelectionPage.tests.verifyErrorMessageCSSAndA11y();
368
363
 
369
- it('When user click on a deselected option, the option should be selected and the error message should disappear and option counter should display 1 count', () => {
364
+ it('When user click on a deselected option, the option should be selected and the error message should not be displayed and option counter should display 1 count', () => {
370
365
  textSelectionPage.steps.selectOptionInSpecifyPossibleOptionsSection('Word', wordTextArray[0]);
371
366
  utilities.verifyElementVisibilityState(textSelectionPage.errorMessage(), 'notExist');
372
367
  textSelectionPage.steps.verifyOptionCounterTextAndValue(1);
@@ -69,6 +69,7 @@ const steps = {
69
69
 
70
70
  expandFontSizeDropdown: () => {
71
71
  additionalSettingsPanel.fontSizeDropdown()
72
+ .trigger('mouseover')
72
73
  .click();
73
74
  }
74
75
  }
@@ -97,6 +97,10 @@ const steps = {
97
97
  utilities.verifyElementVisibilityState(commonComponents.tooltipText(), 'notExist');
98
98
  },
99
99
 
100
+ verifyErrorMessageDoesNotHaveText: () => {
101
+ commonComponents.errorMessage()
102
+ .should('not.have.text', 'Error:');
103
+ }
100
104
  }
101
105
 
102
106
  const tests = {
@@ -2917,25 +2917,25 @@ const tests = {
2917
2917
  'background-color': css.color.gridCellHoverStateBg
2918
2918
  });
2919
2919
  utilities.hoverAwayFromElement(utilities.getNthElement(gridFillPage.cellInSpecifyCorrectAnswerSection(), 9));
2920
+ utilities.triggerMouseout(utilities.getNthElement(gridFillPage.cellInSpecifyCorrectAnswerSection(), 9));
2920
2921
  });
2921
2922
 
2922
2923
  it('User should be able to select the cells of the grid by clicking on them', () => {
2923
2924
  gridFillPage.steps.selectCellSpecifyCorrectAnswerSection(0, 0);
2924
2925
  });
2925
2926
 
2926
- it(`When user deselect all the cells in the grid in the ${accordionName} accordion, \'Error: Please set a correct answer.\' error message should be thrown along with an error icon on the \'${accordionName}\' accordion`, () => {
2927
+ it(`When user deselect all the cells in the grid in the ${accordionName} accordion, error message and error icons should not be displayed on \'${accordionName}\' accordion`, () => {
2927
2928
  gridFillPage.steps.deselectCellSpecifyCorrectAnswerSection(0, 0);
2928
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'visible')
2929
- utilities.verifyInnerText(commonComponents.errorMessage(), 'Error: Please set a correct answer.');
2929
+ gridFillPage.steps.verifyErrorMessageIsNotDisplayed();
2930
2930
  if (accordionName == 'Correct') {
2931
2931
  autoScoredSpecifyCorrectAnswerSection.correctAnswerAccordion()
2932
2932
  .within(() => {
2933
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
2933
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
2934
2934
  });
2935
2935
  } else {
2936
2936
  autoScoredSpecifyCorrectAnswerSection.alternativeAnswerAccordion()
2937
2937
  .within(() => {
2938
- utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'visible');
2938
+ utilities.verifyElementVisibilityState(autoScoredSpecifyCorrectAnswerSection.specifyCorrectAnswerErrorIcon(), 'notExist');
2939
2939
  });
2940
2940
  };
2941
2941
  });
@@ -2980,10 +2980,9 @@ const tests = {
2980
2980
  utilities.verifyInputFieldValue(gridFillPage.cellShadeCountInputField(), '6');
2981
2981
  });
2982
2982
 
2983
- it(`When user clears the value in \'Cell shade count\' input field, then \'Error: Please set a correct answer.\' error message should be thrown along with an error icon on the \'${accordionName}\' accordion`, () => {
2983
+ it(`When user clears the value in \'Cell shade count\' input field, then error message should not be thrown along with an error icon on the \'${accordionName}\' accordion`, () => {
2984
2984
  gridFillPage.steps.clearCellShadeCountInputField();
2985
- utilities.verifyElementVisibilityState(commonComponents.errorMessage(), 'visible')
2986
- utilities.verifyInnerText(commonComponents.errorMessage(), 'Error: Please set a correct answer.');
2985
+ gridFillPage.steps.verifyErrorMessageIsNotDisplayed();
2987
2986
  });
2988
2987
 
2989
2988
  it('CSS of \'Cell shade count\' input field error message', { tags: 'css' }, () => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.376-IEI-5742-and-IEI-5816-manualAndNonScoredScript-83d9dd2.0",
3
+ "version": "1.0.377",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -52,4 +52,4 @@
52
52
  "devDependencies": {
53
53
  "@applitools/eyes-cypress": "^3.47.0"
54
54
  }
55
- }
55
+ }