From 7c288dc4285a17b2bed19a0b1fb2d26f65129089 Mon Sep 17 00:00:00 2001 From: Mohammed Nihal <57055998+nihal467@users.noreply.github.com> Date: Mon, 23 Sep 2024 20:04:11 +0530 Subject: [PATCH] adding wait to the test --- cypress/e2e/facility_spec/FacilityHomepage.cy.ts | 1 + cypress/pageobject/Facility/FacilityHome.ts | 1 + 2 files changed, 2 insertions(+) diff --git a/cypress/e2e/facility_spec/FacilityHomepage.cy.ts b/cypress/e2e/facility_spec/FacilityHomepage.cy.ts index d261036291f..6b4cbfc3782 100644 --- a/cypress/e2e/facility_spec/FacilityHomepage.cy.ts +++ b/cypress/e2e/facility_spec/FacilityHomepage.cy.ts @@ -102,6 +102,7 @@ describe("Facility Homepage Function", () => { facilityHome.csvDownloadIntercept(capacitiesAlias, "&capacity"); facilityHome.clickExportButton(); facilityHome.clickMenuItem("Capacities"); + facilityHome.verifyDownload(capacitiesAlias); facilityHome.clickSearchButton(); // Download the Doctors CSV facilityHome.csvDownloadIntercept(doctorsAlias, "&doctors"); diff --git a/cypress/pageobject/Facility/FacilityHome.ts b/cypress/pageobject/Facility/FacilityHome.ts index f10834c3c63..ba8ffb77c32 100644 --- a/cypress/pageobject/Facility/FacilityHome.ts +++ b/cypress/pageobject/Facility/FacilityHome.ts @@ -91,6 +91,7 @@ class FacilityHome { verifyDownload(alias: string) { cy.wait(`@${alias}`).its("response.statusCode").should("eq", 200); + cy.wait(5000); } getURL() {