fix(test): include response body in error
This commit is contained in:
parent
7f5a08b316
commit
e43bac7fbc
|
|
@ -86,7 +86,8 @@ export class Factory {
|
|||
)
|
||||
|
||||
if (!response.ok()) {
|
||||
throw new Error(`Failed to seed data for table ${table}: ${response.status()} ${response.statusText()}`)
|
||||
const body = await response.json()
|
||||
throw new Error(`Failed to seed data for table ${table} (${response.status()}): ${body.message}`)
|
||||
}
|
||||
|
||||
return response.json()
|
||||
|
|
|
|||
Loading…
Reference in New Issue