-
Notifications
You must be signed in to change notification settings - Fork 553
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
convert query values to strings before comparison #517
base: master
Are you sure you want to change the base?
convert query values to strings before comparison #517
Conversation
b1cb946
to
6e334ae
Compare
Some things I am still working on/figuring out:
|
fa4583c
to
5287372
Compare
@Fire-Dragon-DoL you want to take a look and see if this fixes your problem, or add any other feedback? |
@presidentJFK I can't test against my code because it doesn't exist anymore (we changed it a lot), but by reviewing your PR it definitely looks like it fixes it entirely. |
c879f2e
to
8d30ccf
Compare
It looks like this doesn't solve your original problem with hash_including, so I am giving this another look. |
Mhhh that's weird, handling the hash as string-values only on "both sides" of the hash_including, should work |
this commit refactors out a new private class method .convert_query_string_into_array from the .values_to_query method in WebMock::Util::QueryMapper
rename private class method convert_query_string_into_array => .convert_query_hash_to_array
3caeea8
to
9fb40fc
Compare
This change updates so the expected request and actual request, are compared to as strings, when using hash_including
9fb40fc
to
08a3a4a
Compare
I made a couple mistakes when trying to fix this. I thought a simple one time stringify in the QueryMapper would fix the original issue. But the problem with my original fix was it didn't take into account the HashIncludingMatcher. which handles its own comparision with #==, and was not converting the values to strings before comparing. I have added the first spec you originally posted to the test suite, which exercises this exact functionality. I now just have to clean up some changes I made, move specs to the right place, and double check |
No description provided.