cdent / wsgi-intercept

Intercept socket connection to wsgi applications for testing
MIT License
42 stars 21 forks source link

Accept an empty string from a wsgi iterator #47

Closed cdent closed 7 years ago

cdent commented 7 years ago

This is allowed by the pep but the code was written such that if it received an empty string it would not get the rest of the iterator. This change fixes it so only None will cause the stop.

With this change an unrelated test wsgi app which was returning an empty string needed to be fixed to return a bytestring.

Fixes #46

cdent commented 7 years ago

@noonat If you could give this a glance and quick review that would be great.

noonat commented 7 years ago

@cdent Looks good to me. Thanks for the quick fix!