File tree Expand file tree Collapse file tree
packages/solid-query-devtools/src/__tests__ Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,6 +35,29 @@ describe('SolidQueryDevtools', () => {
3535 ) . not . toThrow ( )
3636 } )
3737
38+ it ( 'should forward "buttonPosition" to the devtools instance' , ( ) => {
39+ const setButtonPosition = vi . spyOn (
40+ TanstackQueryDevtools . prototype ,
41+ 'setButtonPosition' ,
42+ )
43+ const queryClient = new QueryClient ( )
44+
45+ render ( ( ) => (
46+ < SolidQueryDevtools client = { queryClient } buttonPosition = "top-left" />
47+ ) )
48+
49+ expect ( setButtonPosition ) . toHaveBeenCalledWith ( 'top-left' )
50+ } )
51+
52+ it ( 'should forward "position" to the devtools instance' , ( ) => {
53+ const setPosition = vi . spyOn ( TanstackQueryDevtools . prototype , 'setPosition' )
54+ const queryClient = new QueryClient ( )
55+
56+ render ( ( ) => < SolidQueryDevtools client = { queryClient } position = "left" /> )
57+
58+ expect ( setPosition ) . toHaveBeenCalledWith ( 'left' )
59+ } )
60+
3861 it ( 'should forward "initialIsOpen" to the devtools instance' , ( ) => {
3962 const setInitialIsOpen = vi . spyOn (
4063 TanstackQueryDevtools . prototype ,
You can’t perform that action at this time.
0 commit comments