-
Notifications
You must be signed in to change notification settings - Fork 1.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix HttpGet protocol for WebService #1232
Conversation
Current coverage is
|
Thanks! Will try to review it today! |
var queryParameters = new StringBuilder(); | ||
string separator = string.Empty; | ||
int i = 0; | ||
foreach (MethodCallParameter parameter in this.Parameters) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, but I think for
is better if we already need an i
. Do you agree?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Completely agree. I copied the logic from the PrepareHttpRequest
method and did not notice Parameters
was an IList<>
Hi, added some small comments.
If we looks at the code cov, we see some yellow and red. It would be nice if we add a new unit test, or expand the current unit test, so everything is covered (green).
It seems that |
queryParameters.Append(separator); | ||
queryParameters.Append(parameter.Name); | ||
queryParameters.Append("="); | ||
queryParameters.Append(UrlHelper.UrlEncode(Convert.ToString(parameterValues[i], CultureInfo.InvariantCulture), true)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
spaceAsPlus should be false
I tried to fix the different issues. Appveyor build is passing on my repo so i don't really know why it's failing here. |
That's an unstable test. Will try a rebuild |
Fix HttpGet protocol for WebService
Cool! It has been merged. Thanks! |
Also thanks for nice communication, like the |
My pleasure :) |
Fixes #701
Reenables the
WebserviceTest_restapi_httpget
unit test, not sure if other tests are needed.Not sure either if the
spaceAsPlus
parameter for theUrlHelper.UrlEncode()
should be true or falseThis change is