RFR: 8294989: ResourceBundle naming convention issue in JdbcRowSetResourceBundle.java [v8]

Justin Lu duke at openjdk.org
Fri Oct 21 19:00:12 UTC 2022


On Fri, 21 Oct 2022 18:04:29 GMT, Lance Andersen <lancea at openjdk.org> wrote:

>> Justin Lu has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Pass exception to constuctor directly
>
> test/jdk/javax/sql/testng/test/rowset/ValidateResourceBundleAccess.java line 63:
> 
>> 61:             // Unexpected case where exception is not forced
>> 62:             throw new RuntimeException(
>> 63:                     String.format("$$$ Error: SQLException was not caught!%n"));
> 
> As you are not passing any parameters, this can just be a String omitting the "%n"
> 
> Also, it would tweak the String to be "Expected SQLException.... thrown"

Will adjust the exception message

> test/jdk/javax/sql/testng/test/rowset/ValidateResourceBundleAccess.java line 72:
> 
>> 70:             // Unexpected case where exception is not forced
>> 71:             throw new RuntimeException(
>> 72:                     String.format("$$$ Error: SQLException was not caught!%n"));
> 
> Same comment about not needing to use String.format.
> 
> Also, it would tweak the String to be "Expected SQLException.... thrown"

Good point, Naoto actually recommended the same with the .format(), but I thought that I should preserve the newline.

Like you said %n should not be needed, will make the fix.

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

PR: https://git.openjdk.org/jdk/pull/10612


More information about the core-libs-dev mailing list