dify/web/app/(commonLayout)/skills/__tests__/metadata.spec.ts
zxhlyh 667d66c4dc
fix(skills): align management UI accessibility and localization (#41180)
Co-authored-by: yyh <yuanyouhuilyz@gmail.com>
2026-08-25 01:53:19 +00:00

16 lines
528 B
TypeScript

import { describe, expect, it, vi } from 'vite-plus/test'
import { generateMetadata } from '../page'
vi.mock('server-only', () => ({}))
vi.mock('@/i18n-config/server', async (importOriginal) => ({
...(await importOriginal<typeof import('@/i18n-config/server')>()),
getLocaleOnServer: async () => 'en-US',
}))
describe('Skills route metadata', () => {
it('provides the localized document title for the Skills route', async () => {
await expect(generateMetadata()).resolves.toMatchObject({ title: 'Skills' })
})
})