@@ -146,7 +146,7 @@ describe('api', () => {
146146 describe ( 'bridge methods' , ( ) => {
147147 test ( 'throws when missing transformation.region' , ( ) => {
148148 //@ts -expect-error
149- expect ( ( ) => algoliasearch ( 'APP_ID' , 'API_KEY' , { transformation : { } } ) ) . toThrow (
149+ expect ( ( ) => algoliasearch ( 'APP_ID' , 'API_KEY' , { transformation : { } } ) ) . toThrow (
150150 '`region` must be provided when leveraging the transformation pipeline' ,
151151 ) ;
152152 } ) ;
@@ -158,19 +158,15 @@ describe('api', () => {
158158 objects : [ { objectID : 'bar' , baz : 42 } ] ,
159159 waitForTasks : true ,
160160 } ) ,
161- ) . rejects . toThrow (
162- '`transformation.region` must be provided at client instantiation before calling this method.' ,
163- ) ;
161+ ) . rejects . toThrow ( '`transformation.region` must be provided at client instantiation before calling this method.' ) ;
164162
165163 await expect (
166164 client . partialUpdateObjectsWithTransformation ( {
167165 indexName : 'foo' ,
168166 objects : [ { objectID : 'bar' , baz : 42 } ] ,
169167 waitForTasks : true ,
170168 } ) ,
171- ) . rejects . toThrow (
172- '`transformation.region` must be provided at client instantiation before calling this method.' ,
173- ) ;
169+ ) . rejects . toThrow ( '`transformation.region` must be provided at client instantiation before calling this method.' ) ;
174170 } ) ;
175171
176172 test ( 'exposes the transformation methods at the root of the client' , async ( ) => {
@@ -193,7 +189,7 @@ describe('api', () => {
193189 'x-algolia-api-key' : 'API_KEY' ,
194190 } ) ,
195191 ) ;
196- expect ( res . url . startsWith ( 'https://data.us.algolia.com/2/tasks /foo/push ?watch=true' ) ) . toBeTruthy ( ) ;
192+ expect ( res . url . startsWith ( 'https://data.us.algolia.com/1/push /foo?watch=true' ) ) . toBeTruthy ( ) ;
197193 expect ( res . data ) . toEqual ( {
198194 action : 'addObject' ,
199195 records : [
@@ -218,7 +214,7 @@ describe('api', () => {
218214 'x-algolia-api-key' : 'API_KEY' ,
219215 } ) ,
220216 ) ;
221- expect ( res . url . startsWith ( 'https://data.us.algolia.com/2/tasks /foo/push ?watch=true' ) ) . toBeTruthy ( ) ;
217+ expect ( res . url . startsWith ( 'https://data.us.algolia.com/1/push /foo?watch=true' ) ) . toBeTruthy ( ) ;
222218 expect ( res . data ) . toEqual ( {
223219 action : 'partialUpdateObject' ,
224220 records : [
@@ -241,7 +237,7 @@ describe('api', () => {
241237 'x-algolia-api-key' : 'API_KEY' ,
242238 } ) ,
243239 ) ;
244- expect ( res . url . startsWith ( 'https://data.us.algolia.com/2/tasks /foo/push ?watch=true' ) ) . toBeTruthy ( ) ;
240+ expect ( res . url . startsWith ( 'https://data.us.algolia.com/1/push /foo?watch=true' ) ) . toBeTruthy ( ) ;
245241 expect ( res . data ) . toEqual ( {
246242 action : 'partialUpdateObjectNoCreate' ,
247243 records : [
0 commit comments