From 3e6f9d3c6751b8afed5afb18f375a7f423b656a5 Mon Sep 17 00:00:00 2001 From: Martin Varmuza Date: Wed, 21 Jun 2023 16:43:10 +0200 Subject: [PATCH] test(suite): init db before test --- .../actions/wallet/__tests__/coinjoinClientActions.test.ts | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/packages/suite/src/actions/wallet/__tests__/coinjoinClientActions.test.ts b/packages/suite/src/actions/wallet/__tests__/coinjoinClientActions.test.ts index 22fe26db4a6..8a73d526a75 100644 --- a/packages/suite/src/actions/wallet/__tests__/coinjoinClientActions.test.ts +++ b/packages/suite/src/actions/wallet/__tests__/coinjoinClientActions.test.ts @@ -2,6 +2,7 @@ import { combineReducers, createReducer } from '@reduxjs/toolkit'; import { configureMockStore, testMocks } from '@suite-common/test-utils'; import { promiseAllSequence } from '@trezor/utils'; +import { db } from 'src/storage'; import { accountsReducer } from 'src/reducers/wallet'; import { coinjoinReducer } from 'src/reducers/wallet/coinjoinReducer'; import selectedAccountReducer from 'src/reducers/wallet/selectedAccountReducer'; @@ -87,6 +88,9 @@ describe('coinjoinClientActions', () => { afterEach(() => { jest.clearAllMocks(); }); + beforeAll(async () => { + await db.getDB(); + }); fixtures.onCoinjoinRoundChanged.forEach(f => { it(`onCoinjoinRoundChanged: ${f.description}`, async () => {