void () { // Inspired by IDEA-66583 getSettings().BLANK_LINES_AFTER_ANONYMOUS_CLASS_HEADER = 0; String textWithWhiteSpaceBetweenCommentAndLbrace = """ Object object = new Object() { // comment breaks "blank line after anonymous class header" @Override public String toString() { return super.toString(); } };"""; doMethodTest(textWithWhiteSpaceBetweenCommentAndLbrace, textWithWhiteSpaceBetweenCommentAndLbrace); String textWithoutWhiteSpaceBetweenCommentAndLbrace = """ Object object = new Object() {// comment breaks "blank line after anonymous class header" @Override public String toString() { return super.toString(); } };"""; doMethodTest(textWithoutWhiteSpaceBetweenCommentAndLbrace, textWithoutWhiteSpaceBetweenCommentAndLbrace); }