From bcccf9e745d24b5f571c9c90774b06db847a2965 Mon Sep 17 00:00:00 2001 From: Moriz Wahl Date: Fri, 16 Jul 2021 16:37:38 +0200 Subject: [PATCH] add .locale to mocks --- .../views/Pages/AccountOverview/GddTransactionList.spec.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/frontend/src/views/Pages/AccountOverview/GddTransactionList.spec.js b/frontend/src/views/Pages/AccountOverview/GddTransactionList.spec.js index 34ba708ca..731ac6cdc 100644 --- a/frontend/src/views/Pages/AccountOverview/GddTransactionList.spec.js +++ b/frontend/src/views/Pages/AccountOverview/GddTransactionList.spec.js @@ -1,5 +1,6 @@ import { mount } from '@vue/test-utils' import GddTransactionList from './GddTransactionList' +import flushPromises from 'flush-promises' const localVue = global.localVue @@ -18,6 +19,9 @@ describe('GddTransactionList', () => { $n: jest.fn((n) => n), $t: jest.fn((t) => t), $d: jest.fn((d) => d), + $i18n: { + locale: () => 'en', + }, } const Wrapper = () => { @@ -81,6 +85,7 @@ describe('GddTransactionList', () => { ], transactionCount: 12, }) + await flushPromises() }) it('renders 4 transactions', () => {