Expose csvToJson test utils

This commit is contained in:
Adria Navarro 2024-08-02 10:55:20 +02:00
parent 8afb1e6c42
commit f3c18b87b1
1 changed files with 12 additions and 0 deletions

View File

@ -1,6 +1,8 @@
import {
BulkImportRequest,
BulkImportResponse,
CsvToJsonRequest,
CsvToJsonResponse,
MigrateRequest,
MigrateResponse,
Row,
@ -99,4 +101,14 @@ export class TableAPI extends TestAPI {
}
)
}
csvToJson = async (
body: CsvToJsonRequest,
expectations?: Expectations
): Promise<CsvToJsonResponse> => {
return await this._post<CsvToJsonResponse>(`/api/convert/csvToJson`, {
body,
expectations,
})
}
}