Skip to content

Commit 379c202

Browse files
committed
test(request): fix hoisted l10n mock on stable32
Signed-off-by: Vitor Mattos <1079143+vitormattos@users.noreply.github.com>
1 parent b743985 commit 379c202

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/tests/views/Request.spec.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,6 @@
44
*/
55

66
import { beforeEach, describe, expect, it, vi } from 'vitest'
7-
import { createL10nMock } from '../testHelpers/l10n.js'
87
import { mount } from '@vue/test-utils'
98

109
import Request from '../../views/Request.vue'
@@ -19,7 +18,10 @@ const sidebarStoreMock = {
1918
isVisible: false,
2019
}
2120

22-
vi.mock('@nextcloud/l10n', () => createL10nMock())
21+
vi.mock('@nextcloud/l10n', async () => {
22+
const { createL10nMock } = await import('../testHelpers/l10n.js')
23+
return createL10nMock()
24+
})
2325

2426
vi.mock('../../store/files.js', () => ({
2527
useFilesStore: vi.fn(() => filesStoreMock),

0 commit comments

Comments
 (0)