From a2ec22af2f05129862cac759fdfad89d6cbfa1fc Mon Sep 17 00:00:00 2001 From: williamlardier Date: Wed, 28 Aug 2024 16:23:04 +0200 Subject: [PATCH] Extend bucket notification timeout and map to the test timeout Issue: ZENKO-4806 --- tests/ctst/steps/notifications.ts | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/ctst/steps/notifications.ts b/tests/ctst/steps/notifications.ts index 54cad9e168..0fb75e90d9 100644 --- a/tests/ctst/steps/notifications.ts +++ b/tests/ctst/steps/notifications.ts @@ -1,11 +1,11 @@ import { Then, Given, When, After } from '@cucumber/cucumber'; import { strict as assert } from 'assert'; -import { S3, Utils, KafkaHelper, AWSVersionObject, NotificationDestination } from 'cli-testing'; +import { S3, Utils, KafkaHelper, AWSVersionObject, NotificationDestination, Constants } from 'cli-testing'; import { Message } from 'node-rdkafka'; import { cleanS3Bucket } from 'common/common'; import Zenko from 'world/Zenko'; -const KAFKA_TESTS_TIMEOUT = Number(process.env.KAFKA_TESTS_TIMEOUT) || 60000; +const KAFKA_TESTS_TIMEOUT = Number(process.env.KAFKA_TESTS_TIMEOUT) || Constants.DEFAULT_TIMEOUT * 1.5; const allNotificationTypes = [ 's3:ObjectCreated:Put', @@ -308,6 +308,7 @@ Then('notifications should be enabled for {string} event in destination {int}', }); Then('i should {string} a notification for {string} event in destination {int}', + { timeout: Constants.DEFAULT_TIMEOUT * 2 }, async function (this: Zenko, receive: string, notificationType: string, destination: number) { const receivedNotification = await KafkaHelper.consumeTopicUntilCondition(