davydovanton/rspec-hanami

Request tests

beauby opened this issue · 4 comments

Any plan to support request tests with Hanami? (sequences of black-box request-response cycles going through the whole Hanami app including middlewares)

Hello @beauby, I open for any ideas and that's why yes, why not. Do you have any ideas how we can do it?

Here is a little helper I threw together last night: https://gist.github.com/beauby/fe02ecd48f68bcaa11033e08445af36f (I then heard about the Rack::Test gem, which does pretty much the same thing, but is not maintained anymore).

interesting. I'll try to implement this as soon as possible. Thanks!

Thanks, I created this. Now you can use request helpers in tests 🎉