itemengine-cypress-automation 1.0.418-fixesForFlakySmokeFiles22July-f48fab5.0 → 1.0.418
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 -5
- package/cypress/e2e/ILC/ThinkSphere/editTabBasicSection.js +11 -20
- package/cypress/e2e/ILC/ThinkSphere/editThinkSphereQuestion.smoke.js +8 -18
- package/cypress/e2e/ILC/ThinkSphere/equationEditorCreateCustomCategory.smoke.js +4 -4
- package/cypress/e2e/ILC/ThinkSphere/equationEditorEditCategoryFlyOut.js +4 -13
- package/cypress/e2e/ILC/ThinkSphere/gradingViewPlanTabSection.js +4 -0
- package/cypress/e2e/ILC/ThinkSphere/gradingViewReviewTabSection.js +18 -69
- package/cypress/e2e/ILC/ThinkSphere/planPhase.js +10 -9
- package/cypress/e2e/ILC/ThinkSphere/previewTabPlanSection.js +20 -36
- package/cypress/e2e/ILC/ThinkSphere/previewTabReviewSection.js +7 -16
- package/cypress/e2e/ILC/ThinkSphere/solvePhase.js +12 -7
- package/cypress/e2e/ILC/ThinkSphere/studentViewReviewTabSection.js +14 -13
- package/cypress/e2e/ILC/ThinkSphere/studentViewSolveSection.js +0 -1
- package/cypress/pages/thinkSpherePage.js +138 -103
- package/package.json +2 -2
@@ -1,10 +1,10 @@
|
|
1
|
+
import uuid from 'react-uuid';
|
1
2
|
import { thinkSpherePage } from "../../../pages";
|
2
3
|
import { browseItemsPage } from "../../../pages/components/browseItemsPage";
|
3
4
|
import { commonComponents } from "../../../pages/components/commonComponents";
|
4
5
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
5
6
|
import utilities from "../../../support/helpers/utilities";
|
6
7
|
const css = Cypress.env('css');
|
7
|
-
import uuid from 'react-uuid';
|
8
8
|
|
9
9
|
const sentenceStartersTextDefault = [
|
10
10
|
'The strategy I’m going to use is',
|
@@ -14,20 +14,20 @@ const sentenceStartersTextDefault = [
|
|
14
14
|
'If my strategy is not working, I will'
|
15
15
|
];
|
16
16
|
|
17
|
+
const uuidString = uuid();
|
18
|
+
|
17
19
|
describe('Preview question : ThinkSphere Question - Plan Section - preview tab', () => {
|
18
|
-
let randomItemName;
|
19
20
|
before(() => {
|
20
|
-
randomItemName = `~zzz thinksphere item name ${uuid()}`;
|
21
21
|
cy.loginAs('admin');
|
22
|
-
cy.createThinkSphereItem(
|
22
|
+
cy.createThinkSphereItem(uuidString);
|
23
23
|
cy.visit('/item-engine/thinksphere/browse-items');
|
24
|
-
browseItemsPage.steps.clickOnItemReferenceId(
|
24
|
+
browseItemsPage.steps.clickOnItemReferenceId(uuidString);
|
25
25
|
thinkSpherePage.steps.clickOnEditQuestionIcon();
|
26
26
|
thinkSpherePage.steps.switchToPreviewTab();
|
27
27
|
});
|
28
28
|
|
29
29
|
after(() => {
|
30
|
-
cy.deleteThinkSphereItem(
|
30
|
+
cy.deleteThinkSphereItem(uuidString);
|
31
31
|
});
|
32
32
|
|
33
33
|
describe('\'Question instruction\' section', () => {
|
@@ -92,7 +92,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
92
92
|
'font-size': css.fontSize.normal,
|
93
93
|
'font-weight': css.fontWeight.semibold,
|
94
94
|
'border': `1px solid ${css.color.secondaryBtnBorder}`,
|
95
|
-
'color': css.color.primaryBtnBorder,
|
95
|
+
'color': css.color.primaryBtnBorder,
|
96
96
|
});
|
97
97
|
});
|
98
98
|
|
@@ -151,7 +151,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
151
151
|
expect(previewTabCount).to.equal(editTabCount);
|
152
152
|
});
|
153
153
|
});
|
154
|
-
|
154
|
+
|
155
155
|
it('CSS of strategies list', { tags: 'css' }, () => {
|
156
156
|
utilities.verifyCSS(utilities.getNthElement(thinkSpherePage.strategiesPreviewListLI(), 0), {
|
157
157
|
'padding': '8px 16px 8px 24px',
|
@@ -161,7 +161,6 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
161
161
|
});
|
162
162
|
utilities.verifyCSS(utilities.getNthElement(thinkSpherePage.strategyTextWrapper(), 0), {
|
163
163
|
'color': css.color.primaryBtnBorder,
|
164
|
-
'margin-right': '40px',
|
165
164
|
'font-size': '18px',
|
166
165
|
'font-weight': '600',
|
167
166
|
});
|
@@ -200,7 +199,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
200
199
|
.then((count) => {
|
201
200
|
countBeforeOpeningPopup = count;
|
202
201
|
cy.log('Count before opening popup:', countBeforeOpeningPopup);
|
203
|
-
|
202
|
+
});
|
204
203
|
thinkSpherePage.addNewStrategyButton().click();
|
205
204
|
thinkSpherePage.addStrategyPopupCancelButton().click();
|
206
205
|
cy.get(thinkSpherePage.strategiesBoxPreviewTab())
|
@@ -209,7 +208,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
209
208
|
countAfterClosingPopup = count;
|
210
209
|
cy.log('Count after closing popup:', countAfterClosingPopup);
|
211
210
|
expect(countAfterClosingPopup).to.equal(countBeforeOpeningPopup);
|
212
|
-
|
211
|
+
});
|
213
212
|
});
|
214
213
|
|
215
214
|
it('When user adds a new strategy, the popup should close when save button is clicked and the number of strategies should increase by 1 compared to that before opening the popup', () => {
|
@@ -219,7 +218,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
219
218
|
.then((count) => {
|
220
219
|
countBeforeOpeningPopup = count;
|
221
220
|
cy.log('Count before opening popup:', countBeforeOpeningPopup);
|
222
|
-
|
221
|
+
});
|
223
222
|
thinkSpherePage.addNewStrategyButton().click();
|
224
223
|
thinkSpherePage.strategyNameInputField().type('Test Strategy');
|
225
224
|
thinkSpherePage.addStrategyPopupSaveButton().click();
|
@@ -229,7 +228,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
229
228
|
countAfterClosingPopup = count;
|
230
229
|
cy.log('Count after closing popup:', countAfterClosingPopup);
|
231
230
|
expect(countAfterClosingPopup).to.equal(countBeforeOpeningPopup + 1);
|
232
|
-
|
231
|
+
});
|
233
232
|
});
|
234
233
|
|
235
234
|
it('CSS of strategies list in selected state', { tags: 'css' }, () => {
|
@@ -244,22 +243,8 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
244
243
|
thinkSpherePage.steps.clickOnStrategiesPreviewListLI();
|
245
244
|
});
|
246
245
|
|
247
|
-
it('Video icon
|
248
|
-
utilities.verifyElementVisibilityState(thinkSpherePage.videoIconWrapper(), '
|
249
|
-
});
|
250
|
-
|
251
|
-
it('When user uploads a video inside strategy then video icon should be visible besides the strategy name', () => {
|
252
|
-
thinkSpherePage.steps.switchToEditTab();
|
253
|
-
thinkSpherePage.videoLinkComponent()
|
254
|
-
.within(() => {
|
255
|
-
thinkSpherePage.uploadVideoLinkButton()
|
256
|
-
.click();
|
257
|
-
});
|
258
|
-
thinkSpherePage.steps.uploadVideoFile('uploads/sample2MB.mp4');
|
259
|
-
cy.interceptGraphql('getFileScanStatus');
|
260
|
-
cy.wait(5000);
|
261
|
-
thinkSpherePage.steps.switchToPreviewTab();
|
262
|
-
utilities.verifyElementVisibilityState(utilities.getNthElement(thinkSpherePage.videoIconWrapper(), 0), 'visible');
|
246
|
+
it('Video icon should be present by default besides the strategy name', () => {
|
247
|
+
utilities.verifyElementVisibilityState(thinkSpherePage.videoIconWrapper(), 'exist');
|
263
248
|
});
|
264
249
|
|
265
250
|
it('When user clicks on video icon then video should be played in the popup', () => {
|
@@ -319,7 +304,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
319
304
|
sentenceStartersTextDefault.forEach((label, index) => {
|
320
305
|
utilities.verifyInnerText(utilities.getNthElement(thinkSpherePage.chooseStartersListOptionLabels(), index), label);
|
321
306
|
});
|
322
|
-
utilities.
|
307
|
+
utilities.pressEscapeKey();
|
323
308
|
});
|
324
309
|
|
325
310
|
it('CSS of Sentence starters dropdown - active state', { tags: 'css' }, () => {
|
@@ -327,14 +312,13 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
327
312
|
utilities.verifyCSS(utilities.getNthElement(thinkSpherePage.chooseStartersListOptions(), 0), {
|
328
313
|
'color': css.color.liText,
|
329
314
|
'font-size': css.fontSize.default,
|
330
|
-
'font-weight': css.fontWeight.regular
|
331
|
-
'background-color': css.color.dropdownDefaultBG
|
315
|
+
'font-weight': css.fontWeight.regular
|
332
316
|
});
|
333
317
|
utilities.verifyCSS(utilities.getNthElement(thinkSpherePage.chooseStartersListOptions(), 1), {
|
334
318
|
'background-color': css.color.transparent
|
335
319
|
});
|
336
320
|
cy.log('Post step: Closing the Sentence starters dropdown');
|
337
|
-
utilities.
|
321
|
+
utilities.pressEscapeKey();
|
338
322
|
});
|
339
323
|
|
340
324
|
it('When user clicks on any starter then it should get written in the \'Write your plan\' text input field', () => {
|
@@ -454,7 +438,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
454
438
|
utilities.verifyElementVisibilityState(thinkSpherePage.strategyChip(), 'visible');
|
455
439
|
utilities.verifyInnerText(thinkSpherePage.strategyChip(), 'Look for a pattern');
|
456
440
|
});
|
457
|
-
|
441
|
+
|
458
442
|
it('CSS of strategy chip when it is not selected', { tags: 'css' }, () => {
|
459
443
|
utilities.verifyCSS(thinkSpherePage.strategyChip(), {
|
460
444
|
'border': `1px solid ${css.color.figDefaultComponentBorder}`,
|
@@ -476,7 +460,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
476
460
|
thinkSpherePage.contentEditableDiv().should('have.value', 'look for a pattern ');
|
477
461
|
});
|
478
462
|
});
|
479
|
-
|
463
|
+
|
480
464
|
it('CSS of strategy chip when it is selected and CSS of planning journal section', { tags: 'css' }, () => {
|
481
465
|
utilities.verifyCSS(thinkSpherePage.strategyChip(), {
|
482
466
|
'background-color': css.color.secondaryBtnBorder,
|
@@ -488,7 +472,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
488
472
|
'font-size': css.fontSize.heading,
|
489
473
|
'font-weight': css.fontWeight.semibold,
|
490
474
|
});
|
491
|
-
|
475
|
+
|
492
476
|
utilities.verifyCSS(thinkSpherePage.planningWriteWrapper(), {
|
493
477
|
'border': `1px solid ${css.color.secondaryBtnBorder}`,
|
494
478
|
'border-radius': '12px'
|
@@ -1,10 +1,10 @@
|
|
1
|
+
import uuid from 'react-uuid';
|
1
2
|
import { thinkSpherePage } from "../../../pages";
|
2
3
|
import { browseItemsPage } from "../../../pages/components/browseItemsPage";
|
3
4
|
import { commonComponents } from "../../../pages/components/commonComponents";
|
4
5
|
import abortEarlySetup from "../../../support/helpers/abortEarly";
|
5
6
|
import utilities from "../../../support/helpers/utilities";
|
6
7
|
const css = Cypress.env('css');
|
7
|
-
import uuid from 'react-uuid';
|
8
8
|
|
9
9
|
const sentenceStartersTextDefault = [
|
10
10
|
'The strategy I’m going to use is',
|
@@ -14,14 +14,14 @@ const sentenceStartersTextDefault = [
|
|
14
14
|
'If my strategy is not working, I will'
|
15
15
|
];
|
16
16
|
|
17
|
+
const uuidString = uuid();
|
18
|
+
|
17
19
|
describe('Preview question : ThinkSphere Question - Plan Section - preview tab', () => {
|
18
|
-
let randomItemName;
|
19
20
|
before(() => {
|
20
|
-
randomItemName = `~zzz thinksphere item name ${uuid()}`;
|
21
21
|
cy.loginAs('admin');
|
22
|
-
cy.createThinkSphereItem(
|
22
|
+
cy.createThinkSphereItem(uuidString, true);
|
23
23
|
cy.visit('/item-engine/thinksphere/browse-items');
|
24
|
-
browseItemsPage.steps.clickOnItemReferenceId(
|
24
|
+
browseItemsPage.steps.clickOnItemReferenceId(uuidString);
|
25
25
|
browseItemsPage.steps.clickOnAddReviewItem();
|
26
26
|
thinkSpherePage.steps.createReviewQuestion();
|
27
27
|
thinkSpherePage.steps.clickOnEditQuestionIcon();
|
@@ -30,7 +30,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
30
30
|
});
|
31
31
|
|
32
32
|
after(() => {
|
33
|
-
cy.deleteThinkSphereItem(
|
33
|
+
cy.deleteThinkSphereItem(uuidString);
|
34
34
|
});
|
35
35
|
|
36
36
|
describe('\'Question instruction\' section', () => {
|
@@ -87,7 +87,7 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
87
87
|
'font-size': css.fontSize.normal,
|
88
88
|
'font-weight': css.fontWeight.semibold,
|
89
89
|
'border': `1px solid ${css.color.secondaryBtnBorder}`,
|
90
|
-
'color': css.color.primaryBtnBorder,
|
90
|
+
'color': css.color.primaryBtnBorder,
|
91
91
|
});
|
92
92
|
});
|
93
93
|
|
@@ -96,13 +96,4 @@ describe('Preview question : ThinkSphere Question - Plan Section - preview tab',
|
|
96
96
|
utilities.verifyElementVisibilityState(thinkSpherePage.dialogBoxRoot(), 'notExist');
|
97
97
|
});
|
98
98
|
});
|
99
|
-
|
100
|
-
describe('Verify the Your plan Section', () => {
|
101
|
-
abortEarlySetup();
|
102
|
-
before(() => {
|
103
|
-
thinkSpherePage.steps.clickOnSolveTab();
|
104
|
-
});
|
105
|
-
|
106
|
-
thinkSpherePage.tests.verifyYourPlanSection();
|
107
|
-
});
|
108
99
|
});
|
@@ -4,18 +4,18 @@ import abortEarlySetup from "../../../support/helpers/abortEarly";
|
|
4
4
|
import utilities from "../../../support/helpers/utilities";
|
5
5
|
const css = Cypress.env('css');
|
6
6
|
const canvasTools = [
|
7
|
-
'Text', '
|
7
|
+
'Text', 'Pen', 'Highlighter', 'Image', 'Shapes',
|
8
8
|
'Stamps', 'Unifix Cube', 'Diagrams', 'Array',
|
9
9
|
'Number line', 'Fraction bars', 'Protractor', 'Table', 'Grids',
|
10
|
-
'Equation editor', 'Algebra tiles',
|
10
|
+
'Equation editor', 'Algebra tiles', 'Point eraser', 'Item eraser'
|
11
11
|
];
|
12
|
-
const defaultSelectedCanvasTools = ['Text', '
|
13
|
-
const canvasControls = ['
|
14
|
-
const defaultSelectedCanvasControls = ['
|
15
|
-
const defaultTool = '
|
12
|
+
const defaultSelectedCanvasTools = ['Text', 'Pen', 'Highlighter', 'Image', 'Shapes', 'Stamps'];
|
13
|
+
const canvasControls = ['Move', 'Delete', 'Undo', 'Redo', 'Clear all'];
|
14
|
+
const defaultSelectedCanvasControls = ['Move', 'Delete', 'Undo', 'Redo', 'Clear all'];
|
15
|
+
const defaultTool = 'Pen';
|
16
16
|
const defaultSelectedCategories = ['Numpad', 'Keypad', 'Intermediate', 'Primary', 'General', 'Common', 'Algebra', 'Geo', 'Compare', 'Matrices'];
|
17
17
|
const defaultSelectedStamps = ['Stamp 1', 'Stamp 2', 'Stamp 3', 'Stamp 4', 'Stamp 5', 'Stamp 6', 'Stamp 7', 'Stamp 8', 'Stamp 9', 'Stamp 10', 'Stamp 11', 'Stamp 12', 'Stamp 13'];
|
18
|
-
const defaultToolsOptions = ['Text', '
|
18
|
+
const defaultToolsOptions = ['Text', 'Pen', 'Highlighter'];
|
19
19
|
|
20
20
|
|
21
21
|
describe('ThinkSphere Question - Solve Phases Section', () => {
|
@@ -141,6 +141,11 @@ describe('ThinkSphere Question - Solve Phases Section', () => {
|
|
141
141
|
});
|
142
142
|
});
|
143
143
|
|
144
|
+
it('User should be able to unselect any default selected control.', () => {
|
145
|
+
thinkSpherePage.steps.deselectOptionFromToolsAndControls('Move');
|
146
|
+
thinkSpherePage.steps.verifyOptionIsNotSelected('Move');
|
147
|
+
});
|
148
|
+
|
144
149
|
thinkSpherePage.tests.verifyDefaultToolDropdown(defaultToolsOptions, defaultTool);
|
145
150
|
|
146
151
|
it('\'Customize stamps\' component should be present inside \'Customize toolbar options and controls\' accordion of solve phase', () => {
|
@@ -22,6 +22,10 @@ describe('Student view : ThinkSphere Question - Review Section', () => {
|
|
22
22
|
thinkSpherePage.steps.clickOnReviewTab();
|
23
23
|
});
|
24
24
|
|
25
|
+
after(() => {
|
26
|
+
cy.deleteThinkSphereItem(uuidString);
|
27
|
+
});
|
28
|
+
|
25
29
|
describe('\'Question instruction\' section', () => {
|
26
30
|
abortEarlySetup();
|
27
31
|
it('\'Question instruction\' section should be present', () => {
|
@@ -76,7 +80,7 @@ describe('Student view : ThinkSphere Question - Review Section', () => {
|
|
76
80
|
'font-size': css.fontSize.normal,
|
77
81
|
'font-weight': css.fontWeight.semibold,
|
78
82
|
'border': `1px solid ${css.color.secondaryBtnBorder}`,
|
79
|
-
'color': css.color.primaryBtnBorder,
|
83
|
+
'color': css.color.primaryBtnBorder,
|
80
84
|
});
|
81
85
|
});
|
82
86
|
|
@@ -86,15 +90,6 @@ describe('Student view : ThinkSphere Question - Review Section', () => {
|
|
86
90
|
});
|
87
91
|
});
|
88
92
|
|
89
|
-
describe('Verify the Your plan Section', () => {
|
90
|
-
abortEarlySetup();
|
91
|
-
before(() => {
|
92
|
-
thinkSpherePage.steps.clickOnSolveTab();
|
93
|
-
});
|
94
|
-
|
95
|
-
thinkSpherePage.tests.verifyYourPlanSection();
|
96
|
-
});
|
97
|
-
|
98
93
|
describe('\'Check your math\' section', () => {
|
99
94
|
abortEarlySetup();
|
100
95
|
it('\'Check your math\' section header should be present', () => {
|
@@ -109,7 +104,7 @@ describe('Student view : ThinkSphere Question - Review Section', () => {
|
|
109
104
|
'font-weight': css.fontWeight.semibold,
|
110
105
|
});
|
111
106
|
});
|
112
|
-
|
107
|
+
|
113
108
|
it('\'The problem is asking me to\' section header should be present', () => {
|
114
109
|
utilities.verifyElementVisibilityState(thinkSpherePage.problemAskingToMeTextWrapper(), 'visible');
|
115
110
|
utilities.verifyInnerText(thinkSpherePage.problemAskingToMeTextWrapper(), 'The problem is asking me to...');
|
@@ -133,10 +128,16 @@ describe('Student view : ThinkSphere Question - Review Section', () => {
|
|
133
128
|
|
134
129
|
it('When User type in the \'The problem is asking me to\' in the plan tab, then it should render in the \'The problem is asking me to\' in the review tab', () => {
|
135
130
|
thinkSpherePage.steps.clickOnPlanTab();
|
136
|
-
thinkSpherePage.steps.verifyProblemAskingTextAreaFunctionality(
|
131
|
+
thinkSpherePage.steps.verifyProblemAskingTextAreaFunctionality(`This is a test text for the problem.
|
132
|
+
test
|
133
|
+
test
|
134
|
+
test`);
|
137
135
|
thinkSpherePage.steps.clickOnReviewTab();
|
138
136
|
utilities.verifyElementVisibilityState(thinkSpherePage.problemStatementWrapper(), 'visible');
|
139
|
-
|
137
|
+
thinkSpherePage.steps.verifyProblemAskingTextAreaValue(`This is a test text for the problem.
|
138
|
+
test
|
139
|
+
test
|
140
|
+
test`);
|
140
141
|
});
|
141
142
|
|
142
143
|
it('CSS of \'The problem is asking me to\' section statement', { tags: 'css' }, () => {
|
@@ -18,7 +18,6 @@ describe('Student view : ThinkSphere Question - Solve Section', () => {
|
|
18
18
|
editSectionWhiteBoardToolButtons.forEach((toolName) => {
|
19
19
|
thinkSpherePage.steps.selectOptionFromToolsAndControls(toolName);
|
20
20
|
});
|
21
|
-
cy.wait(5000); // Wait for the tools to be added
|
22
21
|
thinkSpherePage.steps.clickOnSaveButton();
|
23
22
|
cy.visit('/item-engine/thinksphere/browse-items');
|
24
23
|
browseItemsPage.steps.clickOnActionButton();
|