MVp
This commit is contained in:
14
tests/unit/i18n.test.ts
Normal file
14
tests/unit/i18n.test.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
import { supportedLocales } from '@/lib/i18n'
|
||||
|
||||
describe('i18n', () => {
|
||||
it('supports en and de', () => {
|
||||
expect(supportedLocales).toContain('en')
|
||||
expect(supportedLocales).toContain('de')
|
||||
})
|
||||
it('has hero strings in both locales', async () => {
|
||||
const enHome = (await import('@/locales/en/home.json')).default as any
|
||||
const deHome = (await import('@/locales/de/home.json')).default as any
|
||||
expect(enHome.hero.headline1.title.length).toBeGreaterThan(10)
|
||||
expect(deHome.hero.headline1.title.length).toBeGreaterThan(10)
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user