From 6d381d8f6b2b9a8bfd4ae6cfffa28ad5559a1f4c Mon Sep 17 00:00:00 2001 From: Ejaaz Khan Date: Wed, 19 Feb 2025 17:40:17 +0530 Subject: [PATCH] test: fix failing tests --- cypress/integration/cell.js | 2 +- cypress/integration/column.js | 18 +++++++++--------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/cypress/integration/cell.js b/cypress/integration/cell.js index f95f38b..65b8c3a 100644 --- a/cypress/integration/cell.js +++ b/cypress/integration/cell.js @@ -61,7 +61,7 @@ describe('Cell', function () { cy.clickCell(2, 0) .type('{ctrl}{rightarrow}'); cy.get('.dt-cell--focus') - .should('have.class', 'dt-cell--7-0'); + .should('have.class', 'dt-cell--11-0'); }); it('cell selection using shift + arrow keys', function () { diff --git a/cypress/integration/column.js b/cypress/integration/column.js index 7e9b2e0..d4ab4ef 100644 --- a/cypress/integration/column.js +++ b/cypress/integration/column.js @@ -29,35 +29,35 @@ describe('Column', function () { .its('currentSort.colIndex') .should('eq', 2); - cy.get('.dt-scrollable .dt-row:first') + cy.get('.dt-scrollable .dt-row:first div:nth-of-type(3)') .contains('Airi Satou'); cy.clickDropdownItem(2, 'Reset sorting'); }); it('removes column using dropdown action', function () { - cy.get('.dt-cell--header').should('have.length', 8); + cy.get('.dt-cell--header').should('have.length', 12); cy.clickDropdown(5); cy.clickDropdownItem(5, 'Remove column'); - cy.get('.dt-cell--header').should('have.length', 7); + cy.get('.dt-cell--header').should('have.length', 11); }); it('resize column with mouse drag', function () { - cy.get('.dt-cell--header-3 .dt-cell__resize-handle').as('resize-handle'); + cy.get('.dt-cell--header-4 .dt-cell__resize-handle').as('resize-handle'); cy .get('@resize-handle') .trigger('mousedown') - .trigger('mousemove', { pageX: 510, pageY: 20, which: 1 }) + .trigger('mousemove', { pageX: 710, pageY: 20, which: 1 }) .trigger('mouseup'); - cy.getColumnCell(3) + cy.getColumnCell(4) .should('have.css', 'width') - .and('match', /13\dpx/); - cy.getCell(3, 1) + .and('match', /^82\d*(\.\d+)?px$/); + cy.getCell(4, 1) .should('have.css', 'width') - .and('match', /13\dpx/); + .and('match', /^82\d*(\.\d+)?px$/); }); it('resize column using double click', function () {