The open alternative to Salesforce, designed for AI.
TypeScript crmcrm-systemcustomergood-first-issuegraphqlhacktoberfestjavascriptmarketingmonoreponestjsopen-sourcepostgresqlreactreactjssalestypescriptweb
Cover the empty currency code in getCurrencyLabel tests (#28424)
Charles Bochet4af96d08d84d
diff --git a/packages/twenty-front/src/modules/localization/utils/__tests__/getCurrencyLabel.test.ts b/packages/twenty-front/src/modules/localization/utils/__tests__/getCurrencyLabel.test.tsindex 4078fd44c53..6058796d451 100644--- a/packages/twenty-front/src/modules/localization/utils/__tests__/getCurrencyLabel.test.ts+++ b/packages/twenty-front/src/modules/localization/utils/__tests__/getCurrencyLabel.test.ts@@ -30,4 +30,8 @@ describe('getCurrencyLabel', () => {it('should fall back to the code for an unknown currency', () => {expect(getCurrencyLabel({ currencyCode: 'XYZ', locale: 'en' })).toBe('XYZ');});++ it('should not crash on an empty currency code', () => {+ expect(getCurrencyLabel({ currencyCode: '', locale: 'en' })).toBe('');+ });});