From 2338cad563446deec18c69fdb02c0d8636b81bd3 Mon Sep 17 00:00:00 2001 From: Kristina Date: Wed, 17 Apr 2024 08:17:51 -0500 Subject: [PATCH] Explore: Work on unskipping test (#86370) * test unskip * Mock getDataSourceSrv seperately * mock the hook instead * Remove TODO --- public/app/features/explore/spec/queryHistory.test.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/public/app/features/explore/spec/queryHistory.test.tsx b/public/app/features/explore/spec/queryHistory.test.tsx index a8e9cfd0acf..7ee48e8962c 100644 --- a/public/app/features/explore/spec/queryHistory.test.tsx +++ b/public/app/features/explore/spec/queryHistory.test.tsx @@ -68,6 +68,10 @@ jest.mock('app/core/services/PreferencesService', () => ({ }, })); +jest.mock('../hooks/useExplorePageTitle', () => ({ + useExplorePageTitle: jest.fn(), +})); + jest.mock('react-virtualized-auto-sizer', () => { return { __esModule: true, @@ -119,8 +123,7 @@ describe('Explore: Query History', () => { }); }); - // TODO: #86287 - it.skip('adds recently added query if the query history panel is already open', async () => { + it('adds recently added query if the query history panel is already open', async () => { const urlParams = { left: serializeStateToUrlParam({ datasource: 'loki',