elm / http

Make HTTP requests in Elm
https://package.elm-lang.org/packages/elm/http/latest
BSD 3-Clause "New" or "Revised" License
155 stars 46 forks source link

Add "ignoreResponseBody" expectation. #35

Closed jonnyarnold closed 6 years ago

jonnyarnold commented 6 years ago

Based on #12, it's not obvious how to deal with empty response bodies.

I've added a new expectation to the Expect zoo which can be used to ignore a request body. This was do-able with expectString, but wasn't obvious and didn't have a representative type signature.

While doing this, I had a few questions:

Thanks for reading!

process-bot commented 6 years ago

Thanks for the pull request! Make sure it satisfies this checklist. My human colleagues will appreciate it!

Here is what to expect next, and if anyone wants to comment, keep these things in mind.

zwilias commented 6 years ago

I'd like to point out that this expectation exists in lukewestby/http-extra and is also implicitly used in lukewestby/elm-http-builder.

(Just presenting these as factual information relevant to the PR, not expressing an opinion on whether or not this makes sense to have in core)

jonnyarnold commented 6 years ago

@zwilias I didn't know about these packages - thanks :)