RFR: 8283698: Refactor Locale constructors used in src/test

Joe Wang joehw at openjdk.java.net
Thu Apr 7 04:51:38 UTC 2022


On Thu, 7 Apr 2022 01:16:27 GMT, Naoto Sato <naoto at openjdk.org> wrote:

>> test/jdk/java/text/Format/DateFormat/DateFormatRoundTripTest.java line 81:
>> 
>>> 79: 
>>> 80:     /**
>>> 81:      * Parse a name like "fr_FR" into Locale.of("fr", "FR", "");
>> 
>> Locale.France?
>
> The test code parses the input string (eg. "fr_FR") into 3 elements, `name`, `country`, and `variant`, then create a `Locale` using those 3 elements. Changing it to `Locale.FRANCE` does not seem right here.

I see.

-------------

PR: https://git.openjdk.java.net/jdk/pull/8130


More information about the core-libs-dev mailing list