twitchax / AspNetCore.Proxy

ASP.NET Core Proxies made easy.
MIT License
525 stars 83 forks source link

Add failing test for catchall proxying form data. #59

Closed PreferLinux closed 4 years ago

PreferLinux commented 4 years ago

As requested, this is a failing test for issue #57.

This is simply a copy of CanProxyControllerPostWithFormRequest() changed to send to "api/catchall/posts".

In this test (unlike what I mentioned in that issue) it does not hang and eventually timeout, but that is due to the server it is proxying to gracefully handling the empty request body. The problem can still be seen via something like Wireshark checking the request that actually gets sent, as it is empty. And as the request sent is empty, the response data doesn't contain the parameters we tried to send, and the test fails.

twitchax commented 4 years ago

Hell yeah: thanks, @PreferLinux. When I get some time, I will manually pull this and "fix" the test. :)