LineLengthCheck extends SubscriptionVisitorCheck implements CharsetAwareVisitor { @VisibleForTesting void setMaximumLineLength(int maximumLineLength) { this.maximumLineLength = maximumLineLength; }  @Override List<Tree.Kind> nodesToVisit(); @Override void visitFile(Tree tree); @Override void setCharset(Charset charset);  }
@Test public void should_find_one_line_longer_than_50_characters_and_raise_an_issue() { check.setMaximumLineLength(50); JavaPropertiesCheckVerifier.issues(check, CheckTestUtils.getTestFile("lineLength.properties")) .next().atLine(3).withMessage("The line contains 51 characters which is greater than 50 authorized.") .next().atLine(6).withMessage("The line contains 51 characters which is greater than 50 authorized.") .noMore(); }