File tree Expand file tree Collapse file tree 1 file changed +1
-5
lines changed
src/components/UI/UserPicker Expand file tree Collapse file tree 1 file changed +1
-5
lines changed Original file line number Diff line number Diff line change @@ -8,7 +8,6 @@ jest.mock('axios');
8
8
9
9
describe ( 'UserPicker Component' , ( ) => {
10
10
const mockOnChange = jest . fn ( ) ;
11
- const mockBuildUrl = jest . fn ( ) ;
12
11
13
12
const mockUser = {
14
13
name : { value : 'John Doe' } ,
@@ -178,13 +177,10 @@ describe('UserPicker Component', () => {
178
177
} ) ;
179
178
} ) ;
180
179
181
- // Testing buildUrl with no search query
182
-
183
180
test ( 'builds URL correctly without search query' , async ( ) => {
184
181
render ( < UserPicker value = { mockUser } onChange = { mockOnChange } /> ) ;
185
182
const input = screen . getByRole ( 'textbox' ) ;
186
- fireEvent . change ( input , { target : { value : '' } } ) ;
187
- fireEvent . click ( input ) ;
183
+ fireEvent . change ( input , { target : { value : ' ' } } ) ;
188
184
189
185
await waitFor ( ( ) => {
190
186
expect ( axios . get ) . toHaveBeenCalledWith ( expect . stringContaining ( '^nameISNOTEMPTY' ) ) ;
You can’t perform that action at this time.
0 commit comments