Closed ayato-p closed 8 years ago
Could you include a test case which shows why this is needed please?
Thanks, I will try it.
I just add one example test case. Please check it out. Thank you.
Does that test fail without the changes to the code you made? I'm sorry - I'm not quite following what the original issue is.
Does that test fail without the changes to the code you made?
Yes.
Sorry, I will explain original issue.
When URL include query parameters (like http://example.com/post?foo=1&bar=2
) and HTML form does not have action attribute.
And then emulate submit via Kerodon's press
function, so Kerodon will create POST URL by kerodon.impl/build-url
from request.
So in this case, Kerodon creates broken URL like http://example.com/postfoo=1&bar=2
(without ?
for separator), and then I can see 404 error.
I just fixed broken function
build-url
.Now, almost same as
peridot.request/url
(difference is just key of args). https://github.com/xeqi/peridot/blob/master/src/peridot/request.clj#L68-L77