Skip to content

Commit

Permalink
Updated PMD main rules (#2325)
Browse files Browse the repository at this point in the history
  • Loading branch information
Ben-Edwards-cgi authored Nov 27, 2024
1 parent 466480b commit b0a7c92
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ pmd {
pmdMain {
ruleSetFiles = files("config/pmd/main-ruleset.xml")
//Ensures we don't passively increase pmd errors but we should aim to reduce this
maxFailures = 1338
maxFailures = 605
}

pmdTestCommon {
Expand Down
4 changes: 3 additions & 1 deletion config/pmd/main-ruleset.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<rule ref="category/java/bestpractices.xml">
<exclude name="GuardLogStatement"/>
<exclude name="UnitTestContainsTooManyAsserts"/>
<exclude name="JUnitAssertionsShouldIncludeMessage"/>
<exclude name="UnitTestAssertionsShouldIncludeMessage"/>
<exclude name="UnitTestShouldIncludeAssert"/>
</rule>
<rule ref="category/java/codestyle.xml">
Expand All @@ -21,6 +21,7 @@
<exclude name="TooManyStaticImports"/>
<exclude name="CommentDefaultAccessModifier"/>
<exclude name="LinguisticNaming"/>
<exclude name="UseExplicitTypes"/>
</rule>
<rule ref="category/java/codestyle.xml/ClassNamingConventions">
<properties>
Expand Down Expand Up @@ -54,6 +55,7 @@
<rule ref="category/java/design.xml/LawOfDemeter">
<properties>
<property name="violationSuppressRegex" value="(.*method chain calls.*|.*object not created locally.*)"/>
<property name="trustRadius" value="2"/>
</properties>
</rule>
<rule ref="category/java/design.xml/SignatureDeclareThrowsException">
Expand Down

0 comments on commit b0a7c92

Please sign in to comment.