Skip to content

Commit

Permalink
build: upgrade to PMD 7.7
Browse files Browse the repository at this point in the history
  • Loading branch information
rubenporras committed Oct 29, 2024
1 parent 73971a3 commit 0f81008
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 10 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/verify.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
uses: pmd/[email protected]
id: pmd
with:
version: '7.5.0'
version: '7.7.0'
rulesets: 'ddk-configuration/pmd/ruleset.xml'
analyzeModifiedFilesOnly: false
- name: Fail build if there are violations
Expand Down
17 changes: 9 additions & 8 deletions ddk-configuration/pmd/ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,15 +73,16 @@
<exclude name="AccessorMethodGeneration"/>
<exclude name="AvoidReassigningParameters"/>
<exclude name="UnusedPrivateMethod"/><!-- false positives-->
<exclude name="DefaultLabelNotLastInSwitchStmt"/>
<exclude name="DefaultLabelNotLastInSwitch"/>
<exclude name="ForLoopCanBeForeach"/>
<exclude name="GuardLogStatement"/><!--TODO-->
<exclude name="JUnitTestContainsTooManyAsserts"/><!--New after PMD 5.3 upgrade, limitation to 1 assert not sensible, would need customization, disabled for the time being-->
<exclude name="JUnitTestsShouldIncludeAssert"/>
<exclude name="JUnit4TestShouldUseAfterAnnotation"/><!--Checkstyle-->
<exclude name="JUnit4TestShouldUseBeforeAnnotation"/><!--Checkstyle-->
<exclude name="JUnit4TestShouldUseTestAnnotation"/>
<exclude name="SwitchStmtsShouldHaveDefault"/>
<exclude name="UnitTestAssertionsShouldIncludeMessage"/>
<exclude name="UnitTestContainsTooManyAsserts"/><!--New after PMD 5.3 upgrade, limitation to 1 assert not sensible, would need customization, disabled for the time being-->
<exclude name="UnitTestShouldIncludeAssert"/>
<exclude name="UnitTestShouldUseAfterAnnotation"/><!--Checkstyle-->
<exclude name="UnitTestShouldUseBeforeAnnotation"/><!--Checkstyle-->
<exclude name="UnitTestShouldUseTestAnnotation"/>
<exclude name="NonExhaustiveSwitch"/>
<exclude name="PreserveStackTrace"/><!--TODO-->
<exclude name="UnusedLocalVariable"/><!--Checkstyle-->
<exclude name="UseTryWithResources"/><!--TODO-->
Expand Down Expand Up @@ -125,7 +126,7 @@
<exclude name="ConsecutiveLiteralAppends"/>
<exclude name="OptimizableToArrayCall"/>
<exclude name="RedundantFieldInitializer"/><!--Checkstyle-->
<exclude name="TooFewBranchesForASwitchStatement"/>
<exclude name="TooFewBranchesForSwitch"/>
</rule>

</ruleset>
2 changes: 1 addition & 1 deletion ddk-parent/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@
<spotbugs.plugin.version>4.8.6.4</spotbugs.plugin.version>
<spotbugs.version>4.8.6</spotbugs.version>
<pmd.plugin.version>3.25.0</pmd.plugin.version>
<pmd.version>7.6.0</pmd.version>
<pmd.version>7.7.0</pmd.version>
<tycho.version>4.0.9</tycho.version>
<xtend.version>2.36.0</xtend.version>
</properties>
Expand Down

0 comments on commit 0f81008

Please sign in to comment.