Explorar o código

add confirmation of the existence of presentation modals

Shun Miyazawa %!s(int64=4) %!d(string=hai) anos
pai
achega
9217a54f04

+ 3 - 6
packages/app/test/cypress/integration/2-basic-features/open-presentation-modal.spec.ts

@@ -28,8 +28,7 @@ context('Open presentation modal', () => {
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
     });
     });
 
 
-    // eslint-disable-next-line cypress/no-unnecessary-waiting
-    cy.wait(1500);
+    cy.get('.grw-presentation-modal').should('be.visible')
     cy.screenshot(`${ssPrefix}-opne-top`, { capture: 'viewport' });
     cy.screenshot(`${ssPrefix}-opne-top`, { capture: 'viewport' });
   });
   });
 
 
@@ -41,8 +40,7 @@ context('Open presentation modal', () => {
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
     });
     });
 
 
-    // eslint-disable-next-line cypress/no-unnecessary-waiting
-    cy.wait(1500);
+    cy.get('.grw-presentation-modal').should('be.visible')
     cy.screenshot(`${ssPrefix}-open-bootstrap4`, { capture: 'viewport' });
     cy.screenshot(`${ssPrefix}-open-bootstrap4`, { capture: 'viewport' });
   });
   });
 
 
@@ -54,8 +52,7 @@ context('Open presentation modal', () => {
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
       cy.getByTestid('open-presentation-modal-btn').click({force: true})
     });
     });
 
 
-    // eslint-disable-next-line cypress/no-unnecessary-waiting
-    cy.wait(1500);
+    cy.get('.grw-presentation-modal').should('be.visible')
     cy.screenshot(`${ssPrefix}-open-bootstrap4-with-ancker-link`, { capture: 'viewport' });
     cy.screenshot(`${ssPrefix}-open-bootstrap4-with-ancker-link`, { capture: 'viewport' });
   });
   });
 });
 });