-
Notifications
You must be signed in to change notification settings - Fork 738
Request parameter with special character (plus) duplicated in request snippet #632
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
Comments
I have the same problem when the value is the empty string. |
@neubarth Thanks for the report. I've reproduced the problem. @marcgemis That doesn't sound like the same problem to me. The problem reported here is due to the |
This is, at least in part, a bug in REST Assured.
It's REST Assured that's taking the |
The problem does not occur when REST Assured is used directly rather than via its MockMVC integration. When used directly it results in a I've tried to find a workaround, for example by using @neubarth I think I've done all I can here. Please open a REST Assured issue and comment here with a link to it. I'm happy to help as needed and also to re-open this issue if my analysis turns out to be faulty. Lastly, please note the REST Docs does not, yet, officially support REST Assured 4.0. I'd actually missed it being released so thanks for bringing that to my attention. I've opened #635. |
When the value of a request parameter contains the plus sign (+), the parameter occurs twice in the generated snippet.
Example controller test:
Resulting snippet:
If i remove the + sign in
phoneNumber
, the snippet is correct, i.e. the parameter occurs only once.Versions used:
spring-restdocs-mockmvc : 2.0.3
rest-assured : 4.0.0
Spring Boot 2.1.5
The text was updated successfully, but these errors were encountered: