MockHttpServletRequest.addHeader fails for invalid LanguageRange in Accept-Language [SPR-16454] #20999
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: regression
A bug that is also a regression
Milestone
Manuel Jordan opened SPR-16454 and commented
I have a Spring Project
4.3.10.RELEASE
, MVC and Rest are tested (working with JUnit 4).In some scenarios the
Accept-Language
header is applied. Until here all work fine.I have created other project working with Spring Project
5.0.3.RELEASE
, practically the same infrastructure is used, but all the Test classes have migrated to JUnit 5. Remember the business and infrastructure code remains the same.When I test MVC it fails with the following error message:
What is strange is
range=en_us
, theLocale
is created in this way within an enumnew Locale("en","US")
.The Rest Test classes fails with:
Sadly the error message is not useful
Note I get the same error messages if for the first project I create a new branch through Git and use Spring updated to
5.0.3.RELEASE
.Thus not sure if it is bug or something extra about configuration is mandatory now. I am confused
Thanks
Affects: 5.0 GA, 5.0.3
Issue Links:
Referenced from: commits b3e21ec
The text was updated successfully, but these errors were encountered: