chore: tests for billings (#29720)

This commit is contained in:
Joel
2025-12-16 15:06:53 +08:00
committed by GitHub
parent e5cf0d0bf6
commit 47cd94ec3e
9 changed files with 603 additions and 1 deletions

View File

@ -19,7 +19,13 @@
*/
export const useTranslation = () => ({
t: (key: string) => key,
t: (key: string, options?: Record<string, unknown>) => {
if (options?.returnObjects)
return [`${key}-feature-1`, `${key}-feature-2`]
if (options)
return `${key}:${JSON.stringify(options)}`
return key
},
i18n: {
language: 'en',
changeLanguage: jest.fn(),