Skip to content

Commit 7ba67e0

Browse files
committed
Trying to adjust the test a bit.
1 parent 0a88be7 commit 7ba67e0

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

eform-client/cypress/e2e/plugins/time-planning-pn/b/dashboard-assert.spec.cy.ts

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -706,14 +706,15 @@ describe('Dashboard assert', () => {
706706
cy.wait(500);
707707
for (let i = 0; i < updatePlanTextsNextWeek.length; i++) {
708708
let firstShiftId = `#firstShift0_${i}`;
709+
let cellId = `#cell0_${i}`;
710+
cy.get(cellId).scrollIntoView();
711+
cy.get(firstShiftId).scrollIntoView();
709712
cy.get(firstShiftId).should('include.text', updatePlanTextsNextWeek[i].firstShift);
710713
if (planTextsNextWeek[i].secondShift) {
711714
let secondShiftId = `#secondShift0_${i}`;
712715
cy.get(secondShiftId).should('include.text', updatePlanTextsNextWeek[i].secondShift);
713716
}
714717

715-
let cellId = `#cell0_${i}`;
716-
cy.get(cellId).scrollIntoView();
717718
cy.get(cellId).click();
718719
cy.get('#planHours').should('be.visible');
719720
cy.get('#planHours').should('include.value', updatePlanTextsNextWeek[i].calculatedHours);
@@ -729,6 +730,8 @@ describe('Dashboard assert', () => {
729730
cy.wait('@index-update', { timeout: 60000 });
730731
cy.wait(500);
731732
for (let i = 0; i < updatePlanTextsFutureWeek.length; i++) {
733+
let cellId = `#cell0_${i}`;
734+
cy.get(cellId).scrollIntoView();
732735
if (planTextsFutureWeek[i].firstShift) {
733736
let firstShiftId = `#firstShift0_${i}`;
734737
cy.get(firstShiftId).should('include.text', updatePlanTextsFutureWeek[i].firstShift);
@@ -742,8 +745,6 @@ describe('Dashboard assert', () => {
742745
let secondShiftId = `#secondShift0_${i}`;
743746
cy.get(secondShiftId).should('include.text', updatePlanTextsFutureWeek[i].secondShift);
744747
}
745-
let cellId = `#cell0_${i}`;
746-
cy.get(cellId).scrollIntoView();
747748
cy.get(cellId).click();
748749
cy.get('#planHours').should('be.visible');
749750
cy.get('#planHours').should('include.value', updatePlanTextsFutureWeek[i].calculatedHours);

eform-client/cypress/e2e/plugins/time-planning-pn/d/dashboard-edit-a.spec.cy.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ describe('Dashboard edit values', () => {
5858
});
5959

6060
afterEach(() => {
61+
cy.get('#cell0_0').scrollIntoView();
6162
cy.get('#cell0_0').click();
6263

6364
['#plannedStartOfShift1', '#start1StartedAt'].forEach(

0 commit comments

Comments
 (0)