On Mon, 7 Mar 2022 21:26:56 GMT, Rajan Halade <[email protected]> wrote:
>> Sean Mullan has updated the pull request incrementally with one additional
>> commit since the last revision:
>>
>> Merge Wildcard test into TestHostnameCheck.
>> Rename HostnameMatcher dir to HostnameChecker.
>
> test/jdk/sun/security/util/HostnameChecker/Wildcard.java line 72:
>
>> 70: } catch (Exception e) {
>> 71: if (expected) {
>> 72: throw new Exception("unexpectedly failed match", e);
>
> consider to update these to RuntimeException
What are the benefits of throwing `RuntimeException` instead of `Exception`? In
the latest commit, I have merged the `Wildcard.java` test into
`TestHostnameChecker.java` test which already throws `Exception` on failures.
-------------
PR: https://git.openjdk.java.net/jdk/pull/7697