On Wed, 27 Jan 2021 22:44:00 GMT, Mahendra Chhipa 
<github.com+34924738+mahendrachh...@openjdk.org> wrote:

>> https://bugs.openjdk.java.net/browse/JDK-8183372
>
> Mahendra Chhipa has updated the pull request incrementally with one 
> additional commit since the last revision:
> 
>   Implemented the review comments.

Changes requested by bchristi (Reviewer).

test/jdk/java/lang/Class/getEnclosingClass/EnclosingClassTest.java line 157:

> 155: 
> 156:     private void match(final String actual, final String expected) {
> 157:         System.out.println("actual:" + actual + "expected:" + expected);

It would be good to insert a space before `expected:`

test/jdk/java/lang/Class/getEnclosingClass/EnclosingClassTest.java line 158:

> 156:     private void match(final String actual, final String expected) {
> 157:         System.out.println("actual:" + actual + "expected:" + expected);
> 158:         assert ((actual == null && expected == null) || 
> actual.equals(expected.trim()));

I think we need to figure out where the extra space is coming from, if the test 
worked before, but now fails without adding the `trim()`.

Also, I think it would be better to throw an exception instead of using 
`assert`, so the test works with or without assertions being enabled.

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

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

Reply via email to