mirror of
https://github.com/jxxghp/MoviePilot-Frontend.git
synced 2026-09-04 23:18:44 +08:00
fix tests
This commit is contained in:
@@ -10,6 +10,9 @@ describe('MediaInfoCard', () => {
|
||||
context: {
|
||||
meta_info: {
|
||||
artists: ['周杰伦'],
|
||||
audio_format: 'FLAC',
|
||||
bit_depth: 24,
|
||||
sample_rate: 48000,
|
||||
title: '晴天',
|
||||
type: '音乐',
|
||||
},
|
||||
@@ -23,6 +26,8 @@ describe('MediaInfoCard', () => {
|
||||
})
|
||||
|
||||
expect(screen.getByText('晴天')).toBeInTheDocument()
|
||||
expect(screen.getByText('FLAC')).toBeInTheDocument()
|
||||
expect(screen.getByText('24 kHz 48000')).toBeInTheDocument()
|
||||
expect(screen.queryByText('识别失败,无法识别到有效信息!')).not.toBeInTheDocument()
|
||||
})
|
||||
|
||||
|
||||
@@ -319,7 +319,9 @@ onMounted(() => {
|
||||
v-model="mediaId"
|
||||
:label="mediaIdLabel"
|
||||
:placeholder="t('dialog.reorganize.mediaIdPlaceholder')"
|
||||
:rules="[(value: any) => isValidMediaSourceId(value, mediaSource.value) || t('dialog.reorganize.mediaIdInvalid')]"
|
||||
:rules="[
|
||||
(value: any) => isValidMediaSourceId(value, mediaSource) || t('dialog.reorganize.mediaIdInvalid'),
|
||||
]"
|
||||
append-inner-icon="mdi-magnify"
|
||||
:hint="t('dialog.reorganize.mediaIdHint')"
|
||||
persistent-hint
|
||||
|
||||
@@ -443,7 +443,8 @@ describe('SiteResourceDialog', () => {
|
||||
await waitFor(() => expect(screen.queryByLabelText('搜索关键字')).not.toBeInTheDocument())
|
||||
})
|
||||
|
||||
it('emits close and formats the result summary in English', async () => {
|
||||
it('emits close and formats the mobile result summary in English', async () => {
|
||||
setViewport(390)
|
||||
server.use(
|
||||
siteCategoriesHandler(501, []),
|
||||
siteResourcesHandler(501, [createTorrentInfo({ title: 'Language resource' })]),
|
||||
|
||||
Reference in New Issue
Block a user