Skip to content

Commit

Permalink
Add wait to meganav and autocomplete spec
Browse files Browse the repository at this point in the history
  • Loading branch information
dpiatek committed Dec 14, 2023
1 parent a9ae563 commit d3019ca
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 5 additions & 4 deletions cypress/e2e/core/company_autocomplete/behaviour.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,11 @@ describe("Company Autocomplete", () => {

it("closes the dropdown when clicked outside it", () => {
cy.get("input")
.type("A")
.get("body")
.click()
.get(CONTAINER_SELECTOR)
.type("A");
cy.get("body")
.click();
cy.wait(1000);
cy.get(CONTAINER_SELECTOR)
.should("not.be.visible");
});

Expand Down
2 changes: 2 additions & 0 deletions cypress/e2e/core/meganav/behaviour.cy.js
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,11 @@ describe("Opening panels on desktop", () => {
cy.get(PLATFORM_PANEL).should("not.be.visible");

cy.get(PLATFORM_PANEL_OPEN_CONTROL).trigger("mouseenter");
cy.wait(1000);
cy.get(PLATFORM_PANEL).should("be.visible");

cy.get(PLATFORM_PANEL_OPEN_CONTROL).trigger("mouseleave");
cy.wait(1000);
cy.get(PLATFORM_PANEL).should("not.be.visible");
});

Expand Down

0 comments on commit d3019ca

Please sign in to comment.