From 92d0fe942ae49c82a0c9c5c3f847db9f0fac2edf Mon Sep 17 00:00:00 2001 From: Santoshkumar Nateekar Date: Fri, 4 Aug 2023 08:36:13 -0700 Subject: [PATCH] [ Daily Run] Carouse block script fix for Windows platform (#149) * update-4 * carousel daily run fix * remove manual.yml --------- Co-authored-by: Santoshkumar Sharanappa Nateekar Co-authored-by: Santoshkumar Sharanappa Nateekar --- features/milo/carousel.block.spec.js | 6 +++--- selectors/milo/carousel.block.page.js | 5 +++++ tests/milo/carousel.block.test.js | 6 +++--- 3 files changed, 11 insertions(+), 6 deletions(-) diff --git a/features/milo/carousel.block.spec.js b/features/milo/carousel.block.spec.js index 72b7a09c..ffc52f7d 100644 --- a/features/milo/carousel.block.spec.js +++ b/features/milo/carousel.block.spec.js @@ -2,21 +2,21 @@ module.exports = { BlockName: 'Carousel Block', features: [ { - tcid: '1', + tcid: '0', name: '@Carousel(container)', path: '/drafts/nala/blocks/carousel/lightbox', tags: '@carousel @carousel-container @smoke @regression @milo', envs: '@milo-live @milo-prod', }, { - tcid: '2', + tcid: '1', name: '@Carousel(lightbox)', path: '/drafts/nala/blocks/carousel/fullpage-carousel', tags: '@carousel @carousel-container @smoke @regression @milo', envs: '@milo-live milo-prod', }, { - tcid: '3', + tcid: '2', name: '@Carousel Multi slide(show-2)', path: '/drafts/nala/blocks/carousel/carousel-show-2', tags: '@carousel @carousel-container @regression @milo', diff --git a/selectors/milo/carousel.block.page.js b/selectors/milo/carousel.block.page.js index a9c23229..dbfaa2c6 100644 --- a/selectors/milo/carousel.block.page.js +++ b/selectors/milo/carousel.block.page.js @@ -197,18 +197,23 @@ export class Carousel { let isDisplayed; switch (type) { case 'carouselLightbox': + await this.carouselLightbox.waitFor({ state: 'visible' }); isDisplayed = await this.carouselLightbox.isVisible(); break; case 'carouselFullpage': + await this.carouselFullpage.waitFor({ state: 'visible' }); isDisplayed = await this.carouselFullpage.isVisible(); break; case 'carouselContainer': + await this.carouselContainer.waitFor({ state: 'visible' }); isDisplayed = await this.carouselContainer.isVisible(); break; case 'carouselShow-2': + await this.carouselContainerShow2.waitFor({ state: 'visible' }); isDisplayed = await this.carouselContainerShow2.isVisible(); break; case 'carousel': + await this.carouselDefault.waitFor({ state: 'visible' }); isDisplayed = await this.carouselDefault.isVisible(); break; default: diff --git a/tests/milo/carousel.block.test.js b/tests/milo/carousel.block.test.js index 542e4843..f9d000dd 100644 --- a/tests/milo/carousel.block.test.js +++ b/tests/milo/carousel.block.test.js @@ -10,7 +10,7 @@ test.describe('Milo Carousel Block test suite', () => { }); test(`${features[0].name},${features[0].tags}`, async ({ page, baseURL }) => { - console.info('[Test Page]: ', baseURL); + console.info(`[Test Page]: ${baseURL}${features[0].path}`); await test.step('step-1: Go to Carousel block test page', async () => { await page.goto(`${baseURL}${features[0].path}`); @@ -50,7 +50,7 @@ test.describe('Milo Carousel Block test suite', () => { }); test(`${features[1].name},${features[1].tags}`, async ({ page, baseURL }) => { - console.info('[Test Page]: ', baseURL); + console.info(`[Test Page]: ${baseURL}${features[0].path}`); await test.step('step-1: Go to Carousel lightbox block test page', async () => { await page.goto(`${baseURL}${features[1].path}`); @@ -83,7 +83,7 @@ test.describe('Milo Carousel Block test suite', () => { }); test(`${features[2].name},${features[2].tags}`, async ({ page, baseURL }) => { - console.info('[Test Page]: ', baseURL); + console.info(`[Test Page]: ${baseURL}${features[2].path}`); await test.step('step-1: Go to Carousel multi-slide show-2 block test page', async () => { await page.goto(`${baseURL}${features[2].path}`);