yohanboniface / pytest-falcon

Pytest helpers for testing Falcon applications
16 stars 6 forks source link

fix getting response body when stream is set #4

Closed stefan8 closed 8 years ago

stefan8 commented 8 years ago

Hi! Thanks for providing that helper in first place. I've found problem when app is settings stream on response instead of feeding data to body (falcon optimization). In that case falcon's _get_body returns iterator and this breaks handling body in fake_request method. Looks like it's simple solution for that.

yohanboniface commented 8 years ago

Good catch! And thanks for the PR :) Made one comment ;)

yohanboniface commented 8 years ago

Thanks a lot :)