The framework should provide a testing client allowing to easily issue requests to the configured routes and handlers. In this light, let's introduce a Marten::HTTP::Client abstraction that would be responsible for that.
This new abstraction should allow to easily:
issue various HTTP requests
specify query parameters and data parameters
configure custom content types
use custom headers
To do
[x] Introduce a basic Marten::Spec::Client abstraction
[x] Ensure that an instance of this test client can be easily accessed via a Marten::Spec#client method
[x] Ensure that the test client is reset after each spec
[x] Update the documentation on how to test handlers and how to leverage the test client
Description
The framework should provide a testing client allowing to easily issue requests to the configured routes and handlers. In this light, let's introduce a
Marten::HTTP::Client
abstraction that would be responsible for that.This new abstraction should allow to easily:
To do
Marten::Spec::Client
abstractionMarten::Spec#client
method