From a1744d363c0a8684a5d7f451fc8ca94ce88eb506 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20Sch=C3=A4fer?= Date: Thu, 18 Apr 2019 16:53:40 +0200 Subject: [PATCH] Click away iziToast message after login Sometimes, the popup was covering the create-post button thus failing some cypress tests locally. --- cypress/support/commands.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cypress/support/commands.js b/cypress/support/commands.js index 5b4c2055b..a7cb76a27 100644 --- a/cypress/support/commands.js +++ b/cypress/support/commands.js @@ -46,7 +46,8 @@ Cypress.Commands.add('login', ({ email, password }) => { cy.get('button[name=submit]') .as('submitButton') .click() - cy.location('pathname').should('eq', '/') // we're in! + cy.get('.iziToast-message').should('contain', 'You are logged in!') + cy.get('.iziToast-close').click() }) Cypress.Commands.add('logout', (email, password) => {