From 844966df89942e6a8efef493e37456b2bf8f51ba Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Deluan=20Quint=C3=A3o?= Date: Sat, 7 Jun 2025 23:11:13 -0400 Subject: [PATCH] test(ui): fix warnings (#4187) * fix(ui): address test warnings * ignore lint error in test Signed-off-by: Deluan --------- Signed-off-by: Deluan --- ui/src/audioplayer/AudioTitle.test.jsx | 7 ++++--- ui/src/dialogs/SaveQueueDialog.jsx | 5 ++++- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ui/src/audioplayer/AudioTitle.test.jsx b/ui/src/audioplayer/AudioTitle.test.jsx index c3f566f6b..7b297c07e 100644 --- a/ui/src/audioplayer/AudioTitle.test.jsx +++ b/ui/src/audioplayer/AudioTitle.test.jsx @@ -12,11 +12,12 @@ vi.mock('@material-ui/core', async () => { }) vi.mock('react-router-dom', () => ({ - Link: ({ to, children, ...props }) => ( - + // eslint-disable-next-line react/display-name + Link: React.forwardRef(({ to, children, ...props }, ref) => ( + {children} - ), + )), })) vi.mock('react-dnd', () => ({ diff --git a/ui/src/dialogs/SaveQueueDialog.jsx b/ui/src/dialogs/SaveQueueDialog.jsx index 69f07dab7..f916a0793 100644 --- a/ui/src/dialogs/SaveQueueDialog.jsx +++ b/ui/src/dialogs/SaveQueueDialog.jsx @@ -57,7 +57,10 @@ export const SaveQueueDialog = () => { return res }) .then((res) => { - notify('ra.notification.created', 'info', { smart_count: 1 }) + notify('ra.notification.created', { + type: 'info', + messageArgs: { smart_count: 1 }, + }) dispatch(closeSaveQueueDialog()) refresh() history.push(`/playlist/${res.data.id}/show`)