Skip to content

Commit

Permalink
add waits on fast run test
Browse files Browse the repository at this point in the history
  • Loading branch information
JeffGreiner-eaton committed Jun 12, 2024
1 parent 871af71 commit 5129574
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion cypress/integration/form-validation/fixed-length.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,6 @@ describe('Form validation fixed length', () => {

it('should display success with correct passcode', () => {
cy.get('[data-cy=passcode]').type('123456')
cy.get('[data-cy=success]').should('be.visible')
cy.get('[data-cy=success]', { timeout: 10000 }).should('be.visible')
});
});
2 changes: 1 addition & 1 deletion cypress/integration/form-validation/in-list.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ describe('Form validation in a list', () => {
});

it('should display unselected toggle', () => {
cy.get('.mat-slide-toggle-bar')
cy.get('.mat-slide-toggle-bar', { timeout: 10000 })
.find('input')
.filter('#mat-slide-toggle-1-input')
.should('have.attr', 'aria-checked', 'false')
Expand Down
8 changes: 4 additions & 4 deletions cypress/integration/form-validation/phone-number.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,22 +16,22 @@ describe('Form validation phone number format', () => {
cy.get('body').click(top, {force: true})
cy.get('[data-cy=phone-helper-error]').should('contain', 'Please enter a valid U.S. phone number.')
cy.get('[data-cy=country-selector]').click()
cy.get('#mat-select-0-panel').contains('CA').click()
cy.get('#mat-select-0-panel', { timeout: 10000 }).contains('CA').click()
cy.get('[data-cy=phone-input]').click()
cy.get('body').click(top, {force: true})
cy.get('[data-cy=phone-helper-error]').should('contain', 'Please enter a valid Canadian phone number.')
cy.get('[data-cy=country-selector]').click()
cy.get('#mat-select-0-panel').contains('RU').click()
cy.get('#mat-select-0-panel', { timeout: 10000 }).contains('RU').click()
cy.get('[data-cy=phone-input]').click()
cy.get('body').click(top, {force: true})
cy.get('[data-cy=phone-helper-error]').should('contain', 'Please enter a valid Russian phone number.')
cy.get('[data-cy=country-selector]').click()
cy.get('#mat-select-0-panel').contains('EG').click()
cy.get('#mat-select-0-panel', { timeout: 10000 }).contains('EG').click()
cy.get('[data-cy=phone-input]').click()
cy.get('body').click(top, {force: true})
cy.get('[data-cy=phone-helper-error]').should('contain', 'Please enter a valid Egyptian phone number.')
cy.get('[data-cy=country-selector]').click()
cy.get('#mat-select-0-panel').contains('IN').click()
cy.get('#mat-select-0-panel', { timeout: 10000 }).contains('IN').click()
cy.get('[data-cy=phone-input]').click()
cy.get('body').click(top, {force: true})
cy.get('[data-cy=phone-helper-error]').should('contain', 'Please enter a valid Indian phone number.')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ describe('Hidden toolbar menu displays on small devices', () => {
it(`should display menu icon ${url}`, () => {
cy.visit(url);
cy.viewport(size);
cy.get('[data-cy=toolbar-menu]')
cy.get('[data-cy=toolbar-menu], { timeout: 10000 }')
.should('be.visible')
});
});
Expand Down

0 comments on commit 5129574

Please sign in to comment.