From 1edef05feca68b848a89d2a00d3425b92d23ccd4 Mon Sep 17 00:00:00 2001 From: Ulf Gebhardt Date: Mon, 12 Apr 2021 19:19:30 +0200 Subject: [PATCH] waiting command --- cypress/integration/common/I_search_for_{string}.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/cypress/integration/common/I_search_for_{string}.js b/cypress/integration/common/I_search_for_{string}.js index 9040de7d6..eaad481f7 100644 --- a/cypress/integration/common/I_search_for_{string}.js +++ b/cypress/integration/common/I_search_for_{string}.js @@ -1,8 +1,12 @@ import { When } from "cypress-cucumber-preprocessor/steps"; When("I search for {string}", value => { + cy.intercept({ + method: "POST", + url: "http://localhost:3000/api", + }).as("graphqlRequest"); cy.get(".searchable-input .ds-select input") .focus() - .type(value) - .wait(750); + .type(value); + cy.wait("@graphqlRequest"); }); \ No newline at end of file