From ad41b23e85518ab22a9b2e9c0aa9c8e907bc2c02 Mon Sep 17 00:00:00 2001 From: sangeetha-nayak Date: Mon, 6 May 2024 18:42:51 +0530 Subject: [PATCH] fix HG tests --- .../2-general-onboarding-flow/sitetype-secondary.cy.js | 4 ++-- .../3-ecommerce-onboarding-flow/sitetype-secondary.cy.js | 4 ++-- tests/cypress/integration/wp-module-support/EventsApi.cy.js | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/tests/cypress/integration/2-general-onboarding-flow/sitetype-secondary.cy.js b/tests/cypress/integration/2-general-onboarding-flow/sitetype-secondary.cy.js index b479df92b..b5c756848 100644 --- a/tests/cypress/integration/2-general-onboarding-flow/sitetype-secondary.cy.js +++ b/tests/cypress/integration/2-general-onboarding-flow/sitetype-secondary.cy.js @@ -44,7 +44,7 @@ describe( 'Get Started Site Type Secondary', function () { let SubcategoryCount = 0; let num = 0; const className = '.nfd-card-sec-category'; - cy.get( className ).should( 'be.visible', { timeout: 10000 } ); + cy.get( className, { timeout: 15000 } ).should( 'be.visible'); const arr = cy.get( className ); arr.each( () => { cy.get( className ) @@ -53,7 +53,7 @@ describe( 'Get Started Site Type Secondary', function () { .then( ( $element ) => { const dataSlugText = $element.attr( 'data-slug' ); if ( num >= 2 ) { - cy.wait( 5000 ); + cy.wait( 7000 ); } EventsAPI( 'secondary_type', diff --git a/tests/cypress/integration/3-ecommerce-onboarding-flow/sitetype-secondary.cy.js b/tests/cypress/integration/3-ecommerce-onboarding-flow/sitetype-secondary.cy.js index 0aafa8520..53471a376 100644 --- a/tests/cypress/integration/3-ecommerce-onboarding-flow/sitetype-secondary.cy.js +++ b/tests/cypress/integration/3-ecommerce-onboarding-flow/sitetype-secondary.cy.js @@ -58,7 +58,7 @@ describe( 'Get Started Site Type Secondary', function () { let SubcategoryCount = 0; let num = 0; const className = '.nfd-card-sec-category'; - cy.get( className ).should( 'be.visible' ); + cy.get( className, { timeout: 15000 } ).should( 'be.visible' ); const arr = cy.get( className ); arr.each( () => { cy.get( className ) @@ -67,7 +67,7 @@ describe( 'Get Started Site Type Secondary', function () { .then( ( $element ) => { const dataSlugText = $element.attr( 'data-slug' ); if ( num >= 2 ) { - cy.wait( 5000 ); + cy.wait( 7000 ); } EventsAPI( 'secondary_type', diff --git a/tests/cypress/integration/wp-module-support/EventsApi.cy.js b/tests/cypress/integration/wp-module-support/EventsApi.cy.js index 11bab3d93..98330f843 100644 --- a/tests/cypress/integration/wp-module-support/EventsApi.cy.js +++ b/tests/cypress/integration/wp-module-support/EventsApi.cy.js @@ -5,7 +5,7 @@ export const APIList = { export const EventsAPI = ( events_name, card_val, api_name ) => { cy.intercept( api_name ).as( 'events' ); - cy.wait( '@events', { timeout: 10000 } ).then( ( requestObject ) => { + cy.wait( '@events', { timeout: 15000 } ).then( ( requestObject ) => { const responseBody = requestObject.request.body; const responseData1 = responseBody[ 0 ].data; if ( events_name == 'experience_level' ) {