File tree Expand file tree Collapse file tree 1 file changed +7
-3
lines changed
src/containers/shared/components/TokenSearchResults/test Expand file tree Collapse file tree 1 file changed +7
-3
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ import testTokens from './mock_data/tokens.json'
55import SocketContext from '../../../SocketContext'
66import SearchResults from '../TokenSearchResults'
77import MockWsClient from '../../../../test/mockWsClient'
8- import { QuickHarness } from '../../../../test/utils'
8+ import { QuickHarness , flushPromises } from '../../../../test/utils'
99
1010const testQuery = 'test'
1111
@@ -43,14 +43,18 @@ describe('Testing tokens search', () => {
4343 wrapper . unmount ( )
4444 } )
4545
46- it ( 'renders without crashing' , ( ) => {
46+ it ( 'renders without crashing' , async ( ) => {
47+ await flushPromises ( )
4748 wrapper . update ( )
49+
4850 const searchMenu = wrapper . find ( '.search-results-menu' )
4951 expect ( searchMenu . length ) . toEqual ( 1 )
5052 } )
5153
52- it ( 'renders all tokens ' , ( ) => {
54+ it ( 'renders all tokens ' , async ( ) => {
55+ await flushPromises ( )
5356 wrapper . update ( )
57+
5458 const searchMenu = wrapper . find ( '.search-results-menu' )
5559
5660 expect ( searchMenu . find ( '.search-results-header' ) . at ( 0 ) . html ( ) ) . toEqual (
You can’t perform that action at this time.
0 commit comments