File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -134,15 +134,15 @@ describe("Session", () => {
134134 await session . connectToMongoDB ( {
135135 connectionString : "mongodb://localhost:27017" ,
136136 } ) ;
137- expect ( await session . isSearchIndexSupported ( ) ) . toEqual ( true ) ;
137+ expect ( await session . isConnectedToMongot ) . toEqual ( true ) ;
138138 } ) ;
139139
140140 it ( "should return false if listing search indexes fail with search error" , async ( ) => {
141141 getSearchIndexesMock . mockRejectedValue ( new Error ( "SearchNotEnabled" ) ) ;
142142 await session . connectToMongoDB ( {
143143 connectionString : "mongodb://localhost:27017" ,
144144 } ) ;
145- expect ( await session . isSearchIndexSupported ( ) ) . toEqual ( false ) ;
145+ expect ( await session . isConnectedToMongot ) . toEqual ( false ) ;
146146 } ) ;
147147 } ) ;
148148} ) ;
Original file line number Diff line number Diff line change @@ -103,7 +103,7 @@ describe("debug resource", () => {
103103 } ) ;
104104
105105 it ( "should notify if a cluster supports search indexes" , async ( ) => {
106- session . isSearchIndexSupported = vi . fn ( ) . mockResolvedValue ( true ) ;
106+ vi . spyOn ( session , "isConnectedToMongot" , "get" ) . mockImplementation ( ( ) => Promise . resolve ( true ) ) ;
107107 debugResource . reduceApply ( "connect" , undefined ) ;
108108 const output = await debugResource . toOutput ( ) ;
109109
You can’t perform that action at this time.
0 commit comments