itemengine-cypress-automation 1.0.257 → 1.0.258
Sign up to get free protection for your applications and to get access to all the features.
- package/cypress/e2e/Gzip/gzip.js +128 -0
- package/cypress/e2e/ILC/BrainingCampManipulative/gradingViewAndCorrectAnswerViewContents.smoke.js +2 -1
- package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerEditTabAddFeatureRadioButton.js +17 -20
- package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerEditTabAudioPlayerStyle.js +53 -54
- package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerEditTabStudentViewSettings.js +0 -1
- package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerPreviewTab.js +37 -38
- package/cypress/e2e/ILC/CkEditorAudioPlayer/audioPlayerPreviewTabSupportedFileTypes.js +6 -6
- package/cypress/e2e/ILC/CkEditorInsertImage/upload.js +2 -2
- package/cypress/e2e/ILC/CkEditorLink/uploadSection.js +2 -2
- package/cypress/e2e/ILC/Compass/compassPreviewContent.smoke.js +5 -5
- package/cypress/e2e/ILC/DrawingResponse/drawingResponsePreviewTabContents.smoke.js +3 -0
- package/cypress/e2e/ILC/EssayResponse/createCustomCategory.smoke.js +3 -3
- package/cypress/e2e/ILC/FillInTheGapsDragAndDropNew/headerSection.js +3 -5
- package/cypress/e2e/ILC/Graphing/layoutAndGridOptions.js +12 -0
- package/cypress/e2e/ILC/Protractor/protractorPreviewContents.smoke.js +2 -1
- package/cypress/e2e/ILC/ReadingRuler/readingrulerPreviewContents.smoke.js +2 -1
- package/cypress/e2e/ILC/Ruler/rulerPreviewContents.smoke.js +2 -1
- package/cypress/e2e/ILC/SimpleCalculator/previewContents.smoke.js +3 -2
- package/cypress/e2e/ILC/TextEntryMath/MathTempleteLayout.js +172 -0
- package/cypress/e2e/ILC/ToolAudioPlayerNew/previewContents.smoke.js +2 -1
- package/cypress/e2e/ILC/UploadResponse/previewContentsForAllViews.smoke.js +2 -1
- package/cypress/e2e/ThirdPartyQuestions/GeoGebra/scientificCalculatorEditTabBasicSection.js +3 -3
- package/cypress/e2e/ThirdPartyQuestions/GeoGebra/scientificCalculatorPreviewTabContents.smoke.js +1 -1
- package/cypress/fixtures/equationEditorCategoriesAndSymbols .js +1 -1
- package/cypress/pages/components/ckEditorAudioPlayerComponent.js +12 -26
- package/cypress/pages/components/ckEditorEquationEditorComponent.js +2 -2
- package/cypress/pages/components/ckEditorInsertImageComponent.js +2 -2
- package/cypress/pages/components/equationEditorFlyout.js +2 -1
- package/cypress/pages/components/equationEditorSectionCommonComponent.js +2 -5
- package/deploy/e2e/deploy.yaml +2 -2
- package/deploy/smoke/deploy.yaml +2 -2
- package/package.json +3 -2
@@ -0,0 +1,128 @@
|
|
1
|
+
// Command for execution - npx cypress run --headed --browser chrome --env fileConfig=ilqa,assetVersion=1.0.409,CKEditorVersion=4.14.0.98 --spec "cypress\e2e\Gzip\gzip.js"
|
2
|
+
//assetVersion, CKEditorVersion should be updated according to the current version
|
3
|
+
|
4
|
+
const assetVersion = Cypress.env('assetVersion');
|
5
|
+
const CKEditorVersion = Cypress.env('CKEditorVersion');
|
6
|
+
|
7
|
+
describe('Assets GZIP compression', () => {
|
8
|
+
before(() => {
|
9
|
+
cy.loginAs('admin');
|
10
|
+
});
|
11
|
+
|
12
|
+
beforeEach(() => {
|
13
|
+
cy.restoreLocalStorage();
|
14
|
+
});
|
15
|
+
|
16
|
+
afterEach(() => {
|
17
|
+
cy.saveLocalStorage();
|
18
|
+
});
|
19
|
+
|
20
|
+
after(() => {
|
21
|
+
cy.logout();
|
22
|
+
});
|
23
|
+
|
24
|
+
it('Verifying equation-editor.bundle.js gzip', () => {
|
25
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/js/equation-editor.bundle.js`);
|
26
|
+
});
|
27
|
+
|
28
|
+
it('Verifying main.next-gen-item-engine-author.bundle.js gzip', () => {
|
29
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/js/main.next-gen-item-engine-author.bundle.js`);
|
30
|
+
});
|
31
|
+
|
32
|
+
it('Verifying main.next-gen-item-engine-items-api.bundle.js gzip', () => {
|
33
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/js/main.next-gen-item-engine-items-api.bundle.js`)
|
34
|
+
});
|
35
|
+
|
36
|
+
it('Verifying vendors.bundle.js gzip', () => {
|
37
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/js/vendors.bundle.js`);
|
38
|
+
});
|
39
|
+
|
40
|
+
it('Verifying (0-N).bundle.js gzip', () => {
|
41
|
+
const verifyBundle = (bundleIndex = 0) => {
|
42
|
+
cy.request({
|
43
|
+
method: 'GET',
|
44
|
+
url: `https://media.wne-cdn.com/static/itemengine/${assetVersion}/js/${bundleIndex}.bundle.js`,
|
45
|
+
headers: {
|
46
|
+
'accept-encoding': 'gzip, deflate, gzip, zstd',
|
47
|
+
},
|
48
|
+
failOnStatusCode: false,
|
49
|
+
}).then((response) => {
|
50
|
+
if (response.status === 403) {
|
51
|
+
cy.log(`Verification stopped. ${bundleIndex - 1}.bundle.js returned status 403.`);
|
52
|
+
} else {
|
53
|
+
cy.log(`Verifying ${bundleIndex}.bundle.js`);
|
54
|
+
expect(response.headers["content-encoding"]).to.be.oneOf(['gzip', 'br']);
|
55
|
+
verifyBundle(bundleIndex + 1);
|
56
|
+
}
|
57
|
+
});
|
58
|
+
};
|
59
|
+
verifyBundle();
|
60
|
+
});
|
61
|
+
|
62
|
+
it('Verifying /mathJax/tex-mml-svg.js gzip', () => {
|
63
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/mathJax/tex-mml-svg.js`)
|
64
|
+
});
|
65
|
+
|
66
|
+
//.css
|
67
|
+
it('Verifying main.css gzip', () => {
|
68
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/stylesheets/css/main.css`)
|
69
|
+
});
|
70
|
+
|
71
|
+
it('Verifying theme1.css gzip', () => {
|
72
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine/${assetVersion}/stylesheets/css/theme1.css`)
|
73
|
+
});
|
74
|
+
});
|
75
|
+
|
76
|
+
describe('CKEditor GZIP compression', () => {
|
77
|
+
before(() => {
|
78
|
+
cy.loginAs('admin');
|
79
|
+
});
|
80
|
+
|
81
|
+
beforeEach(() => {
|
82
|
+
cy.restoreLocalStorage();
|
83
|
+
});
|
84
|
+
|
85
|
+
afterEach(() => {
|
86
|
+
cy.saveLocalStorage();
|
87
|
+
});
|
88
|
+
|
89
|
+
after(() => {
|
90
|
+
cy.logout();
|
91
|
+
});
|
92
|
+
|
93
|
+
it('Verifying ngckeditor/ngckeditor.js gzip', () => {
|
94
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine-ckeditor/${CKEditorVersion}/ngckeditor/ngckeditor.js`);
|
95
|
+
});
|
96
|
+
|
97
|
+
//.css
|
98
|
+
it('Verifying custom_item_engine.css gzip', () => {
|
99
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine-ckeditor/${CKEditorVersion}/ngckeditor/css/custom_item_engine.css`)
|
100
|
+
});
|
101
|
+
|
102
|
+
//externalPlugins
|
103
|
+
it('Verifying externalPlugins/nextGenEqnEditor/plugin.js gzip', () => {
|
104
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine-ckeditor/${CKEditorVersion}/ngckeditor/externalPlugins/nextGenEqnEditor/plugin.js`)
|
105
|
+
});
|
106
|
+
|
107
|
+
it('Verifying externalPlugins/nextGenAudioPlayer/plugin.js gzip', () => {
|
108
|
+
steps.verifyGzipCompression(`https://media.wne-cdn.com/static/itemengine-ckeditor/${CKEditorVersion}/ngckeditor/externalPlugins/nextGenAudioPlayer/plugin.js`)
|
109
|
+
});
|
110
|
+
});
|
111
|
+
|
112
|
+
const steps = {
|
113
|
+
/**
|
114
|
+
* Sends a GET request to the specified URL and verifies that the content is gzip-compressed.
|
115
|
+
* @param {string} resourceLink The URL to be requested for gzip compression verification.
|
116
|
+
*/
|
117
|
+
verifyGzipCompression: (resourceLink) => {
|
118
|
+
cy.request({
|
119
|
+
method: 'GET',
|
120
|
+
url: resourceLink,
|
121
|
+
'accept-encoding': 'gzip, deflate, gzip, zstd',
|
122
|
+
}).then(
|
123
|
+
(response) => {
|
124
|
+
expect(response.headers["content-encoding"]).to.be.oneOf(['gzip', 'br']);
|
125
|
+
}
|
126
|
+
)
|
127
|
+
}
|
128
|
+
}
|
package/cypress/e2e/ILC/BrainingCampManipulative/gradingViewAndCorrectAnswerViewContents.smoke.js
CHANGED
@@ -12,7 +12,8 @@ describe('Create item page - Brainingcamp manipulative: Grading view, Correct an
|
|
12
12
|
});
|
13
13
|
|
14
14
|
if (views.includes('Grading view')) {
|
15
|
-
|
15
|
+
//Failing due to https://redmine.zeuslearning.com/issues/583133
|
16
|
+
describe.skip('Grading view contents', { tags: 'smoke' }, () => {
|
16
17
|
abortEarlySetup();
|
17
18
|
before(() => {
|
18
19
|
brainingCampManipulativePage.steps.navigateToCreateQuestion('brainingcamp manipulative');
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
2
|
-
import { multipleSelectionPage } from "../../../pages";
|
2
|
+
import { multipleSelectionPage, audioPlayerPage } from "../../../pages";
|
3
3
|
import constants from "../../../fixtures/constants";
|
4
4
|
import utilities from "../../../support/helpers/utilities";
|
5
5
|
const css = Cypress.env('css');
|
@@ -62,8 +62,8 @@ describe('Audio player: Edit tab', () => {
|
|
62
62
|
it('\'Source URL\' label and input field should be displayed. By default, the source url input field should be empty', () => {
|
63
63
|
utilities.verifyInnerText(multipleSelectionPage.sourceUrlLabel(), 'Source URL');
|
64
64
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlLabel(), 'visible');
|
65
|
-
utilities.verifyElementVisibilityState(
|
66
|
-
utilities.verifyInnerText(
|
65
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlInputField(), 'visible');
|
66
|
+
utilities.verifyInnerText(audioPlayerPage.sourceUrlInputField(), '');
|
67
67
|
});
|
68
68
|
|
69
69
|
it('CSS of \'Add audio URL\' Section', { tags: 'css' }, () => {
|
@@ -72,7 +72,7 @@ describe('Audio player: Edit tab', () => {
|
|
72
72
|
'font-size': '12px',
|
73
73
|
'font-weight': '400'
|
74
74
|
});
|
75
|
-
utilities.verifyCSS(
|
75
|
+
utilities.verifyCSS(audioPlayerPage.sourceUrlInputField(), {
|
76
76
|
'color': 'rgba(0, 0, 0, 0.87)',
|
77
77
|
'font-size': '12px',
|
78
78
|
'font-weight': '400'
|
@@ -80,7 +80,7 @@ describe('Audio player: Edit tab', () => {
|
|
80
80
|
});
|
81
81
|
|
82
82
|
it('When user focuses in and out of the \'Source URL\' input field, \'Error: Source URL is required.\' error message should be displayed below \'Source URL\' input field.', () => {
|
83
|
-
|
83
|
+
audioPlayerPage.steps.focusInAndFocusOutOfSourceURLInputField();
|
84
84
|
utilities.verifyInnerText(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'Error: Source URL is required.');
|
85
85
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'visible');
|
86
86
|
});
|
@@ -88,13 +88,13 @@ describe('Audio player: Edit tab', () => {
|
|
88
88
|
multipleSelectionPage.tests.verifyErrorMessageCSSAndA11y();
|
89
89
|
|
90
90
|
it('When user adds a MP3 file in \'Source URL\' input field, \'Error: Source URL is required.\' validation message should disappear', () => {
|
91
|
-
|
91
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.sampleMp3Link);
|
92
92
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'hidden');
|
93
93
|
});
|
94
94
|
|
95
95
|
it('When user adds invalid file format URL in \'Source URL\' input field, \'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.\' validation message should be displayed', () => {
|
96
|
-
|
97
|
-
|
96
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
97
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.foxImageLink);
|
98
98
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'visible');
|
99
99
|
utilities.verifyInnerText(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.');
|
100
100
|
});
|
@@ -102,14 +102,14 @@ describe('Audio player: Edit tab', () => {
|
|
102
102
|
multipleSelectionPage.tests.verifyErrorMessageCSSAndA11y();
|
103
103
|
|
104
104
|
it('When user adds valid file URL in \'Source URL\' input field, \'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.\' validation message should disappear', () => {
|
105
|
-
|
106
|
-
|
105
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
106
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.sampleMp3Link);
|
107
107
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'hidden');
|
108
108
|
});
|
109
109
|
|
110
110
|
it('When user adds invalid text in \'Source URL\' input field, \'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.\' validation message should be displayed', () => {
|
111
|
-
|
112
|
-
|
111
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
112
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField('Invalid text');
|
113
113
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'visible');
|
114
114
|
utilities.verifyInnerText(multipleSelectionPage.sourceUrlInputFieldErrorMessage(), 'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.');
|
115
115
|
});
|
@@ -132,7 +132,7 @@ describe('Audio player: Edit tab', () => {
|
|
132
132
|
|
133
133
|
it('\'Source URL\' label and input field should not be displayed', () => {
|
134
134
|
utilities.verifyElementVisibilityState(multipleSelectionPage.sourceUrlLabel(), 'notExist');
|
135
|
-
utilities.verifyElementVisibilityState(
|
135
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlInputField(), 'notExist');
|
136
136
|
});
|
137
137
|
|
138
138
|
it('\'Upload\' label should be displayed', () => {
|
@@ -146,8 +146,8 @@ describe('Audio player: Edit tab', () => {
|
|
146
146
|
});
|
147
147
|
|
148
148
|
it('\'Choose File\' button should be displayed', () => {
|
149
|
-
utilities.verifyInnerText(multipleSelectionPage.
|
150
|
-
utilities.verifyElementVisibilityState(multipleSelectionPage.
|
149
|
+
utilities.verifyInnerText(multipleSelectionPage.audioPlayerChooseFileButton(), 'Choose File');
|
150
|
+
utilities.verifyElementVisibilityState(multipleSelectionPage.audioPlayerChooseFileButton(), 'visible');
|
151
151
|
});
|
152
152
|
|
153
153
|
it('By default \'No file chosen\' text should be displayed below the \'File name\' label.', () => {
|
@@ -171,7 +171,7 @@ describe('Audio player: Edit tab', () => {
|
|
171
171
|
'font-size': '12px',
|
172
172
|
'font-weight': '400'
|
173
173
|
});
|
174
|
-
utilities.verifyCSS(multipleSelectionPage.
|
174
|
+
utilities.verifyCSS(multipleSelectionPage.audioPlayerChooseFileButton(), {
|
175
175
|
'background-color': 'rgb(248, 248, 248)',
|
176
176
|
'border': '1px solid rgb(188, 188, 188)',
|
177
177
|
'color': 'rgb(72, 72, 72)',
|
@@ -186,10 +186,7 @@ describe('Audio player: Edit tab', () => {
|
|
186
186
|
|
187
187
|
it('When the user adds the audio file and file upload is inprogress, file name and progress bar should be displayed below \'File name\' label. Progress bar should disappear once file is uploaded', () => {
|
188
188
|
multipleSelectionPage.steps.uploadFile('sample.mp3');
|
189
|
-
utilities.verifyElementVisibilityState(multipleSelectionPage.fileUploadProgressBar(), 'visible');
|
190
189
|
utilities.verifyInnerText(multipleSelectionPage.uploadedFileNameLabel(), 'sample.mp3');
|
191
|
-
utilities.verifyElementVisibilityState(multipleSelectionPage.uploadedFileNameLabel(), 'visible');
|
192
|
-
utilities.verifyElementVisibilityState(multipleSelectionPage.fileUploadProgressBar(), 'hidden');
|
193
190
|
});
|
194
191
|
|
195
192
|
it('CSS of progress bar and file name when file upload is in progress', { tags: 'css' }, () => {
|
@@ -211,7 +208,7 @@ describe('Audio player: Edit tab', () => {
|
|
211
208
|
});
|
212
209
|
|
213
210
|
it('When the user uploads a file that is not supported, following error message should be displayed: \'Error: The file type is not supported. Please upload a file with the following supported formats: MP3, WAV, AAC.\'', () => {
|
214
|
-
multipleSelectionPage.steps.
|
211
|
+
multipleSelectionPage.steps.uploadOnlyFile('sample.mp4');
|
215
212
|
utilities.verifyElementVisibilityState(multipleSelectionPage.uploadFileSectionErrorMessage(), 'visible');
|
216
213
|
utilities.verifyInnerText(multipleSelectionPage.uploadFileSectionErrorMessage(), 'Error: The file type is not supported. Please upload a file with the following supported formats: MP3, WAV, AAC.');
|
217
214
|
});
|
@@ -1,6 +1,5 @@
|
|
1
1
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
2
|
-
import { multipleSelectionPage } from "../../../pages";
|
3
|
-
import constants from "../../../fixtures/constants";
|
2
|
+
import { multipleSelectionPage, audioPlayerPage } from "../../../pages";
|
4
3
|
import utilities from "../../../support/helpers/utilities";
|
5
4
|
const css = Cypress.env('css');
|
6
5
|
|
@@ -24,78 +23,78 @@ describe('Audio player: Edit tab', () => {
|
|
24
23
|
});
|
25
24
|
|
26
25
|
it('Three toggle buttons \'Standard\', \'Bar\' and \'Compact\' should be displayed and \'Bar\' toggle button should be displayed', () => {
|
27
|
-
utilities.verifyInnerText(
|
28
|
-
utilities.verifyElementVisibilityState(
|
29
|
-
utilities.verifyInnerText(
|
30
|
-
utilities.verifyElementVisibilityState(
|
31
|
-
utilities.verifyInnerText(
|
32
|
-
utilities.verifyElementVisibilityState(
|
33
|
-
|
34
|
-
|
35
|
-
|
26
|
+
utilities.verifyInnerText(audioPlayerPage.standardStyleToggleButtonLabel(), 'Standard');
|
27
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.standardStyleToggleButton(), 'visible');
|
28
|
+
utilities.verifyInnerText(audioPlayerPage.barStyleToggleButtonLabel(), 'Bar');
|
29
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.barStyleToggleButton(), 'visible');
|
30
|
+
utilities.verifyInnerText(audioPlayerPage.compactStyleToggleButtonLabel(), 'Compact');
|
31
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.compactStyleToggleButton(), 'visible');
|
32
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Standard');
|
33
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsSelected('Bar');
|
34
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Compact');
|
36
35
|
});
|
37
36
|
|
38
37
|
it('User should be able to select \'Standard\' toggle button', () => {
|
39
|
-
|
40
|
-
|
41
|
-
|
38
|
+
audioPlayerPage.steps.selectAudioPlayerStyleToggleButton('Standard');
|
39
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Bar');
|
40
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Compact');
|
42
41
|
});
|
43
42
|
|
44
43
|
it('User should be able to select \'Bar\' toggle button', () => {
|
45
|
-
|
46
|
-
|
47
|
-
|
44
|
+
audioPlayerPage.steps.selectAudioPlayerStyleToggleButton('Bar');
|
45
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Standard');
|
46
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Compact');
|
48
47
|
});
|
49
48
|
|
50
49
|
it('User should be able to select \'Compact\' toggle button', () => {
|
51
|
-
|
52
|
-
|
53
|
-
|
50
|
+
audioPlayerPage.steps.selectAudioPlayerStyleToggleButton('Compact');
|
51
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Standard');
|
52
|
+
audioPlayerPage.steps.verifyAudioPlayerStyleToggleButtonIsNotSelected('Bar');
|
54
53
|
});
|
55
54
|
|
56
55
|
it('When user has selected \'Compact\' toggle button, then \'Compact player options\' label and options - \'Default\', \'Text\', \'Image\' and \'Icon\' should be displayed and default should be selected by default', () => {
|
57
56
|
utilities.verifyInnerText(multipleSelectionPage.compactPlayerOptionsLabel(), 'Compact player options');
|
58
57
|
utilities.verifyElementVisibilityState(multipleSelectionPage.compactPlayerOptionsLabel(), 'visible');
|
59
|
-
utilities.verifyInnerText(
|
60
|
-
utilities.verifyElementVisibilityState(
|
61
|
-
utilities.verifyInnerText(
|
62
|
-
utilities.verifyElementVisibilityState(
|
63
|
-
utilities.verifyInnerText(
|
64
|
-
utilities.verifyElementVisibilityState(
|
65
|
-
utilities.verifyInnerText(
|
66
|
-
utilities.verifyElementVisibilityState(
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
58
|
+
utilities.verifyInnerText(audioPlayerPage.defaultPlayerOptionButton(), 'Default');
|
59
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.defaultPlayerOptionButton(), 'visible');
|
60
|
+
utilities.verifyInnerText(audioPlayerPage.textPlayerOptionButton(), 'Text');
|
61
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.textPlayerOptionButton(), 'visible');
|
62
|
+
utilities.verifyInnerText(audioPlayerPage.imagePlayerOptionButton(), 'Image');
|
63
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.imagePlayerOptionButton(), 'visible');
|
64
|
+
utilities.verifyInnerText(audioPlayerPage.iconPlayerOptionButton(), 'Icon');
|
65
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.iconPlayerOptionButton(), 'visible');
|
66
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsSelected('Default');
|
67
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Text');
|
68
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Image');
|
69
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Icon');
|
71
70
|
});
|
72
71
|
|
73
72
|
it('User should be able to select \'Default\' toggle button', () => {
|
74
|
-
|
75
|
-
|
76
|
-
|
77
|
-
|
73
|
+
audioPlayerPage.steps.selectCompactPlayerOptionButton('Default');
|
74
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Text');
|
75
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Image');
|
76
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Icon');
|
78
77
|
});
|
79
78
|
|
80
79
|
it('User should be able to select \'Text\' toggle button', () => {
|
81
|
-
|
82
|
-
|
83
|
-
|
84
|
-
|
80
|
+
audioPlayerPage.steps.selectCompactPlayerOptionButton('Text');
|
81
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Default');
|
82
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Image');
|
83
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Icon');
|
85
84
|
});
|
86
85
|
|
87
86
|
it('User should be able to select \'Image\' toggle button', () => {
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
87
|
+
audioPlayerPage.steps.selectCompactPlayerOptionButton('Image');
|
88
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Default');
|
89
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Text');
|
90
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Icon');
|
92
91
|
});
|
93
92
|
|
94
93
|
it('User should be able to select \'Icon\' toggle button', () => {
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
94
|
+
audioPlayerPage.steps.selectCompactPlayerOptionButton('Icon');
|
95
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Default');
|
96
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Text');
|
97
|
+
audioPlayerPage.steps.verifyCompactPlayerOptionButtonIsNotSelected('Image');
|
99
98
|
});
|
100
99
|
|
101
100
|
it('CSS of audio player style section', { tags: 'css' }, () => {
|
@@ -104,13 +103,13 @@ describe('Audio player: Edit tab', () => {
|
|
104
103
|
'font-size': '12px',
|
105
104
|
'font-weight': '400'
|
106
105
|
});
|
107
|
-
utilities.verifyCSS(
|
106
|
+
utilities.verifyCSS(audioPlayerPage.compactStyleToggleButton(), {
|
108
107
|
'color': 'rgba(0, 0, 0, 0.38)',
|
109
108
|
'background-color': 'rgb(72, 72, 72)',
|
110
109
|
'font-size': '14px',
|
111
110
|
'font-weight': '500'
|
112
111
|
});
|
113
|
-
utilities.verifyCSS(
|
112
|
+
utilities.verifyCSS(audioPlayerPage.standardStyleToggleButton(), {
|
114
113
|
'color': 'rgba(0, 0, 0, 0.38)',
|
115
114
|
'background-color': 'rgba(0, 0, 0, 0)',
|
116
115
|
'font-size': '14px',
|
@@ -121,20 +120,20 @@ describe('Audio player: Edit tab', () => {
|
|
121
120
|
'font-size': '12px',
|
122
121
|
'font-weight': '400'
|
123
122
|
});
|
124
|
-
utilities.verifyCSS(
|
123
|
+
utilities.verifyCSS(audioPlayerPage.iconPlayerOptionButton(), {
|
125
124
|
'background-color': 'rgba(0, 0, 0, 0)',
|
126
125
|
'border': '2px solid rgb(72, 72, 72)'
|
127
126
|
});
|
128
|
-
utilities.verifyCSS(
|
127
|
+
utilities.verifyCSS(audioPlayerPage.iconPlayerOptionButton().find('.ngie-toggle-button-label'), {
|
129
128
|
'color': 'rgb(72, 72, 72)',
|
130
129
|
'font-size': '12px',
|
131
130
|
'font-weight': '400'
|
132
131
|
});
|
133
|
-
utilities.verifyCSS(
|
132
|
+
utilities.verifyCSS(audioPlayerPage.defaultPlayerOptionButton(), {
|
134
133
|
'background-color': 'rgba(0, 0, 0, 0)',
|
135
134
|
'border': '1px solid rgb(188, 188, 188)'
|
136
135
|
});
|
137
|
-
utilities.verifyCSS(
|
136
|
+
utilities.verifyCSS(audioPlayerPage.defaultPlayerOptionButton().find('.ngie-toggle-button-label'), {
|
138
137
|
'color': 'rgb(72, 72, 72)',
|
139
138
|
'font-size': '12px',
|
140
139
|
'font-weight': '400'
|
@@ -1,6 +1,5 @@
|
|
1
1
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
2
2
|
import { multipleSelectionPage } from "../../../pages";
|
3
|
-
import constants from "../../../fixtures/constants";
|
4
3
|
import utilities from "../../../support/helpers/utilities";
|
5
4
|
const css = Cypress.env('css');
|
6
5
|
const customizeUIControlButtons = [multipleSelectionPage.customizeControlPauseButton, multipleSelectionPage.customizeControlSeekButton, multipleSelectionPage.customizeControlPlayBackSpeedButton, multipleSelectionPage.customizeControlAddPinButton, multipleSelectionPage.customizeControlForwardBackwardButton];
|