Migrate RowAPI.search
This commit is contained in:
parent
c0907d37ef
commit
f91db6d985
|
@ -134,14 +134,11 @@ export class RowAPI extends TestAPI {
|
||||||
search = async (
|
search = async (
|
||||||
sourceId: string,
|
sourceId: string,
|
||||||
params?: SearchParams,
|
params?: SearchParams,
|
||||||
{ expectStatus } = { expectStatus: 200 }
|
expectations?: Expectations
|
||||||
): Promise<SearchRowResponse> => {
|
): Promise<SearchRowResponse> => {
|
||||||
const request = this.request
|
return await this._post<SearchRowResponse>(`/api/${sourceId}/search`, {
|
||||||
.post(`/api/${sourceId}/search`)
|
body: params,
|
||||||
.send(params)
|
expectations,
|
||||||
.set(this.config.defaultHeaders())
|
})
|
||||||
.expect(expectStatus)
|
|
||||||
|
|
||||||
return (await request).body
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue