itemengine-cypress-automation 1.0.51 → 1.0.63
Sign up to get free protection for your applications and to get access to all the features.
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerEditTab.js +342 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerEditTabAddFeatureRadioButton.js +218 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerEditTabTitleDescriptionAndTranscript.js +187 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerHeaderSection.js +73 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerPreviewTab.js +302 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerPreviewTabPlaybackPlayer.js +245 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerPreviewTabSupportedFileTypes.js +78 -0
- package/cypress/e2e/ILC/AudioPlayer/audioPlayerPreviewTabTitleDescriptionAndTranscript.js +248 -0
- package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsAllOrNothingAlternatePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardAllOrNothingAlternatePointsGreaterThanCorrectPoints.js +1 -1
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAdditionalSettingsAnswerNumeration.js +206 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAdditionalSettingsBasic.js +222 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAdditionalSettingsResponseAccordions.js +366 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAllOrNothingWithAlternateAnswer.js +624 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPartialDifferentWeightsWithAlternateAnswer.js +865 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPartialEqualWeightsWithAlternateAnswer.js +763 -0
- package/cypress/e2e/ILC/FillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownSupportedFileTypes.js +86 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/allOrNothingAlternatePointsMoreThanCorrectPoints.js +213 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/allOrNothingCorrectPointsEqualToAlternatePoints.js +215 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/allOrNothingCorrectPointsMoreThanAlternatePoints.js +215 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/allOrNothingScoring.js +187 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/manualAndNonScored.js +162 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialDifferentWeightsAlternatePointsMoreThanCorrectPoints.js +316 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialDifferentWeightsCorrectEqualToAlternatePoints.js +385 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialDifferentWeightsCorrectPointsMoreThanAlternatePoints.js +316 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialDifferentWeightsScoring.js +245 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialEqualWeightsAlternatePointsMoreThanCorrectPoints.js +250 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialEqualWeightsCorrectPointEqualToAlternatePoints.js +266 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialEqualWeightsCorrectPointsMoreThanAlternatePoints.js +250 -0
- package/cypress/e2e/ILC/Highlight/HighlightScoring/partialEqualWeightsScoring.js +226 -0
- package/cypress/e2e/ILC/Highlight/highlightAdditionalSettingsBasic.js +221 -0
- package/cypress/e2e/ILC/Highlight/highlightAdditionalSettingsMaximumNumberOfAnswers.js +137 -0
- package/cypress/e2e/ILC/Highlight/highlightBasicScoringForTextSelectionTypes.js +457 -0
- package/cypress/e2e/ILC/Highlight/highlightColorLibraryFlyout.js +143 -0
- package/cypress/e2e/ILC/Highlight/highlightEditTabScoringSection.js +361 -0
- package/cypress/e2e/ILC/Highlight/highlightHeaderSection.js +91 -0
- package/cypress/e2e/ILC/Highlight/highlightQuestionInstructionsAndQuestion.js +178 -0
- package/cypress/e2e/ILC/Highlight/highlightScoringSectionBasic.js +21 -0
- package/cypress/e2e/ILC/Highlight/highlightSetCorrectAnswerSection.js +204 -0
- package/cypress/e2e/ILC/Highlight/highlightTextSelectionDropdownAndHighlightOptionsSection.js +175 -0
- package/cypress/e2e/ILC/Highlight/highlightTextSelectionTypeInPreviewTab.js +237 -0
- package/cypress/e2e/ILC/Highlight/highlightTextSelectionTypeInSetCorrectAnswerSection.js +341 -0
- package/cypress/e2e/ILC/Highlight/highlightTextSelectionTypesInHighlightOptionsSection.js +375 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridAdditionalSettingsBasic.js +11 -5
- package/cypress/e2e/ILC/MultipleSelectionGrid/{multipleSelectionGridQuestionStemAdditionalSettings.js → multipleSelectionGridAdditionalSettingsQuestionStem.js} +0 -11
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridAllOrNothingAlternatePointsGreaterThanCorrectPoints.js +263 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridAllOrNothingCorrectPointsEqualToAlternatePoints.js +263 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridAllOrNothingCorrectPointsGreaterThanAlternatePoints.js +261 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialDifferentWeightsAlternatePointsGreaterThanCorrectPoints.js +340 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialDifferentWeightsCorrectPointsEqualToAlternatePoints.js +310 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialDifferentWeightsCorrectPointsGreaterThanAlternatePoints.js +341 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialEqualWeightsAlternatePointsGreaterThanCorrectPoints.js +313 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialEqualWeightsCorrectPointsEqualToAlternatePoints.js +285 -0
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialEqualWeightsCorrectPointsGreaterThanAlternatePoints.js +316 -0
- package/cypress/e2e/ILC/ReadingRuler/readingRulerEditTabBasicsSection.js +185 -0
- package/cypress/e2e/ILC/ReadingRuler/readingRulerHeaderSection.js +55 -0
- package/cypress/e2e/ILC/ReadingRuler/readingRulerPreviewTab.js +257 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridAllOrNothingAlternatePointsGreaterThanCorrectPoints.js +173 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridAllOrNothingCorrectPointsEqualToAlternatePoints.js +179 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridAllOrNothingCorrectPointsGreaterThanAlternatePoints.js +174 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialDifferentWeightsAlternatePointsGreaterThanCorrectPoints.js +247 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialDifferentWeightsCorrectPointsEqualToAlternatePoints.js +219 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialDifferentWeightsCorrectPointsGreaterThanAlternatePoints.js +246 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialEqualWeightsAlternatePointsGreaterThanCorrectPoints.js +225 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialEqualWeightsCorrectPointsEqualToAlternatePoints.js +197 -0
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialEqualWeightsCorrectPointsGreaterThanAlternatePoints.js +226 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponseAdditionalSettings.js +135 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponseAdditionalSettingsBasic.js +88 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponseEditTabBasic.js +78 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponseHeaderSection.js +74 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponsePreviewTab.js +627 -0
- package/cypress/e2e/ILC/VideoResponse/videoResponseScoringSection.js +76 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAddResponseContainer.js +230 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAdditionalSettings.js +247 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownAllOrNothingScoring.js +352 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownConditionalCheckboxes.js +258 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownEditAriaLabelCheckbox.js +134 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownEditTabBasicSection.js +132 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownEditTabScoringSection.js +237 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownHeaderSection.js +113 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownImageProperties.js +156 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownManualAndNonScoredScoring.js +165 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownOptionsForResponse.js +303 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPartialDifferentWeightsScoring.js +372 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPartialEqualWeightsScoring.js +371 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownPreviewTab.js +77 -0
- package/cypress/e2e/ILC/fillInTheGapsOverImageDropdown/fillInTheGapsOverImageDropdownSetCorrectAnswerSection.js +117 -0
- package/cypress/pages/dragAndDropIntoCategoriesAllOrNothingScoring.js +1 -1
- package/package.json +1 -1
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridAllOrNothingWithAlternateAnswer.js +0 -731
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialDifferentWeightsWithAlternateAnswer.js +0 -942
- package/cypress/e2e/ILC/MultipleSelectionGrid/multipleSelectionGridPartialEqualWeightsWithAlternateAnswer.js +0 -864
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridAllOrNothingWithAlternateAnswer.js +0 -472
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialDifferentWeightsWithAlternateAnswer.js +0 -662
- package/cypress/e2e/ILC/SingleSelectionGrid/singleSelectionGridPartialEqualWeightsWIthAlternateAnswer.js +0 -595
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsAllOrNothing.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsAllOrNothingCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsAllOrNothingCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachCell.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachCellAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachCellCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachCellCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachResponse.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachResponseAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachResponseCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsPartialScoreForEachResponseCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenCell.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenCellsAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenCellsCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenCellsCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenResponses.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenResponsesAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenResponsesCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/groupedOptionsTotalScoreDividedBetweenResponsesCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardAllOrNothing.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardAllOrNothingCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardAllOrNothingCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachCell.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachCellAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachCellCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachCellCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachResponse.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachResponseAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachResponseCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardPartialScoreForEachResponseCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenCell.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenCellAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenCellCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenCellCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenResponse.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenResponseAlternatePointsGreaterThanCorrectPoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenResponseCorrectPointsEqualToAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/DragAndDropIntoCategories/{dragAndDropIntoCategoriesScoringFiles → dragAndDropIntoCategoriesScoring}/standardTotalScoreDividedBetweenResponseCorrectPointsGreaterThanAlternatePoints.js +0 -0
- /package/cypress/e2e/ILC/MultipleSelectionGrid/{multipleSelectionGridOptionsAdditionalSettings.js → multipleSelectionAdditionalSettingsGridOptions.js} +0 -0
@@ -0,0 +1,342 @@
|
|
1
|
+
import { audioPlayerPage } from "../../../pages";
|
2
|
+
import utilities from "../../../support/helpers/utilities";
|
3
|
+
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
4
|
+
const css = Cypress.env('css');
|
5
|
+
|
6
|
+
describe('Audio player: Edit tab', () => {
|
7
|
+
before(() => {
|
8
|
+
cy.loginAs('admin');
|
9
|
+
});
|
10
|
+
|
11
|
+
describe('\'Player type\' dropdown section', () => {
|
12
|
+
abortEarlySetup();
|
13
|
+
before(() => {
|
14
|
+
cy.log('Navigating to audio player tool');
|
15
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
16
|
+
});
|
17
|
+
|
18
|
+
it('\'Player type\' label and dropdown should be displayed. By default, \'Bar\' option should be selected in \'Player type\' dropdown and it should be disabled', () => {
|
19
|
+
utilities.verifyInnerText(audioPlayerPage.playerTypeLabel(), 'Player type');
|
20
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.playerTypeLabel(), 'visible');
|
21
|
+
utilities.verifyInnerText(audioPlayerPage.playerTypeDropdown(), 'Bar');
|
22
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.playerTypeDropdown(), 'visible');
|
23
|
+
audioPlayerPage.steps.verifyPlayerTypeDropdownDisabledState();
|
24
|
+
});
|
25
|
+
|
26
|
+
it('CSS of Player type dropdown section', { tags: 'css' }, () => {
|
27
|
+
utilities.verifyCSS(audioPlayerPage.playerTypeLabel(), {
|
28
|
+
'color': css.color.labels,
|
29
|
+
'font-size': css.fontSize.normal,
|
30
|
+
'font-weight': css.fontWeight.semibold
|
31
|
+
});
|
32
|
+
utilities.verifyCSS(audioPlayerPage.playerTypeDropdown(), {
|
33
|
+
'background-color': css.color.defaultBackground,
|
34
|
+
'border': `1px solid ${css.color.defaultDropdownBorder}`,
|
35
|
+
});
|
36
|
+
utilities.verifyCSS(audioPlayerPage.playerTypeDropdown().find('.dropdown-label-text'), {
|
37
|
+
'color': css.color.secondaryBtnDisabled,
|
38
|
+
'font-size': css.fontSize.default,
|
39
|
+
'font-weight': css.fontWeight.regular
|
40
|
+
});
|
41
|
+
audioPlayerPage.playerTypeDropdown()
|
42
|
+
.verifyPseudoClassBeforeProperty('color', css.color.secondaryBtnDisabled);
|
43
|
+
});
|
44
|
+
|
45
|
+
//Note: a11y covered in header file
|
46
|
+
});
|
47
|
+
|
48
|
+
describe('Playback limit section', () => {
|
49
|
+
abortEarlySetup();
|
50
|
+
before(() => {
|
51
|
+
cy.log('Navigating to audio player tool');
|
52
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
53
|
+
});
|
54
|
+
|
55
|
+
it('\'Playback limit\' label and empty input field should be displayed', () => {
|
56
|
+
utilities.verifyInnerText(audioPlayerPage.playbackLimitLabel(), 'Playback limit');
|
57
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.playbackLimitLabel(), 'visible');
|
58
|
+
utilities.verifyInnerText(audioPlayerPage.playbackLimitInputField(), '');
|
59
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.playbackLimitInputField(), 'visible');
|
60
|
+
});
|
61
|
+
|
62
|
+
it('When the user focuses in and out of the \'Playback limit\' input field, no error message should be displayed', () => {
|
63
|
+
audioPlayerPage.steps.focusInAndFocusOutOfPlaybackLimitInputField()
|
64
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'hidden');
|
65
|
+
})
|
66
|
+
|
67
|
+
it('CSS of Playback limit section', { tags: 'css' }, () => {
|
68
|
+
utilities.verifyCSS(audioPlayerPage.playbackLimitLabel(), {
|
69
|
+
'color': css.color.labels,
|
70
|
+
'font-size': css.fontSize.normal,
|
71
|
+
'font-weight': css.fontWeight.semibold
|
72
|
+
});
|
73
|
+
utilities.verifyCSS(audioPlayerPage.playbackLimitInputField(), {
|
74
|
+
'color': css.color.text,
|
75
|
+
'font-size': css.fontSize.default,
|
76
|
+
'font-weight': css.fontWeight.regular
|
77
|
+
});
|
78
|
+
});
|
79
|
+
|
80
|
+
//Note: a11y covered in header file
|
81
|
+
//https://redmine.zeuslearning.com/issues/542861
|
82
|
+
it('When user adds decimal values or alphanumeric values then only numeric values should be displayed in the \'Playback limit\' input field', () => {
|
83
|
+
audioPlayerPage.steps.setPlaybackLimit('.10.0');
|
84
|
+
audioPlayerPage.steps.verifyPlaybackLimitInputFieldValue('100');
|
85
|
+
audioPlayerPage.steps.setPlaybackLimit('!@#ab5cd8e4');
|
86
|
+
audioPlayerPage.steps.verifyPlaybackLimitInputFieldValue('584');
|
87
|
+
});
|
88
|
+
});
|
89
|
+
|
90
|
+
describe('\'Customize UI controls for playback\' accordion', () => {
|
91
|
+
abortEarlySetup();
|
92
|
+
before(() => {
|
93
|
+
cy.log('Navigating to audio player tool');
|
94
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
95
|
+
});
|
96
|
+
|
97
|
+
it('\'Customize UI controls for playback\' label should be displayed along with chevron. \'Customize UI controls for playback\' accordion should be displayed in collapsed state by default.', () => {
|
98
|
+
utilities.verifyInnerText(audioPlayerPage.customizeUIControlAccordion(), 'Customize UI controls for playback');
|
99
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.customizeUIControlAccordion(), 'visible');
|
100
|
+
audioPlayerPage.steps.verifyCustomizeUIControlAccordionChevronIcon();
|
101
|
+
audioPlayerPage.steps.verifyCustomizeUIControlAccordionCollapsedState();
|
102
|
+
});
|
103
|
+
|
104
|
+
it('User should be able to expand \'Customize UI controls for playback\' accordion and Play, Pause and Seek option should be displayed in \'Customize UI controls for playback\' accordion. By default all options should be selected', () => {
|
105
|
+
audioPlayerPage.steps.clickOnCustomizeUIControlAccordion();
|
106
|
+
audioPlayerPage.steps.verifyCustomizeUIControlAccordionExpandedState();
|
107
|
+
utilities.verifyInnerText(audioPlayerPage.customizeUIControlAccordion(), 'Customize UI controls for playback');
|
108
|
+
utilities.verifyInnerText(audioPlayerPage.customizeControlPlayButton(), 'Play');
|
109
|
+
utilities.verifyInnerText(audioPlayerPage.customizeControlPauseButton(), 'Pause');
|
110
|
+
utilities.verifyInnerText(audioPlayerPage.customizeControlSeekButton(), 'Seek');
|
111
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.customizeControlPlayButton(), 'visible');
|
112
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.customizeControlPauseButton(), 'visible');
|
113
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.customizeControlSeekButton(), 'visible');
|
114
|
+
audioPlayerPage.steps.verifyCustomizeControlPlayButtonSelectedState();
|
115
|
+
audioPlayerPage.steps.verifyCustomizeControlPauseButtonSelectedState();
|
116
|
+
audioPlayerPage.steps.verifyCustomizeControlSeekButtonSelectedState();
|
117
|
+
});
|
118
|
+
|
119
|
+
it('CSS of \'Customize UI controls for playback\' accordion', { tags: 'css' }, () => {
|
120
|
+
utilities.verifyCSS(audioPlayerPage.customizeUIControlAccordion().find('.accordion_label'), {
|
121
|
+
'color': css.color.activeButtons,
|
122
|
+
'font-size': css.fontSize.default,
|
123
|
+
'font-weight': css.fontWeight.bold
|
124
|
+
});
|
125
|
+
const optionButtons = [audioPlayerPage.customizeControlPlayButton(), audioPlayerPage.customizeControlPauseButton(), audioPlayerPage.customizeControlSeekButton()];
|
126
|
+
optionButtons.forEach(button => {
|
127
|
+
utilities.verifyCSS(button, {
|
128
|
+
'background-color': css.color.activeButtons,
|
129
|
+
'border': `1px solid ${css.color.activeButtons}`
|
130
|
+
});
|
131
|
+
});
|
132
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlPlayButton().find('.ngie-toggle-button-icon svg'), {
|
133
|
+
'fill': css.color.secondaryBtnBg
|
134
|
+
});
|
135
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlPauseButton().find('.ngie-toggle-button-icon svg'), {
|
136
|
+
'fill': css.color.secondaryBtnBg
|
137
|
+
});
|
138
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlSeekButton().find('.ngie-toggle-button-icon svg'), {
|
139
|
+
'fill': css.color.secondaryBtnBg
|
140
|
+
});
|
141
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlButtonLabel(), {
|
142
|
+
'color': css.color.whiteText,
|
143
|
+
'font-size': css.fontSize.default,
|
144
|
+
'font-weight': css.fontWeight.regular
|
145
|
+
});
|
146
|
+
utilities.verifyCSS(audioPlayerPage.selectedButtonIcon().find('[data-name="Icon feather-check"]'), {
|
147
|
+
'fill': css.color.activeButtons
|
148
|
+
});
|
149
|
+
});
|
150
|
+
|
151
|
+
it('Accessibility of \'Customize UI controls for playback\' in expanded state', { tags: 'a11y' }, () => {
|
152
|
+
cy.checkAccessibility(audioPlayerPage.addAudioFileRadioButton().parents('.audio-player-resource'));
|
153
|
+
});
|
154
|
+
|
155
|
+
it('User should be able to deselect all options from \'Customize UI controls for playback\' accordion', () => {
|
156
|
+
audioPlayerPage.steps.clickOnCustomizeControlPlayButton();
|
157
|
+
audioPlayerPage.steps.clickOnCustomizeControlPauseButton();
|
158
|
+
audioPlayerPage.steps.clickOnCustomizeControlSeekButton();
|
159
|
+
audioPlayerPage.steps.verifyCustomizeControlPlayButtonDeselectedState();
|
160
|
+
audioPlayerPage.steps.verifyCustomizeControlPauseButtonDeselectedState();
|
161
|
+
audioPlayerPage.steps.verifyCustomizeControlSeekButtonDeselectedState();
|
162
|
+
});
|
163
|
+
|
164
|
+
it('CSS of deselected options in \'Customize UI controls for playback\' accordion', { tags: 'css' }, () => {
|
165
|
+
const optionButtons = [audioPlayerPage.customizeControlPlayButton(), audioPlayerPage.customizeControlPauseButton(), audioPlayerPage.customizeControlSeekButton()];
|
166
|
+
optionButtons.forEach(button => {
|
167
|
+
utilities.verifyCSS(button, {
|
168
|
+
'background-color': css.color.defaultBackground,
|
169
|
+
'border': `1px solid ${css.color.defaultDropdownBorder}`
|
170
|
+
});
|
171
|
+
});
|
172
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlPlayButton().find('.ngie-toggle-button-icon svg'), {
|
173
|
+
'fill': css.color.secondaryBtn
|
174
|
+
});
|
175
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlPauseButton().find('.ngie-toggle-button-icon svg'), {
|
176
|
+
'fill': css.color.secondaryBtn
|
177
|
+
});
|
178
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlSeekButton().find('.ngie-toggle-button-icon svg'), {
|
179
|
+
'fill': css.color.secondaryBtn
|
180
|
+
});
|
181
|
+
utilities.verifyCSS(audioPlayerPage.customizeControlButtonLabel(), {
|
182
|
+
'color': css.color.secondaryBtn,
|
183
|
+
'font-size': css.fontSize.default,
|
184
|
+
'font-weight': css.fontWeight.regular
|
185
|
+
});
|
186
|
+
});
|
187
|
+
|
188
|
+
it('Accessibility of deselected options in \'Customize UI controls for playback\' accordion', { tags: 'a11y' }, () => {
|
189
|
+
cy.checkAccessibility(audioPlayerPage.addAudioFileRadioButton().parents('.audio-player-resource'));
|
190
|
+
});
|
191
|
+
|
192
|
+
it('User should be able to collapse \'Customize UI controls for playback\' accordion', () => {
|
193
|
+
audioPlayerPage.steps.clickOnCustomizeUIControlAccordion();
|
194
|
+
audioPlayerPage.steps.verifyCustomizeUIControlAccordionCollapsedState();
|
195
|
+
});
|
196
|
+
});
|
197
|
+
|
198
|
+
describe('\'Advanced player layout settings\' accordion', () => {
|
199
|
+
abortEarlySetup();
|
200
|
+
before(() => {
|
201
|
+
cy.log('Navigating to audio player tool');
|
202
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
203
|
+
});
|
204
|
+
|
205
|
+
it('\'Advanced player layout settings\' label should be displayed along with chevron. \'Advanced player layout settings\' accordion should be displayed in collapsed state by default.', () => {
|
206
|
+
utilities.verifyInnerText(audioPlayerPage.advancedPlayerSettingsAccordion(), 'Advanced player layout settings');
|
207
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.advancedPlayerSettingsAccordion(), 'visible');
|
208
|
+
audioPlayerPage.steps.verifyAdvancedPlayerAccordionChevronIcon();
|
209
|
+
audioPlayerPage.steps.verifyAdvancedPlayerSettingsAccordionCollapsedState();
|
210
|
+
});
|
211
|
+
|
212
|
+
//Failing due to https://redmine.zeuslearning.com/issues/547232
|
213
|
+
it('User should be able to expand \'Advanced player layout settings\' accordion and \'Timer\', \'Progress bar\' and \'Volume control\' option should be displayed in \'Advanced player layout settings\' accordion. By default all options should be selected', () => {
|
214
|
+
audioPlayerPage.steps.clickOnAdvancedPlayerSettingsAccordion();
|
215
|
+
audioPlayerPage.steps.verifyAdvancedPlayerSettingsAccordionExpandedState();
|
216
|
+
utilities.verifyInnerText(audioPlayerPage.advancedPlayerTimerButton(), 'Timer');
|
217
|
+
utilities.verifyInnerText(audioPlayerPage.advancedPlayerProgressBarButton(), 'Progress bar');
|
218
|
+
utilities.verifyInnerText(audioPlayerPage.advancedPlayerVolumeControlButton(), 'Volume control');
|
219
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.advancedPlayerTimerButton(), 'visible');
|
220
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.advancedPlayerProgressBarButton(), 'visible');
|
221
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.advancedPlayerVolumeControlButton(), 'visible');
|
222
|
+
audioPlayerPage.steps.verifyAdvancedPlayerTimerButtonSelectedState();
|
223
|
+
audioPlayerPage.steps.verifyAdvancedPlayerProgressBarButtonSelectedState();
|
224
|
+
audioPlayerPage.steps.verifyAdvancedPlayerVolumeControlButtonSelectedState();
|
225
|
+
});
|
226
|
+
|
227
|
+
it('CSS of \'Advanced player layout settings\' accordion', { tags: 'css' }, () => {
|
228
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerSettingsAccordion().find('.accordion_label'), {
|
229
|
+
'color': css.color.activeButtons,
|
230
|
+
'font-size': css.fontSize.default,
|
231
|
+
'font-weight': css.fontWeight.bold
|
232
|
+
});
|
233
|
+
const optionButtons = [audioPlayerPage.advancedPlayerTimerButton(), audioPlayerPage.advancedPlayerProgressBarButton(), audioPlayerPage.advancedPlayerVolumeControlButton()];
|
234
|
+
optionButtons.forEach(button => {
|
235
|
+
utilities.verifyCSS(button, {
|
236
|
+
'background-color': css.color.activeButtons,
|
237
|
+
'border': `1px solid ${css.color.activeButtons}`
|
238
|
+
});
|
239
|
+
});
|
240
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerTimerButton().find('.ngie-toggle-button-icon svg'), {
|
241
|
+
'fill': css.color.secondaryBtnBg
|
242
|
+
});
|
243
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerProgressBarButton().find('.ngie-toggle-button-icon svg'), {
|
244
|
+
'fill': css.color.secondaryBtnBg
|
245
|
+
});
|
246
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerVolumeControlButton().find('.ngie-toggle-button-icon svg'), {
|
247
|
+
'fill': css.color.secondaryBtnBg
|
248
|
+
});
|
249
|
+
utilities.verifyCSS(audioPlayerPage.selectedButtonIcon().find('[data-name="Icon feather-check"]'), {
|
250
|
+
'fill': css.color.activeButtons
|
251
|
+
});
|
252
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerButtonLabel(), {
|
253
|
+
'color': css.color.whiteText,
|
254
|
+
'font-size': css.fontSize.default,
|
255
|
+
'font-weight': css.fontWeight.regular
|
256
|
+
});
|
257
|
+
});
|
258
|
+
|
259
|
+
it('Accessibility of \'Advanced player layout settings\' in expanded state', { tags: 'a11y' }, () => {
|
260
|
+
cy.checkAccessibility(audioPlayerPage.addUrlRadioButton().parents('.audio-player-resource'));
|
261
|
+
});
|
262
|
+
|
263
|
+
it('User should be able to deselect all options from \'Advanced player layout settings\' accordion', () => {
|
264
|
+
audioPlayerPage.steps.clickOnAdvancedPlayerTimerButton();
|
265
|
+
audioPlayerPage.steps.clickOnAdvancedPlayerProgressBarButton();
|
266
|
+
audioPlayerPage.steps.clickOnAdvancedPlayerVolumeControlButton();
|
267
|
+
audioPlayerPage.steps.verifyAdvancedPlayerTimerButtonDeselectedState();
|
268
|
+
audioPlayerPage.steps.verifyAdvancedPlayerProgressBarButtonDeselectedState();
|
269
|
+
audioPlayerPage.steps.verifyAdvancedPlayerVolumeControlButtonDeselectedState();
|
270
|
+
});
|
271
|
+
|
272
|
+
it('CSS of deselected options in \'Advanced player layout settings\' accordion', { tags: 'css' }, () => {
|
273
|
+
const optionButtons = [audioPlayerPage.advancedPlayerTimerButton(), audioPlayerPage.advancedPlayerProgressBarButton(), audioPlayerPage.advancedPlayerVolumeControlButton()];
|
274
|
+
optionButtons.forEach(button => {
|
275
|
+
utilities.verifyCSS(button, {
|
276
|
+
'background-color': css.color.defaultBackground,
|
277
|
+
'border': `1px solid ${css.color.defaultDropdownBorder}`
|
278
|
+
});
|
279
|
+
});
|
280
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerButtonLabel(), {
|
281
|
+
'color': css.color.secondaryBtn,
|
282
|
+
'font-size': css.fontSize.default,
|
283
|
+
'font-weight': css.fontWeight.regular
|
284
|
+
});
|
285
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerTimerButton().find('.ngie-toggle-button-icon svg'), {
|
286
|
+
'fill': css.color.secondaryBtn
|
287
|
+
});
|
288
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerProgressBarButton().find('.ngie-toggle-button-icon svg'), {
|
289
|
+
'fill': css.color.secondaryBtn
|
290
|
+
});
|
291
|
+
utilities.verifyCSS(audioPlayerPage.advancedPlayerVolumeControlButton().find('.ngie-toggle-button-icon svg'), {
|
292
|
+
'fill': css.color.secondaryBtn
|
293
|
+
});
|
294
|
+
});
|
295
|
+
|
296
|
+
it('Accessibility of deselected options in \'Advanced player layout settings\' accordion', { tags: 'a11y' }, () => {
|
297
|
+
cy.checkAccessibility(audioPlayerPage.addAudioFileRadioButton().parents('.audio-player-resource'));
|
298
|
+
});
|
299
|
+
|
300
|
+
it('User should be able to collapse \'Advanced player layout settings\' accordion', () => {
|
301
|
+
audioPlayerPage.steps.clickOnAdvancedPlayerSettingsAccordion();
|
302
|
+
audioPlayerPage.steps.verifyAdvancedPlayerSettingsAccordionCollapsedState();
|
303
|
+
});
|
304
|
+
});
|
305
|
+
|
306
|
+
describe('\'Allow students to download the audio\' checkbox', () => {
|
307
|
+
abortEarlySetup();
|
308
|
+
before(() => {
|
309
|
+
cy.log('Navigating to audio player tool');
|
310
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
311
|
+
});
|
312
|
+
|
313
|
+
it('\'Allow students to download the audio\' label and checkbox should be displayed. By default the \'Allow students to download the audio\' checkbox should be unchecked.', () => {
|
314
|
+
utilities.verifyInnerText(audioPlayerPage.allowStudentsToDownloadAudioLabel(), 'Allow students to download the audio');
|
315
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.allowStudentsToDownloadAudioLabel(), 'visible');
|
316
|
+
audioPlayerPage.steps.verifyAllowStudentsToDownloadAudioCheckboxNotChecked();
|
317
|
+
});
|
318
|
+
|
319
|
+
it('CSS of \'Allow students to download the audio\' section - unchecked state', { tags: 'css' }, () => {
|
320
|
+
utilities.verifyCSS(audioPlayerPage.allowStudentsToDownloadAudioCheckbox().parent().find('svg'), {
|
321
|
+
'fill': css.color.uncheckedCheckbox
|
322
|
+
});
|
323
|
+
});
|
324
|
+
|
325
|
+
//Note: a11y covered in header file
|
326
|
+
|
327
|
+
it('The user should be able to check the \'Allow students to download the audio\' checkbox', () => {
|
328
|
+
audioPlayerPage.steps.checkUncheckAllowStudentsToDownloadAudioCheckbox();
|
329
|
+
audioPlayerPage.steps.verifyAllowStudentsToDownloadAudioCheckboxChecked();
|
330
|
+
});
|
331
|
+
|
332
|
+
it('CSS of \'Allow students to download the audio\' section - checked state', { tags: 'css' }, () => {
|
333
|
+
utilities.verifyCSS(audioPlayerPage.allowStudentsToDownloadAudioCheckbox().parent('.icon-checkbox-selected').find('.checkbox-icon-border-rect'), {
|
334
|
+
'fill': css.color.activeButtons
|
335
|
+
});
|
336
|
+
});
|
337
|
+
|
338
|
+
it('Accessibility of \'Allow students to download the audio\' section - checked state', { tags: 'a11y' }, () => {
|
339
|
+
cy.checkAccessibility(audioPlayerPage.addUrlRadioButton().parents('.audio-player-resource'));
|
340
|
+
});
|
341
|
+
});
|
342
|
+
});
|
@@ -0,0 +1,218 @@
|
|
1
|
+
import { audioPlayerPage } from "../../../pages";
|
2
|
+
import utilities from "../../../support/helpers/utilities";
|
3
|
+
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
4
|
+
import constants from "../../../fixtures/constants";
|
5
|
+
const css = Cypress.env('css');
|
6
|
+
|
7
|
+
describe('Audio player: Edit tab', () => {
|
8
|
+
before(() => {
|
9
|
+
cy.loginAs('admin');
|
10
|
+
});
|
11
|
+
|
12
|
+
describe('\'Add\' feature radio buttons', () => {
|
13
|
+
abortEarlySetup();
|
14
|
+
before(() => {
|
15
|
+
cy.log('Navigating to audio player tool');
|
16
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
17
|
+
});
|
18
|
+
|
19
|
+
it('\'Add URL\' and \'Add audio file\' radio buttons should be displayed. By default \'Add URL\' button should be selected', () => {
|
20
|
+
utilities.verifyInnerText(audioPlayerPage.addUrlLabel(), 'Add URL');
|
21
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.addUrlLabel(), 'visible');
|
22
|
+
audioPlayerPage.steps.verifyAddUrlCheckedState();
|
23
|
+
utilities.verifyInnerText(audioPlayerPage.addAudioFileLabel(), 'Add audio file');
|
24
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.addAudioFileLabel(), 'visible');
|
25
|
+
audioPlayerPage.steps.verifyAddAudioFileUncheckedState();
|
26
|
+
});
|
27
|
+
|
28
|
+
it('CSS of Add feature radio buttons', { tags: 'css' }, () => {
|
29
|
+
utilities.verifyCSS(audioPlayerPage.addUrlRadioButton().parent().find('svg'), {
|
30
|
+
'fill': css.color.secondaryBtnActive
|
31
|
+
});
|
32
|
+
utilities.verifyCSS(audioPlayerPage.addAudioFileRadioButton().parent().find('svg path'), {
|
33
|
+
'fill': css.color.uncheckedCheckbox
|
34
|
+
});
|
35
|
+
utilities.verifyCSS(audioPlayerPage.addUrlLabel(), {
|
36
|
+
'color': css.color.labelText,
|
37
|
+
'font-size': css.fontSize.normal,
|
38
|
+
'font-weight': css.fontWeight.regular
|
39
|
+
});
|
40
|
+
utilities.verifyCSS(audioPlayerPage.addAudioFileLabel(), {
|
41
|
+
'color': css.color.labelText,
|
42
|
+
'font-size': css.fontSize.normal,
|
43
|
+
'font-weight': css.fontWeight.regular
|
44
|
+
});
|
45
|
+
});
|
46
|
+
|
47
|
+
//Note: a11y covered in header file
|
48
|
+
});
|
49
|
+
|
50
|
+
describe('\'Add URL\' section', () => {
|
51
|
+
abortEarlySetup();
|
52
|
+
before(() => {
|
53
|
+
cy.log('Navigating to audio player tool');
|
54
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
55
|
+
});
|
56
|
+
|
57
|
+
it('\'Source URL\' label and input field should be displayed. By default, the source url input field should be empty', () => {
|
58
|
+
utilities.verifyInnerText(audioPlayerPage.sourceUrlLabel(), 'Source URL');
|
59
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlLabel(), 'visible');
|
60
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlInputField(), 'visible');
|
61
|
+
utilities.verifyInnerText(audioPlayerPage.sourceUrlInputField(), '');
|
62
|
+
});
|
63
|
+
|
64
|
+
it('CSS of \'Add audio URL\' Section', { tags: 'css' }, () => {
|
65
|
+
utilities.verifyCSS(audioPlayerPage.sourceUrlLabel(), {
|
66
|
+
'color': css.color.labels,
|
67
|
+
'font-size': css.fontSize.normal,
|
68
|
+
'font-weight': css.fontWeight.semibold
|
69
|
+
});
|
70
|
+
utilities.verifyCSS(audioPlayerPage.sourceUrlInputField(), {
|
71
|
+
'color': css.color.text,
|
72
|
+
'font-size': css.fontSize.default,
|
73
|
+
'font-weight': css.fontWeight.regular
|
74
|
+
});
|
75
|
+
});
|
76
|
+
|
77
|
+
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.', () => {
|
78
|
+
audioPlayerPage.steps.focusInAndFocusOutOfSourceURLInputField();
|
79
|
+
utilities.verifyInnerText(audioPlayerPage.errorMessage(), 'Error: Source URL is required.');
|
80
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'visible');
|
81
|
+
});
|
82
|
+
|
83
|
+
audioPlayerPage.tests.verifyCSSAnda11yOfErrorMessage();
|
84
|
+
|
85
|
+
//http://redmine.zeuslearning.com/issues/542695
|
86
|
+
it('When user adds a MP3 file in \'Source URL\' input field, \'Error: Source URL is required.\' validation message should disappear', () => {
|
87
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.sampleMp3Link);
|
88
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'hidden');
|
89
|
+
});
|
90
|
+
|
91
|
+
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', () => {
|
92
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
93
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.foxImageLink);
|
94
|
+
utilities.verifyInnerText(audioPlayerPage.errorMessage(), 'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.');
|
95
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'visible');
|
96
|
+
});
|
97
|
+
|
98
|
+
audioPlayerPage.tests.verifyCSSAnda11yOfErrorMessage();
|
99
|
+
|
100
|
+
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', () => {
|
101
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
102
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField(constants.sampleMp3Link);
|
103
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'hidden');
|
104
|
+
});
|
105
|
+
|
106
|
+
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', () => {
|
107
|
+
audioPlayerPage.steps.clearTextInSourceURLInputField();
|
108
|
+
audioPlayerPage.steps.enterTextInSourceURLInputField('Invalid text');
|
109
|
+
utilities.verifyInnerText(audioPlayerPage.errorMessage(), 'Error: The provided URL does not link to a supported audio file. Please enter a URL for a MP3, WAV, AAC file.');
|
110
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'visible');
|
111
|
+
});
|
112
|
+
});
|
113
|
+
|
114
|
+
describe('\'Add audio file\' section', () => {
|
115
|
+
abortEarlySetup();
|
116
|
+
before(() => {
|
117
|
+
cy.log('Navigating to audio player tool');
|
118
|
+
audioPlayerPage.steps.navigateToCreateResource('audio player');
|
119
|
+
});
|
120
|
+
|
121
|
+
it('On selecting \'Add audio file\' radio button, the \'Add URL\' radio button should get unchecked', () => {
|
122
|
+
audioPlayerPage.steps.clickOnAddAudioFileRadioButton();
|
123
|
+
audioPlayerPage.steps.verifyAddAudioFileCheckedState();
|
124
|
+
audioPlayerPage.steps.verifyAddUrlUncheckedState();
|
125
|
+
});
|
126
|
+
|
127
|
+
it('\'Source URL\' label and input field should not be displayed', () => {
|
128
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlLabel(), 'notExist');
|
129
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.sourceUrlInputField(), 'notExist');
|
130
|
+
});
|
131
|
+
|
132
|
+
it('\'Upload\' label should be displayed', () => {
|
133
|
+
utilities.verifyInnerText(audioPlayerPage.uploadLabel(), 'Upload');
|
134
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.uploadLabel(), 'visible');
|
135
|
+
});
|
136
|
+
|
137
|
+
it('\'File name\' label should be displayed', () => {
|
138
|
+
utilities.verifyInnerText(audioPlayerPage.fileNameLabel(), 'File name');
|
139
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.fileNameLabel(), 'visible');
|
140
|
+
});
|
141
|
+
|
142
|
+
it('\'Choose file\' button should be displayed', () => {
|
143
|
+
utilities.verifyInnerText(audioPlayerPage.chooseFileButton(), 'Choose file');
|
144
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.chooseFileButton(), 'visible');
|
145
|
+
});
|
146
|
+
|
147
|
+
it('By default \'No file chosen\' text should be displayed below the \'File name\' label.', () => {
|
148
|
+
utilities.verifyInnerText(audioPlayerPage.noFileChosenLabel(), 'No file chosen');
|
149
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.noFileChosenLabel(), 'visible');
|
150
|
+
});
|
151
|
+
|
152
|
+
it('CSS of \'Add audio file\' section', { tags: 'css' }, () => {
|
153
|
+
utilities.verifyCSS(audioPlayerPage.uploadLabel(), {
|
154
|
+
'color': css.color.labels,
|
155
|
+
'font-size': css.fontSize.normal,
|
156
|
+
'font-weight': css.fontWeight.semibold
|
157
|
+
});
|
158
|
+
utilities.verifyCSS(audioPlayerPage.fileNameLabel(), {
|
159
|
+
'color': css.color.labels,
|
160
|
+
'font-size': css.fontSize.normal,
|
161
|
+
'font-weight': css.fontWeight.semibold
|
162
|
+
});
|
163
|
+
utilities.verifyCSS(audioPlayerPage.noFileChosenLabel(), {
|
164
|
+
'color': css.color.liText,
|
165
|
+
'font-size': css.fontSize.default,
|
166
|
+
'font-weight': css.fontWeight.regular
|
167
|
+
});
|
168
|
+
utilities.verifyCSS(audioPlayerPage.chooseFileButton(), {
|
169
|
+
'background-color': css.color.transparent,
|
170
|
+
'border': `1px solid ${css.color.secondaryBtnBorder}`,
|
171
|
+
'color': css.color.secondaryBtn,
|
172
|
+
'font-size': css.fontSize.default,
|
173
|
+
'font-weight': css.fontWeight.regular
|
174
|
+
});
|
175
|
+
});
|
176
|
+
|
177
|
+
it('Accessibility of \'Add audio file\' section', { tags: 'a11y' }, () => {
|
178
|
+
cy.checkAccessibility(audioPlayerPage.addAudioFileRadioButton().parents('.audio-player-resource'));
|
179
|
+
});
|
180
|
+
|
181
|
+
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', () => {
|
182
|
+
audioPlayerPage.steps.uploadFile('uploads/sample.mp3');
|
183
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.fileUploadProgressBar(), 'visible');
|
184
|
+
utilities.verifyInnerText(audioPlayerPage.uploadedFileNameLabel(), 'sample.mp3');
|
185
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.uploadedFileNameLabel(), 'visible');
|
186
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.fileUploadProgressBar(), 'hidden');
|
187
|
+
});
|
188
|
+
|
189
|
+
it('CSS of progress bar and file name when file upload is in progress', { tags: 'css' }, () => {
|
190
|
+
audioPlayerPage.steps.uploadFile('uploads/sample1.mp3');
|
191
|
+
audioPlayerPage.fileUploadProgressBar()
|
192
|
+
.verifyPseudoClassBeforeProperty('background-color', css.color.fileUploadProgressBarFill);
|
193
|
+
});
|
194
|
+
|
195
|
+
it('Accessibility of progress bar and file name when file upload is in progress', { tags: 'a11y' }, () => {
|
196
|
+
cy.checkAccessibility(audioPlayerPage.addAudioFileRadioButton().parents('.audio-player-resource'));
|
197
|
+
});
|
198
|
+
|
199
|
+
it('When user clicks on \'Choose file\' button again and upload another audio file, previously uploaded audio file should get replaced with new audio file', () => {
|
200
|
+
audioPlayerPage.steps.uploadFile('uploads/sample2.mp3');
|
201
|
+
utilities.verifyInnerText(audioPlayerPage.uploadedFileNameLabel(), 'sample2.mp3');
|
202
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.uploadedFileNameLabel(), 'visible');
|
203
|
+
});
|
204
|
+
|
205
|
+
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.\'', () => {
|
206
|
+
audioPlayerPage.steps.uploadFile('uploads/sample.mp4')
|
207
|
+
utilities.verifyInnerText(audioPlayerPage.errorMessage(), 'Error: The file type is not supported. Please upload a file with the following supported formats: MP3, WAV, AAC.');
|
208
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'visible');
|
209
|
+
});
|
210
|
+
|
211
|
+
audioPlayerPage.tests.verifyCSSAnda11yOfErrorMessage();
|
212
|
+
|
213
|
+
it('When user upload supported format of audio file, error message should disappear', () => {
|
214
|
+
audioPlayerPage.steps.uploadFile('uploads/sample2.mp3');
|
215
|
+
utilities.verifyElementVisibilityState(audioPlayerPage.errorMessage(), 'hidden');
|
216
|
+
});
|
217
|
+
});
|
218
|
+
});
|