forked from checkstyle/checkstyle
-
Notifications
You must be signed in to change notification settings - Fork 0
/
suppressions.xml
179 lines (150 loc) · 10.3 KB
/
suppressions.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
<?xml version="1.0"?>
<!DOCTYPE suppressions PUBLIC
"-//Puppy Crawl//DTD Suppressions 1.1//EN"
"http://www.puppycrawl.com/dtds/suppressions_1_1.dtd">
<suppressions>
<suppress checks="FileLength"
files="TokenTypes.java"
lines="1"/>
<!-- There is no other way to deliver filename that was under processing.
See https://github.com/checkstyle/checkstyle/issues/2285-->
<suppress checks="IllegalCatch"
files="Checker.java"
lines="278"/>
<suppress checks="IllegalCatch"
files="Checker.java"
lines="388"/>
<!--Test to reproduce error catching in Checker and satisfy coverage rate. -->
<suppress checks="IllegalCatch"
files="CheckerTest.java"
lines="576"/>
<!-- we can not change it as, Check name is part of API (used in configurations) -->
<suppress checks="AbbreviationAsWordInName"
files="JavaNCSSCheck.java"
lines="41"/>
<!-- test should be named as their main class -->
<suppress checks="AbbreviationAsWordInName"
files="JavaNCSSCheckTest.java"
lines="42"/>
<!-- we can not change it as, Check name is part of API (used in configurations) -->
<suppress checks="AbbreviationAsWordInName"
files="XMLLogger.java"
lines="44"/>
<!-- test should be named as their main class -->
<suppress checks="AbbreviationAsWordInName"
files="XMLLoggerTest.java"
lines="48"/>
<!-- we can not change it as, Check property is part of API (used in configurations) -->
<suppress checks="AbbreviationAsWordInName"
files="JavadocMethodCheck.java"
lines="146,252"/>
<!-- we can not change it as, Check property is part of API (used in configurations) -->
<suppress checks="AbbreviationAsWordInName"
files="SuppressWithNearbyCommentFilter.java"
lines="97,183"/>
<!-- we can not change it as, Check property is part of API (used in configurations) -->
<suppress checks="AbbreviationAsWordInName"
files="SuppressionCommentFilter.java"
lines="85,172"/>
<!-- should be removed at 7.0 version, we keep for some time to avoid braking compatibiilty -->
<suppress checks="AbbreviationAsWordInName"
files="CheckstyleAntTask.java"
lines="230"/>
<!-- should be removed at 7.0 version, we keep for some time to avoid braking compatibiilty -->
<suppress checks="AbbreviationAsWordInName"
files="AbstractComplexityCheck.java"
lines="65"/>
<!-- illegal words are part of Javadoc -->
<suppress checks="TodoComment" files=".*TodoCommentCheck\.java"/>
<!-- All disallowed characters are stored there -->
<suppress checks="AvoidEscapedUnicodeCharactersCheck"
files="AvoidEscapedUnicodeCharactersCheck.java"/>
<!-- Can not change API -->
<suppress checks="AbstractClassNameCheck"
files="Check.java"/>
<!-- 'Abstract' pattern is used to show it is checking for abstract class name -->
<suppress checks="AbstractClassNameCheck"
files="AbstractClassNameCheck.java"/>
<!-- test should be named as their main class -->
<suppress checks="AbstractClassNameCheck"
files="AbstractCheckTest.java|AbstractClassNameCheckTest.java|AbstractTypeAwareCheckTest.java|AbstractJavadocCheckTest.java|AbstractViolationReporterTest.java"/>
<!-- Tone down the checking for test code -->
<suppress checks="CyclomaticComplexity" files="[\\/]XDocsPagesTest\.java"/>
<suppress checks="IllegalCatch" files="[\\/]internal[\\/]\w+Util\.java"/>
<suppress checks="EmptyBlock" files=".*[\\/]src[\\/]test[\\/]"/>
<suppress checks="ImportControl" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<suppress checks="Javadoc" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<suppress checks="MagicNumber" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<suppress checks="AvoidStaticImport" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<suppress checks="MethodCount" files="[\\/]ImportOrderCheckTest.java$"/>
<suppress checks="MethodCount" files="[\\/]IndentationCheckTest.java$"/>
<suppress checks="ClassDataAbstractionCoupling" files="[\\/]IndentationCheckTest.java$"/>
<suppress checks="MethodCount" files="[\\/]JavadocMethodCheckTest.java$"/>
<suppress checks="MethodCount" files="[\\/]MainTest.java$"/>
<suppress checks="EqualsAvoidNull" files="[\\/]Int.*FilterTest.java$"/>
<suppress checks="VisibilityModifier" files="[\\/]BaseCheckTestSupport.java$"/>
<suppress checks="WriteTag" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<!--The Check generates too many violations, fixing them will make code unmanageable.-->
<suppress checks="MagicNumber" files="(ParseTreeTablePModel|MainFrame)\.java"/>
<!-- Methods that build fake AST are very long-->
<suppress checks="MethodLength" files="src[\\/]test[\\/]java[\\/]com[\\/]puppycrawl[\\/]tools[\\/]checkstyle[\\/]grammars[\\/]comments[\\/]CommentsTest\.java"/>
<suppress checks="ExecutableStatementCount" files="src[\\/]test[\\/]java[\\/]com[\\/]puppycrawl[\\/]tools[\\/]checkstyle[\\/]grammars[\\/]comments[\\/]CommentsTest\.java"/>
<suppress checks="JavaNCSS" files="src[\\/]test[\\/]java[\\/]com[\\/]puppycrawl[\\/]tools[\\/]checkstyle[\\/]grammars[\\/]comments[\\/]CommentsTest\.java"/>
<suppress checks="MethodLength" files=".*GeneratedJavaTokenTypesTest\.java"/>
<suppress checks="ExecutableStatementCount" files=".*GeneratedJavaTokenTypesTest\.java"/>
<suppress checks="JavaNCSS" files=".*GeneratedJavaTokenTypesTest\.java"/>
<suppress checks="." files=".*JavadocTokenTypes\.java"/>
<suppress checks="." files=".*ParseTreeBuilder\.java"/>
<!-- Till https://github.com/checkstyle/checkstyle/issues/1854 -->
<suppress checks="TrailingComment" files="(InnerAssignmentCheck\.java|OperatorWrapCheck\.java|XMLLoggerTest\.java|AbbreviationAsWordInNameCheckTest\.java)"/>
<!-- Fixing these cases will decrease code readability -->
<suppress checks="MultipleStringLiterals" files="JavadocStyleCheck\.java|AbstractTypeAwareCheck\.java|XMLLogger\.java"/>
<suppress checks="MultipleStringLiterals" files=".*[\\/]src[\\/](test|it)[\\/]"/>
<!-- There are a lot of setters/getters in the Check. A small number of methods is left for Check's logic -->
<suppress checks="MethodCount" files="[\\/]JavadocMethodCheck.java$"/>
<!-- Apart from a complex logic there is a lot of small methods for a better readability. -->
<suppress checks="MethodCount" files="[\\/]CommentsIndentationCheck.java$"/>
<!--VisibilityModifierCheck has 7 options which require 7 additional methods (setters)-->
<suppress checks="MethodCount" files="[\\/]VisibilityModifierCheck.java$"/>
<!-- getDetails() method - huge Switch, it has to be monolithic -->
<suppress checks="ExecutableStatementCount" files="RightCurlyCheck\.java" lines="313"/>
<suppress checks="JavaNCSS" files="RightCurlyCheck\.java" lines="313"/>
<suppress checks="CyclomaticComplexity" files="RightCurlyCheck\.java" lines="313"/>
<!-- we need that set of converters -->
<suppress checks="ClassDataAbstractionCoupling" files="AutomaticBean\.java"/>
<!-- they are aggregators of logic, usage a several of classes are ok -->
<suppress checks="ClassDataAbstractionCoupling" files="(Checker|TreeWalker|Main|CheckstyleAntTask|JavadocDetailNodeParser)\.java"/>
<suppress checks="ClassDataAbstractionCoupling" files="(CheckerTest|TreeWalkerTest|BaseCheckTestSupport|XDocsPagesTest|CheckstyleAntTaskTest)\.java"/>
<suppress checks="ClassDataAbstractionCoupling" files="PropertyCacheFile\.java"/>
<!-- a lot of GUI elements is OK -->
<suppress checks="ClassDataAbstractionCoupling" files="(JTreeTable|MainFrame)\.java"/>
<!-- Should be fixed after moving https://github.com/sevntu-checkstyle/sevntu.checkstyle/blob/master/sevntu-checks/src/main/java/com/github/sevntu/checkstyle/checks/coding/ReturnCountExtendedCheck.java into the main repo -->
<suppress checks="ReturnCount" files="(ClassResolver|ConfigurationLoader|IndentationCheckTest)\.java"/>
<!-- Just big switches. Cannot be split to several methods. Till https://github.com/checkstyle/checkstyle/issues/2029 -->
<suppress checks="CyclomaticComplexity" files="(AbstractDeclarationCollector|RequireThisCheck|SuppressWarningsHolder|LeftCurlyCheck|FallThroughCheck|FinalLocalVariableCheck|ModifiedControlVariableCheck)\.java"/>
<suppress checks="CyclomaticComplexity" files="(ParameterAssignmentCheck|VariableDeclarationUsageDistanceCheck|BooleanExpressionComplexityCheck|NPathComplexityCheck|CheckUtils)\.java"/>
<!-- Suppressions from PMD configuration-->
<!-- validateCli is not reasonable to split as encapsulation of logic will be damaged -->
<suppress checks="CyclomaticComplexity" files="Main\.java" lines="212"/>
<!-- JavadocMethodCheck, JavadocStyleCheck, JavadocUtils.getJavadocTags() - deprecated -->
<suppress checks="CyclomaticComplexity" files="JavadocMethodCheck\.java"/>
<suppress checks="CyclomaticComplexity" files="JavadocStyleCheck\.java"/>
<suppress checks="CyclomaticComplexity" files="CustomImportOrderCheck\.java"/>
<!-- equals() - a lot of fields to check -->
<suppress checks="CyclomaticComplexity" files="LocalizedMessage\.java" lines="210"/>
<!-- SWITCH was transformed into IF-ELSE -->
<suppress checks="CyclomaticComplexity" files="ImportOrderCheck\.java" lines="357"/>
<!-- Just big SWITCH block which contains IF blocks in 'visitToken'.
If we split the block to several methods it will demage readibility. -->
<suppress checks="CyclomaticComplexity" files="DeclarationOrderCheck\.java" lines="189"/>
<!-- LocalizedMessage class is immutable, we need that amount of arguments. -->
<suppress checks="ParameterNumber"
files="LocalizedMessage.java"
lines="105, 143, 174"/>
<!-- Not reasonable to split as encapsulation of logic will be damaged. -->
<suppress checks="ExecutableStatementCount" files="Main\.java" lines="128"/>
<suppress checks="JavaNCSS" files="Main\.java" lines="128"/>
<!-- too complex to break apart -->
<suppress checks="CyclomaticComplexity" files="MissingOverrideCheck\.java" lines="144"/>
<suppress checks="ReturnCount" files="JavadocStyleCheck\.java" lines="342"/>
</suppressions>