@@ -321,7 +321,9 @@ describe("Sidebar Environment Variables", () => {
321
321
322
322
openConfigSection ( ) ;
323
323
324
- const timeoutInput = screen . getByTestId ( "MCP_SERVER_REQUEST_TIMEOUT-input" ) ;
324
+ const timeoutInput = screen . getByTestId (
325
+ "MCP_SERVER_REQUEST_TIMEOUT-input" ,
326
+ ) ;
325
327
fireEvent . change ( timeoutInput , { target : { value : "5000" } } ) ;
326
328
327
329
expect ( setConfig ) . toHaveBeenCalledWith ( {
@@ -338,7 +340,9 @@ describe("Sidebar Environment Variables", () => {
338
340
339
341
openConfigSection ( ) ;
340
342
341
- const timeoutInput = screen . getByTestId ( "MCP_SERVER_REQUEST_TIMEOUT-input" ) ;
343
+ const timeoutInput = screen . getByTestId (
344
+ "MCP_SERVER_REQUEST_TIMEOUT-input" ,
345
+ ) ;
342
346
fireEvent . change ( timeoutInput , { target : { value : "abc1" } } ) ;
343
347
344
348
expect ( setConfig ) . toHaveBeenCalledWith ( {
@@ -351,22 +355,35 @@ describe("Sidebar Environment Variables", () => {
351
355
352
356
it ( "should maintain configuration state after multiple updates" , ( ) => {
353
357
const setConfig = jest . fn ( ) ;
354
- const { rerender } = renderSidebar ( { config : DEFAULT_INSPECTOR_CONFIG , setConfig } ) ;
358
+ const { rerender } = renderSidebar ( {
359
+ config : DEFAULT_INSPECTOR_CONFIG ,
360
+ setConfig,
361
+ } ) ;
355
362
356
363
openConfigSection ( ) ;
357
364
358
365
// First update
359
- const timeoutInput = screen . getByTestId ( "MCP_SERVER_REQUEST_TIMEOUT-input" ) ;
366
+ const timeoutInput = screen . getByTestId (
367
+ "MCP_SERVER_REQUEST_TIMEOUT-input" ,
368
+ ) ;
360
369
fireEvent . change ( timeoutInput , { target : { value : "5000" } } ) ;
361
370
362
371
// Get the updated config from the first setConfig call
363
372
const updatedConfig = setConfig . mock . calls [ 0 ] [ 0 ] as InspectorConfig ;
364
373
365
374
// Rerender with the updated config
366
- rerender ( < Sidebar { ...defaultProps } config = { updatedConfig } setConfig = { setConfig } /> ) ;
375
+ rerender (
376
+ < Sidebar
377
+ { ...defaultProps }
378
+ config = { updatedConfig }
379
+ setConfig = { setConfig }
380
+ /> ,
381
+ ) ;
367
382
368
383
// Second update
369
- const updatedTimeoutInput = screen . getByTestId ( "MCP_SERVER_REQUEST_TIMEOUT-input" ) ;
384
+ const updatedTimeoutInput = screen . getByTestId (
385
+ "MCP_SERVER_REQUEST_TIMEOUT-input" ,
386
+ ) ;
370
387
fireEvent . change ( updatedTimeoutInput , { target : { value : "3000" } } ) ;
371
388
372
389
// Verify the final state matches what we expect
0 commit comments