Checks the year in the Version.
()
| 380 | * Checks the year in the {@link Version}. |
| 381 | */ |
| 382 | private void versionYear() throws IOException { |
| 383 | final List<String> lines = |
| 384 | FileUtils.readLines(new File("src/main/java/org/htmlunit/Version.java"), |
| 385 | SOURCE_ENCODING); |
| 386 | for (final String line : lines) { |
| 387 | if (line.contains("return \"Copyright (c) 2002-" + Calendar.getInstance(Locale.ROOT).get(Calendar.YEAR))) { |
| 388 | return; |
| 389 | } |
| 390 | } |
| 391 | addFailure("src/main/java/org/htmlunit/Version.java", 0, "Incorrect year in Version.getCopyright()"); |
| 392 | } |
| 393 | |
| 394 | /** |
| 395 | * Verifies no <parent> tag in {@code pom.xml}. |
no test coverage detected