From ca6c4ac7912bf70d7fb345b779752959832f4b97 Mon Sep 17 00:00:00 2001 From: KishenKumarrrrr Date: Thu, 8 Feb 2024 16:42:00 +0800 Subject: [PATCH] fix: broken tests --- frontend/config-overrides.js | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/frontend/config-overrides.js b/frontend/config-overrides.js index 66a0b74fa..d99dae618 100644 --- a/frontend/config-overrides.js +++ b/frontend/config-overrides.js @@ -35,15 +35,17 @@ module.exports.jest = (config) => { '^styles/?(.*)': '/src/styles/$1', '^@shared/?(.*)': '/../shared/src/$1', } - config.testPathIgnorePatterns.push(...[ - 'frontend/src/components/dashboard/create/email/tests/EmailRecipients.test.tsx', - 'frontend/src/components/dashboard/create/sms/tests/SMSRecipients.test.tsx', - 'frontend/src/components/dashboard/create/telegram/tests/TelegramRecipients.test.tsx', - 'frontend/src/components/dashboard/tests/integration/email.test.tsx', - 'frontend/src/components/dashboard/tests/integration/sms.test.tsx', - 'frontend/src/components/dashboard/tests/integration/telegram.test.tsx', - ]) - + if (!config.testPathIgnorePatterns) { + config.testPathIgnorePatterns = [ + 'frontend/src/components/dashboard/create/email/tests/EmailRecipients.test.tsx', + 'frontend/src/components/dashboard/create/sms/tests/SMSRecipients.test.tsx', + 'frontend/src/components/dashboard/create/telegram/tests/TelegramRecipients.test.tsx', + 'frontend/src/components/dashboard/tests/integration/email.test.tsx', + 'frontend/src/components/dashboard/tests/integration/sms.test.tsx', + 'frontend/src/components/dashboard/tests/integration/telegram.test.tsx', + ]; + } + const moduleNameMapper = { ...config.moduleNameMapper, ...aliasMap } return { ...config,