Skip to content

Latest commit

 

History

History
21 lines (14 loc) · 755 Bytes

File metadata and controls

21 lines (14 loc) · 755 Bytes

Test Java 8 explicit receiver parameters.

See blog post Explicit receiver parameters by Stephen Colebourne

Test with Checkstyle

Run mvn checkstyle:check

Result: Build fails, because parsing of Main.java fails.

Test with PMD

Run mvn pmd:check -Dpmd.verbose=true

Result: Build succeeds. But it shouldn't, because the empty if block is a PMD violation.

To demonstrate that the build should really fail:

  1. In Main.java comment out the Demo Block
  2. Run mvn pmd:check
  3. Result: The build fails because the empty if block is a PMD violation