Skip to content

Commit

Permalink
Issue #12099: Add ArchUnit test to ensure fields are modules and util…
Browse files Browse the repository at this point in the history
…s are immutable and modules are correctly annotated
  • Loading branch information
Vyom-Yadav committed Sep 1, 2022
1 parent 1b92ac8 commit 97405b9
Show file tree
Hide file tree
Showing 2 changed files with 421 additions and 1 deletion.
6 changes: 5 additions & 1 deletion config/pmd-test.xml
Expand Up @@ -119,7 +119,9 @@
from the test method.
In XdocsPagesTest PMD does not find asserts in lambdas.
All test classes which starts with XpathRegression have asserts inside parent's method.
In ArchUnitTest assertion calls are not required as they are called by the library -->
In ArchUnitTest assertion calls are not required as they are called by the library
In ImmutabilityTest assertion calls are not required as they are called
by the library -->
<property name="violationSuppressXPath"
value="//ClassOrInterfaceDeclaration[@SimpleName='AllChecksTest'
or @SimpleName='AstRegressionTest'
Expand All @@ -132,6 +134,8 @@
//MethodDeclaration[@Name='testAllCheckSectionJavaDocs']
| //ClassOrInterfaceDeclaration[starts-with(@SimpleName,'XpathRegression')]
//MethodDeclaration
| //ClassOrInterfaceDeclaration[@SimpleName='ImmutabilityTest']
//MethodDeclaration
| //ClassOrInterfaceDeclaration[@SimpleName='ArchUnitTest']
//MethodDeclaration"/>
</properties>
Expand Down

0 comments on commit 97405b9

Please sign in to comment.