itemengine-cypress-automation 1.0.433-IEI-6654-6ef60cd.0 → 1.0.433-thinksphere-cypress-failing-cases-5850582.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.
- package/cypress/e2e/ILC/ThinkSphere/createReviewItem.js +7 -3
- package/cypress/e2e/ILC/ThinkSphere/editThinkSphereQuestion.smoke.js +5 -3
- package/cypress/e2e/ILC/ThinkSphere/gradingViewPlanTabSection.js +4 -0
- package/cypress/e2e/ILC/ThinkSphere/previewTabPlanSection.js +3 -3
- package/cypress/e2e/ILC/ThinkSphere/studentViewSolveSection.js +1 -1
- package/cypress/pages/thinkSpherePage.js +19 -7
- package/package.json +1 -1
@@ -1,3 +1,4 @@
|
|
1
|
+
import uuid from 'react-uuid';
|
1
2
|
import { thinkSpherePage } from "../../../pages";
|
2
3
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
3
4
|
import utilities from "../../../support/helpers/utilities";
|
@@ -26,17 +27,20 @@ const dropDownArray = [
|
|
26
27
|
'Math response',
|
27
28
|
'Graph and chart'
|
28
29
|
]
|
30
|
+
|
31
|
+
const css = Cypress.env('css');
|
32
|
+
const uuidString = uuid();
|
33
|
+
|
29
34
|
describe("Create Review Item", () => {
|
30
35
|
abortEarlySetup();
|
31
36
|
before(() => {
|
32
37
|
cy.loginAs('admin');
|
33
|
-
cy.
|
34
|
-
cy.createThinkSphereItem('~zzz item name');
|
38
|
+
cy.createThinkSphereItem(uuidString);
|
35
39
|
thinkSpherePage.steps.navigateToReviewItemsPage();
|
36
40
|
});
|
37
41
|
|
38
42
|
after(() => {
|
39
|
-
cy.deleteThinkSphereItem(
|
43
|
+
cy.deleteThinkSphereItem(uuidString);
|
40
44
|
});
|
41
45
|
|
42
46
|
it('When the user clicks on the \'Create Question\' button then the user should be navigated to create review question page',() => {
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import uuid from 'react-uuid';
|
1
2
|
import { thinkSpherePage } from '../../../pages/thinkSpherePage';
|
2
3
|
import { browseItemsPage } from "../../../pages/components/browseItemsPage";
|
3
4
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
@@ -59,16 +60,17 @@ const alternateTextForImage = 'Alternative text for image';
|
|
59
60
|
|
60
61
|
const editedFontSize = 'Normal';
|
61
62
|
|
63
|
+
const uuidString = uuid();
|
64
|
+
|
62
65
|
describe('Edit Question and edit item', () => {
|
63
66
|
before(() => {
|
64
67
|
cy.loginAs('admin');
|
65
|
-
cy.
|
66
|
-
cy.createThinkSphereItem('~zzz item name test test test', true);
|
68
|
+
cy.createThinkSphereItem(uuidString, true);
|
67
69
|
thinkSpherePage.steps.visitThinksphereBrowseItemsPage();
|
68
70
|
});
|
69
71
|
|
70
72
|
after(() => {
|
71
|
-
cy.deleteThinkSphereItem(
|
73
|
+
cy.deleteThinkSphereItem(uuidString);
|
72
74
|
});
|
73
75
|
|
74
76
|
describe('Edit question', () => {
|
@@ -18,6 +18,10 @@ describe('Grading view : ThinkSphere Question - Plan Section', () => {
|
|
18
18
|
thinkSpherePage.steps.stepsBeforeGradingView();
|
19
19
|
});
|
20
20
|
|
21
|
+
after(() => {
|
22
|
+
cy.deleteThinkSphereItem(uuidString);
|
23
|
+
});
|
24
|
+
|
21
25
|
describe('\'Question instruction\' section', () => {
|
22
26
|
abortEarlySetup();
|
23
27
|
it('\'Question instruction\' section should be present', () => {
|
@@ -19,7 +19,7 @@ const uuidString = uuid();
|
|
19
19
|
describe('Preview question : ThinkSphere Question - Plan Section - preview tab', () => {
|
20
20
|
before(() => {
|
21
21
|
cy.loginAs('admin');
|
22
|
-
cy.createThinkSphereItem(uuidString);
|
22
|
+
cy.createThinkSphereItem(uuidString, true);
|
23
23
|
cy.visit('/item-engine/thinksphere/browse-items');
|
24
24
|
browseItemsPage.steps.clickOnItemReferenceId(uuidString);
|
25
25
|
thinkSpherePage.steps.clickOnEditQuestionIcon();
|
@@ -40,7 +40,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
40
40
|
utilities.verifyCSS(thinkSpherePage.questionInstructionPreviewTexWrapper(), {
|
41
41
|
'border-radius': '12px',
|
42
42
|
'background-color': css.color.questionInstructionBG,
|
43
|
-
'padding': '10px
|
43
|
+
'padding': '10px 170px 10px 27px',
|
44
44
|
'font-size': css.fontSize.default,
|
45
45
|
'font-weight': css.fontWeight.regular,
|
46
46
|
});
|
@@ -253,7 +253,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
253
253
|
thinkSpherePage.dialogBoxRoot()
|
254
254
|
.within(() => {
|
255
255
|
utilities.verifyElementVisibilityState(thinkSpherePage.dialogBoxTitle(), 'visible');
|
256
|
-
utilities.verifyInnerText(thinkSpherePage.dialogBoxTitle(), '
|
256
|
+
utilities.verifyInnerText(thinkSpherePage.dialogBoxTitle(), 'Create_a_model');
|
257
257
|
utilities.verifyElementVisibilityState(thinkSpherePage.buttonClose(), 'visible');
|
258
258
|
});
|
259
259
|
thinkSpherePage.steps.closeVideoPopup();
|
@@ -17,7 +17,7 @@ describe('Student view : ThinkSphere Question - Solve Section', () => {
|
|
17
17
|
thinkSpherePage.steps.expandCustomizeToolsAndControls();
|
18
18
|
editSectionWhiteBoardToolButtons.forEach((toolName) => {
|
19
19
|
thinkSpherePage.steps.selectOptionFromToolsAndControls(toolName);
|
20
|
-
})
|
20
|
+
})
|
21
21
|
thinkSpherePage.steps.clickOnSaveButton();
|
22
22
|
cy.visit('/item-engine/thinksphere/browse-items');
|
23
23
|
browseItemsPage.steps.clickOnActionButton();
|
@@ -801,7 +801,7 @@ const steps = {
|
|
801
801
|
|
802
802
|
expandChooseStarterDropdown: () => {
|
803
803
|
thinkSpherePage.chooseStarterDropdown()
|
804
|
-
.click();
|
804
|
+
.click({force: true});
|
805
805
|
},
|
806
806
|
|
807
807
|
verifyOptionAlignmentIsSelected: (direction) => {
|
@@ -988,10 +988,9 @@ const steps = {
|
|
988
988
|
},
|
989
989
|
|
990
990
|
verifyCategoryCharactersAndUnSelectedState: (arrayOfSymbolsAriaLabel) => {
|
991
|
-
const unselectedCategoriesStartingIndex = 11; // Starting index for unselected categories
|
992
991
|
thinkSpherePage.categoryCharacters()
|
993
992
|
.then(($symbols) => {
|
994
|
-
for (let index =
|
993
|
+
for (let index = 11; index < arrayOfSymbolsAriaLabel.length - 1; index++) {
|
995
994
|
editCategoryFlyout.categoryCharacters()
|
996
995
|
.eq(index)
|
997
996
|
.should('not.have.class', 'Mui-selected')
|
@@ -1292,8 +1291,7 @@ const steps = {
|
|
1292
1291
|
},
|
1293
1292
|
|
1294
1293
|
verifyNewlyAddedStrategyEditDeleteButtonDisableState: () => {
|
1295
|
-
|
1296
|
-
utilities.getNthElement(thinkSpherePage.strategiesBoxPreviewTab(), newlyAddedStrategyIndex)
|
1294
|
+
utilities.getNthElement(thinkSpherePage.strategiesBoxPreviewTab(), 5)
|
1297
1295
|
.within(() => {
|
1298
1296
|
thinkSpherePage.editStrategyButton()
|
1299
1297
|
.should('have.attr', 'tabindex', '-1')
|
@@ -2581,6 +2579,7 @@ const tests = {
|
|
2581
2579
|
whiteBoardTools.forEach((tool) => {
|
2582
2580
|
it(`When user clicks on "${tool.name}" tool it should display its sub tools`, () => {
|
2583
2581
|
// Click the main tool by data-testid
|
2582
|
+
|
2584
2583
|
cy.get(`[data-testid="${tool.dataTestId}"]`)
|
2585
2584
|
.and('be.visible')
|
2586
2585
|
.first()
|
@@ -2612,8 +2611,10 @@ const tests = {
|
|
2612
2611
|
if(tool.popupContent) {
|
2613
2612
|
// Verify the content inside the popup
|
2614
2613
|
tool.popupContent.forEach((content) => {
|
2615
|
-
cy.get(`[class="${content}"]`).should('exist').and('be.visible');
|
2614
|
+
cy.get(`[class="${content}"]`).scrollIntoView().should('exist').and('be.visible');
|
2616
2615
|
});
|
2616
|
+
thinkSpherePage.steps.clickOnReviewTab();
|
2617
|
+
thinkSpherePage.steps.clickOnSolveTab();
|
2617
2618
|
}
|
2618
2619
|
}
|
2619
2620
|
|
@@ -2653,6 +2654,7 @@ const tests = {
|
|
2653
2654
|
});
|
2654
2655
|
})
|
2655
2656
|
|
2657
|
+
|
2656
2658
|
thinkSpherePage.tests.verifyWhiteBoardSubTools(whiteBoardTools);
|
2657
2659
|
},
|
2658
2660
|
|
@@ -2910,7 +2912,17 @@ const tests = {
|
|
2910
2912
|
cy.wait(6000); // Wait for the playback to start
|
2911
2913
|
thinkSpherePage.steps.clickOnWhiteBoardPlaybackPlayButton();
|
2912
2914
|
cy.wait(1000);
|
2913
|
-
thinkSpherePage.
|
2915
|
+
thinkSpherePage.whiteboardPlaybackTime()
|
2916
|
+
.invoke('text')
|
2917
|
+
.then((text) => {
|
2918
|
+
const currentTime = text.split('/')[0].trim(); // extract current time before "/"
|
2919
|
+
|
2920
|
+
// Assert it matches mm:ss format
|
2921
|
+
expect(currentTime).to.match(/^\d{2}:\d{2}$/);
|
2922
|
+
|
2923
|
+
// Assert it's not 00:00
|
2924
|
+
expect(currentTime).not.to.equal('00:00');
|
2925
|
+
});
|
2914
2926
|
});
|
2915
2927
|
|
2916
2928
|
it('When the user clicks on the Pause button, it should pause the recording', () => {
|