File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -124,7 +124,7 @@ describe('FlagsmithProvider', () => {
124
124
expect ( JSON . parse ( screen . getByTestId ( "flags" ) . innerHTML ) ) . toEqual ( removeIds ( defaultState . flags ) ) ;
125
125
} ) ;
126
126
} ) ;
127
- it ( 'handles race condition of init returning after identify ' , async ( ) => {
127
+ it ( 'ignores init response if identify gets called and resolves first ' , async ( ) => {
128
128
129
129
const onChange = jest . fn ( ) ;
130
130
const { flagsmith, initConfig, mockFetch} = getFlagsmith ( { onChange} )
@@ -135,7 +135,7 @@ describe('FlagsmithProvider', () => {
135
135
id : 1 ,
136
136
name : "hero"
137
137
}
138
- } ] , 300 ) // never resolves
138
+ } ] , 300 ) // resolves after flagsmith.identify, it should be ignored
139
139
140
140
render (
141
141
< FlagsmithProvider flagsmith = { flagsmith } options = { initConfig } >
You can’t perform that action at this time.
0 commit comments