Skip to content

Commit

Permalink
scroll e2e testing
Browse files Browse the repository at this point in the history
  • Loading branch information
stazrouti committed Feb 11, 2024
1 parent 782bd0a commit bd4f61a
Showing 1 changed file with 19 additions and 0 deletions.
19 changes: 19 additions & 0 deletions cypress/e2e/back_to_top .cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
it("show car details", () => {
cy.visit("http://localhost:3000/");
cy.get('.pick-container__title') // replace with the actual selector for your modal
.should('be.visible') // Check if the modal is visible
.contains('Vehicle Models');

cy.get('.pick-description__table__col').should('be.visible').contains('Audi');
cy.get('.pick-description__table__col').should('be.visible').contains('AC');

/* cy.get('BMW 320 ModernLine'); */
cy.get('#btn4').click();
cy.get('.pick-description__table__col').should('be.visible').contains('320');
cy.get('.pick-description__table__col').should('be.visible').contains('BMW');
cy.get('.pick-description__table__col').should('be.visible').contains('AC');
cy.get('.pick-description__table__col').should('be.visible').contains('Diesel');

cy.get('.show-scroll').click({force: true});
cy.get('.show-scroll').should('not.exist');
});

0 comments on commit bd4f61a

Please sign in to comment.