Bypass provides a quick way to create a custom plug that can be put in place instead of an actual HTTP server to return prebaked responses to client requests.
Hi there,
I want to propose a modify for the following method: expect and expect_once.
Because I find not so easy and clear do an assertion on headers request.
For example, I use this method to check the request header during my last work.
Hi there, I want to propose a modify for the following method:
expect
andexpect_once
. Because I find not so easy and clear do an assertion on headers request. For example, I use this method to check the request header during my last work.I think that a method like this is more useful and clear:
functions:
expect(bypass, method, path, headers, fun)
expect_once(bypass, method, path, headers, fun)
headers
is a list of the tuple and the function check if every tuple in the list is present in the request.I want to listen to your opinion about this pr proposal. In case you agree, I would be happy to do it! 😃