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
IllegalArgumentException: Only Strings allowed in path parameters #1728
Comments
It happens with Spring Boot 3.1.4 as well, since that upgrades to rest assured 5.3.2. I changed the rest assured version to 5.3.1 and it works. If validating unnamed path params is intended for this use case, then the methods like
should be deprecated and we should use the calls with Map<String, Object> instead, right? |
Well the calls with Map<String, Object> seem to just call map.values().toArray(new Object[map.values().size()]) under the hood. At least through spring-mock-mvc RestAssuredMockMvc. So if you don't use an ordered Map you even end up with mumbled up parameters. Not to mention that the validation for "Only Strings allowed in path parameters." happens on both unnamed and named path parameters. So the Object based interfaces should be deprecated, because they seem to make no sense anymore. |
Any news? Theres 5.4.0 version and still unnamed parameters are not working. I also have this problem. I use Spring Boot 3.2.0. Rest assured in version 5.4.0 |
I tried to upgrade my Spring Boot 3.1/Java 17 example to Spring Boot 3.2-M2 and Java 21, the restassured-mock-mvc test failed.
The example project: https://github.com/hantsy/spring6-sandbox/tree/master/boot
The failed tests: https://github.com/hantsy/spring6-sandbox/blob/master/boot/src/test/java/com/example/demo/web/PostControllerTestWithRestAssuredMockMvc.java
The text was updated successfully, but these errors were encountered: