Skip to content

Commit

Permalink
Add status codes to mocked responses
Browse files Browse the repository at this point in the history
  • Loading branch information
imacrayon committed Jun 19, 2024
1 parent b4ae5cb commit 212b452
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,16 @@
)
}

// TODO: Add support for dynamic response status codes
console.log(`Mock Server Response:`, {
status: 200,
ok: true,
url,
text: body
})

return {
status: 200,
ok: true,
url,
text: () => Promise.resolve(body)
Expand Down

0 comments on commit 212b452

Please sign in to comment.