From 8b57f6fdb1005f93a575ef12a47bc212d18e2238 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bart=C5=82omiej=20G=C5=82ownia?= Date: Mon, 21 Mar 2022 19:22:53 +0100 Subject: [PATCH] Fix RTL warnings --- .../src/lib/market-list-table.spec.tsx | 17 ++++++++++------- 1 file changed, 10 insertions(+), 7 deletions(-) diff --git a/libs/market-list/src/lib/market-list-table.spec.tsx b/libs/market-list/src/lib/market-list-table.spec.tsx index 7dde7a630..19d64ed6c 100644 --- a/libs/market-list/src/lib/market-list-table.spec.tsx +++ b/libs/market-list/src/lib/market-list-table.spec.tsx @@ -1,14 +1,17 @@ import { render } from '@testing-library/react'; +import { act } from 'react-dom/test-utils'; import { MockedProvider } from '@apollo/react-testing'; import MarketListTable from './market-list-table'; describe('MarketListTable', () => { - it('should render successfully', () => { - const { baseElement } = render( - - - - ); - expect(baseElement).toBeTruthy(); + it('should render successfully', async () => { + await act(async () => { + const { baseElement } = render( + + + + ); + expect(baseElement).toBeTruthy(); + }); }); });