itemengine-cypress-automation 1.0.347-IEI-4974-47ab7e2.0 → 1.0.347-IEI-4974-acd3dc9.0

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.
@@ -187,8 +187,8 @@ describe('Audio player: Edit tab', () => {
187
187
  });
188
188
 
189
189
  it('The user should be able to enter text in the \'Transcript\' input field', () => {
190
- multipleSelectionPage.steps.enterTextInTranscriptInputField('This is a transcript text');
191
- utilities.verifyTextContent(multipleSelectionPage.typeInTranscriptInputField(), 'This is a transcript text');
190
+ multipleSelectionPage.steps.enterTextInCKEditorTranscriptInputField('This is a transcript text');
191
+ utilities.verifyTextContent(multipleSelectionPage.cKEditorTranscriptInputField(), 'This is a transcript text');
192
192
  });
193
193
 
194
194
  it('CSS of \'Type in transcript\' Section', { tags: 'css' }, () => {
@@ -31,8 +31,8 @@ describe('Audio player: Header section, buttons and saving item', () => {
31
31
 
32
32
  describe('OK button Contents', () => {
33
33
  it('\'OK\' button should be displayed in popup.', () => {
34
- utilities.verifyInnerText(multipleSelectionPage.okButton(), 'OK');
35
- utilities.verifyElementVisibilityState(multipleSelectionPage.okButton(), 'visible');
34
+ utilities.verifyInnerText(multipleSelectionPage.audioPlayerOkButton(), 'OK');
35
+ utilities.verifyElementVisibilityState(multipleSelectionPage.audioPlayerOkButton(), 'visible');
36
36
  });
37
37
 
38
38
  it('CSS of \'OK\' button', { tags: 'css' }, () => {
@@ -32,7 +32,7 @@ describe('Audio player: Edit tab', () => {
32
32
  multipleSelectionPage.steps.switchToEditTab();
33
33
  multipleSelectionPage.steps.clickOnAudioPlayerBlock();
34
34
  multipleSelectionPage.steps.clickOnLimitPlayAttempts();
35
- multipleSelectionPage.steps.setPlaybackLimit(2);
35
+ multipleSelectionPage.steps.setCKEditorPlaybackLimit(2);
36
36
  multipleSelectionPage.steps.clickOnOKButton();
37
37
  multipleSelectionPage.steps.focusInAndOutOfQuestionInstructionsInputField();
38
38
  multipleSelectionPage.steps.switchToPreviewTab();
@@ -32,7 +32,6 @@ describe('Audio player: Edit tab', () => {
32
32
  multipleSelectionPage.steps.switchToEditTab();
33
33
  multipleSelectionPage.steps.clickOnAudioPlayerBlock();
34
34
  multipleSelectionPage.steps.uploadTranscriptFile('sample.txt');
35
- utilities.verifyElementVisibilityState(multipleSelectionPage.transcriptFileUploadProgressBar(), 'visible');
36
35
  multipleSelectionPage.steps.clickOnOKButton();
37
36
  multipleSelectionPage.steps.focusInAndOutOfQuestionInstructionsInputField();
38
37
  multipleSelectionPage.steps.switchToPreviewTab();
@@ -49,7 +48,7 @@ describe('Audio player: Edit tab', () => {
49
48
  multipleSelectionPage.steps.switchToEditTab();
50
49
  multipleSelectionPage.steps.clickOnAudioPlayerBlock();
51
50
  multipleSelectionPage.steps.clickOnTypeInTranscriptRadioButton();
52
- multipleSelectionPage.steps.enterTextInTranscriptInputField('In triangle ABC,m ∠ ABC = (4x-12) ° and m ∠ ACB = (2x + 26) °');
51
+ multipleSelectionPage.steps.enterTextInCKEditorTranscriptInputField('In triangle ABC,m ∠ ABC = (4x-12) ° and m ∠ ACB = (2x + 26) °');
53
52
  multipleSelectionPage.steps.clickOnOKButton();
54
53
  multipleSelectionPage.steps.focusInAndOutOfQuestionInstructionsInputField();
55
54
  multipleSelectionPage.steps.switchToPreviewTab();
@@ -73,7 +72,7 @@ describe('Audio player: Edit tab', () => {
73
72
  multipleSelectionPage.steps.uploadFile('sample.mp3');
74
73
  utilities.verifyElementVisibilityState(multipleSelectionPage.fileUploadProgressBar(), 'hidden');
75
74
  multipleSelectionPage.steps.clickOnTypeInTranscriptRadioButton();
76
- multipleSelectionPage.steps.enterTextInTranscriptInputField('In triangle ABC,m ∠ ABC = (4x-12) ° and m ∠ ACB = (2x + 26) °');
75
+ multipleSelectionPage.steps.enterTextInCKEditorTranscriptInputField('In triangle ABC,m ∠ ABC = (4x-12) ° and m ∠ ACB = (2x + 26) °');
77
76
  multipleSelectionPage.steps.clickOnOKButton();
78
77
  });
79
78
 
@@ -28,8 +28,8 @@ describe('Insert Image: Edit tab', () => {
28
28
  });
29
29
 
30
30
  it('\'URL\', \'Alternative Text\', \'Width\', \'Height\', \'Border\', \'HSpace\', \'VSpace\' label with input field for each individual label and \'Preview\' label with image preview box should be visible ', () => {
31
- utilities.verifyInnerText(multipleSelectionPage.urlLabel(), 'URL');
32
- utilities.verifyElementVisibilityState(multipleSelectionPage.urlLabel(), 'visible');
31
+ utilities.verifyInnerText(multipleSelectionPage.imageUrlLabel(), 'URL');
32
+ utilities.verifyElementVisibilityState(multipleSelectionPage.imageUrlLabel(), 'visible');
33
33
  utilities.verifyElementVisibilityState(multipleSelectionPage.urlInputField(), 'visible');
34
34
  utilities.verifyInnerText(multipleSelectionPage.alternateTextLabel(), 'Alternative Text');
35
35
  utilities.verifyElementVisibilityState(multipleSelectionPage.alternateTextLabel(), 'visible');
@@ -82,7 +82,7 @@ describe('Insert Image: Edit tab', () => {
82
82
  'font-size': '12px',
83
83
  'font-weight': '400'
84
84
  });
85
- utilities.verifyCSS(multipleSelectionPage.urlLabel(), {
85
+ utilities.verifyCSS(multipleSelectionPage.imageUrlLabel(), {
86
86
  'color': 'rgb(0, 0, 0)',
87
87
  'font-size': '12px',
88
88
  'font-weight': '400'
@@ -82,8 +82,8 @@ describe('Insert Table: Edit tab', () => {
82
82
  it('\'Border size\' label and input field with default value 1, \'Striped\' label and 3 strip options with default value none and \'Add hover state\' label and dropdown with default value none should be displayed.', () => {
83
83
  multipleSelectionPage.steps.scrollingDownInInsertTablePopUp();
84
84
  utilities.verifyInnerText(multipleSelectionPage.borderSizeLabel(), 'Border size');
85
- utilities.verifyElementVisibilityState(multipleSelectionPage.borderSizeLabel(), 'visible');
86
- utilities.verifyElementVisibilityState(multipleSelectionPage.borderSizeInputField(), 'visible');
85
+ utilities.verifyElementVisibilityState(multipleSelectionPage.borderSizeLabel(), 'exist');
86
+ utilities.verifyElementVisibilityState(multipleSelectionPage.borderSizeInputField(), 'exist');
87
87
  utilities.verifyInnerText(multipleSelectionPage.stripedLabel(), 'Striped');
88
88
  utilities.verifyElementVisibilityState(multipleSelectionPage.stripedLabel(), 'visible');
89
89
  utilities.verifyElementVisibilityState(multipleSelectionPage.clearStripes(), 'visible');
@@ -24,7 +24,7 @@ describe('Link Ck Editor: Edit tab', () => {
24
24
  utilities.verifyElementVisibilityState(multipleSelectionPage.uploadSectionTitle(), 'visible');
25
25
  utilities.verifyInnerText(multipleSelectionPage.uploadTitle(), 'Upload');
26
26
  utilities.verifyElementVisibilityState(multipleSelectionPage.uploadTitle(), 'visible');
27
- utilities.verifyElementVisibilityState(multipleSelectionPage.insertImageChooseFileButton(), 'visible');
27
+ utilities.verifyElementVisibilityState(multipleSelectionPage.insertImageChooseFileButton(), 'exist');
28
28
  utilities.verifyInnerText(multipleSelectionPage.sendItToServerButton(), 'Send it to the Server');
29
29
  utilities.verifyElementVisibilityState(multipleSelectionPage.sendItToServerButton(), 'visible');
30
30
  });
@@ -51,6 +51,8 @@ const selectors = {
51
51
  typeInTranscriptLabel: () => cy.get('.type-in-transcript-opt-label'),
52
52
  typeInTranscriptRadioButton: () => cy.get('[aria-label="Type in transcript"][type="radio"]'),
53
53
  transcriptInputField: () => cy.get('[title="Transcript"]'),
54
+ cKEditorTranscriptInputField: () => cy.get('textarea[aria-label="Transcript"]'),
55
+ ckEditorPlayAttemptsLimitInputField: () => cy.get('input[aria-label="Playback Limit"]'),
54
56
  allowStudentsToDownloadAudioLabel: () => cy.get('.allow-students-to-download-audio .MuiFormControlLabel-label').eq(0),
55
57
  allowStudentsToDownloadAudioCheckbox: () => cy.get('.allow-students-to-download-audio input'),
56
58
  limitPlayAttemptsLabel: () => cy.get('.allow-students-to-download-audio .MuiFormControlLabel-label').eq(1),
@@ -168,6 +170,13 @@ const steps = {
168
170
  .blur();
169
171
  },
170
172
 
173
+ enterTextInCKEditorTranscriptInputField: (text) => {
174
+ audioPlayerPage.cKEditorTranscriptInputField()
175
+ .type(text)
176
+ .blur();
177
+ },
178
+
179
+
171
180
  verifyTextInTranscriptInputField: (text) => {
172
181
  audioPlayerPage.transcriptInputField()
173
182
  .should('have.text', text);
@@ -708,6 +717,20 @@ const steps = {
708
717
  .type(value)
709
718
  },
710
719
 
720
+ /**
721
+ * Sets the playback limit value in the audio player's input field.
722
+ * @param {string|number} value - The value to set as the playback limit.
723
+ * @returns {void}
724
+ */
725
+ setCKEditorPlaybackLimit: (value) => {
726
+ audioPlayerPage.ckEditorPlayAttemptsLimitInputField()
727
+ .clear()
728
+ .type(value);
729
+ cy.wait(2000);
730
+ audioPlayerPage.ckEditorPlayAttemptsLimitInputField()
731
+ .blur();
732
+ },
733
+
711
734
  /**
712
735
  * Verify the playback limit help text in preview tab
713
736
  * @param {string|number} value - The value to set as the playback limit.
@@ -20,7 +20,7 @@ const selectors = {
20
20
  selectAManipulativeLabel: () => cy.get('[class*="SelectManipulativeWrapper"] [class*="BrainingcampManipulativestyle__WrapperSubHeader"]'),
21
21
  enterAShareCodeLabel: () => cy.get('[class*="EnterShareCodeWrapper"] [class*="BrainingcampManipulativestyle__WrapperSubHeader"]'),
22
22
  enterAShareCodeInputField: () => cy.get('[class*="EnterShareCodeWrapper"] input'),
23
- previewTabCanvas: () => cy.get('.canvas'),
23
+ previewTabCanvas: () => cy.get('.bcm-inner')
24
24
  }
25
25
 
26
26
  const steps = {
@@ -9,6 +9,7 @@ const selectors = {
9
9
  equationEditorIcon: () => cy.get('.cke_button__nextgeneqneditor_icon:visible'),
10
10
  equationEditorLabel: () => cy.get('[class*="EquationEditorstyles__Heading"]'),
11
11
  okButton: () => cy.get('[title="OK"]'),
12
+ audioPlayerOkButton: () => cy.get('.save-action-btn-wrapper button').eq(0),
12
13
  editorCancelButton: () => cy.get('[title="Cancel"]'),
13
14
  equationEditorPopUp: () => cy.get('[class*="EquationEditorstyles__EquationEditorContainer"]'),
14
15
  equationWrapper: () => cy.get('.cke_widget_ngie_equation [class*="NGMathJax"]'),
@@ -15,7 +15,7 @@ const selectors = {
15
15
  imageInfoButton: () => cy.get('[title="Image Info"]'),
16
16
  uploadButton: () => cy.get('[title="Upload"]'),
17
17
  //Image Info
18
- urlLabel: () => cy.get('.dialog-input-label').eq(0),
18
+ imageUrlLabel: () => cy.get('.dialog-input-label').eq(0),
19
19
  urlInputField: () => cy.get('.cke_dialog_ui_input_text').eq(1),
20
20
  alternateTextLabel: () => cy.get('.dialog-input-label').eq(1),
21
21
  alternateTextInputField: () => cy.get('.cke_dialog_ui_input_text').eq(3),
@@ -23,7 +23,7 @@ const selectors = {
23
23
  widthInputField: () => cy.get('.cke_dialog_ui_input_text').eq(5),
24
24
  heightLabel: () => cy.get('.dialog-input-label').eq(3),
25
25
  heightInputField: () => cy.get('.cke_dialog_ui_input_text').eq(7),
26
- borderLabel: () => cy.get('[class="cke_dialog_ui_html"]').eq(2),
26
+ borderLabel: () => cy.get('.dialog-input-label').eq(4),
27
27
  borderInputField: () => cy.get('.cke_dialog_ui_input_text').eq(9),
28
28
  hSpaceLabel: () => cy.get('.dialog-input-label').eq(5),
29
29
  hSpaceInputField: () => cy.get('.cke_dialog_ui_input_text').eq(11),
@@ -36,7 +36,7 @@ const selectors = {
36
36
  fixedRadioButton: () => cy.get('[class*="image-responsiveness-radio-wrapper"]').eq(3),
37
37
  fixedRadioLabel: () => cy.get('[class*="image-responsiveness-radio-wrapper"]').eq(4),
38
38
  //Alignment
39
- alignmentLabel: () => cy.get('.dialog-input-label').eq(9),
39
+ alignmentLabel: () => cy.get('.dialog-input-label').eq(7),
40
40
  alignmentDropDown: () => cy.get('.cke_dialog_ui_input_select').eq(3),
41
41
  alignmentOptions: (alignment = null) => {
42
42
  if (alignment) {
@@ -12,7 +12,7 @@ const selectors = {
12
12
  linkLabel: () => cy.get('.dialog-header-label'),
13
13
  linkPopUpWrapper: () => cy.get('.custom-link-wrapper'),
14
14
  urlInQuestionInstruction: () => cy.get('[data-cke-saved-href*="https"]'),
15
- foxImageLinkUrlValueCheck: () => cy.get('[src*="https://cdn.pixabay.com/photo/2016/11/29/03/28/fox-1867062_960_720.jpg"]'),
15
+ foxImageLinkUrlValueCheck: () => cy.get('[href*="https://cdn.pixabay.com/photo/2016/11/29/03/28/fox-1867062_960_720.jpg"]'),
16
16
  urlInputField: () => cy.get('input[class*="cke_dialog_ui_input_text"]').eq(1),
17
17
  OkButton: () => cy.get('[title="OK"]'),
18
18
  //Link Info
@@ -24,8 +24,8 @@ const selectors = {
24
24
  linkTypeDropDown: () => cy.get('.cke_dialog_ui_input_select').eq(0),
25
25
  protocolLabel: () => cy.get('.dialog-input-label').eq(2),
26
26
  protocolDropDown: () => cy.get('.cke_dialog_ui_input_select').eq(1),
27
- urlLabel: () => cy.get('.dialog-input-label').eq(0),
28
- urlInputField: () => cy.get('.cke_dialog_ui_input_text').eq(0),
27
+ urlLabel: () => cy.get('.cke_dialog_ui_text .dialog-input-label').eq(1),
28
+ urlInputField: () => cy.get('.cke_dialog_ui_input_text input').eq(1),
29
29
  //Protocol
30
30
  protocolDropDown: () => cy.get('.dialog-input-area').eq(2),
31
31
  selectProtocolOptionDropdown: (protocolType = null) => {
@@ -55,8 +55,7 @@ const steps = {
55
55
 
56
56
  addURLInLinkPopUp: (text) => {
57
57
  ckEditorLinkComponent.urlInputField()
58
- .type(text, { delay: 0 })
59
- .blur();
58
+ .type(text, { delay: 0 });
60
59
  },
61
60
 
62
61
  addTextInDisplayText: (text) => {
@@ -72,7 +71,7 @@ const steps = {
72
71
 
73
72
  expandProtocolDropDown: () => {
74
73
  ckEditorLinkComponent.protocolDropDown()
75
- .click({force: true});
74
+ .click({ force: true });
76
75
  },
77
76
 
78
77
  selectProtocolType: (protocolType) => {
@@ -122,12 +121,12 @@ const steps = {
122
121
  doc.addEventListener('click', () => {
123
122
  setTimeout(function () { doc.location.reload() }, 5000);
124
123
  });
125
- ckEditorLinkComponent.foxImageLinkUrlValueCheckPreviewTab()
124
+ ckEditorLinkComponent.foxImageLinkUrlValueCheckPreviewTab()
126
125
  .click();
127
- cy.verifyDownload(fileName);
126
+ cy.verifyDownload(fileName);
128
127
  });
129
128
  },
130
-
129
+
131
130
 
132
131
  clickSendItToServerButton: () => {
133
132
  ckEditorLinkComponent.sendItToServerButton()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "itemengine-cypress-automation",
3
- "version": "1.0.347-IEI-4974-47ab7e2.0",
3
+ "version": "1.0.347-IEI-4974-acd3dc9.0",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {