Skip to content

Commit

Permalink
Update error
Browse files Browse the repository at this point in the history
  • Loading branch information
Nicole White committed Mar 10, 2024
1 parent a59a8f8 commit 4af7066
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions src/handlers/testing/exec/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,11 @@ class RunManager {
Authorization: `Bearer ${this.apiKey}`,
},
});
const data = await resp.json();
if (!resp.ok) {
throw new Error(
`POST ${path} failed: ${resp.status} ${await resp.text()}`,
);
throw new Error(`POST ${subpath}${path} failed: ${JSON.stringify(data)}`);
}
return resp.json();
return data;
}

private get isCI(): boolean {
Expand Down

0 comments on commit 4af7066

Please sign in to comment.