fix(test): include response body in error

This commit is contained in:
kolaente 2025-11-28 16:48:08 +01:00
parent 7f5a08b316
commit e43bac7fbc
No known key found for this signature in database
GPG Key ID: F40E70337AB24C9B
1 changed files with 2 additions and 1 deletions

View File

@ -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()