aboutsummaryrefslogtreecommitdiff
path: root/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming
diff options
context:
space:
mode:
authorAndrei Selkin <andreyselkin@gmail.com>2015-11-05 23:21:56 +0300
committerRoman Ivanov <ivanov-jr@mail.ru>2015-11-05 20:59:34 -0800
commit8381754587bee0de49489e9bfb11e5912f664e87 (patch)
treead3a1bf561ac8e5c25ebb79775e5f0af8e8f76c0 /src/test/java/com/puppycrawl/tools/checkstyle/checks/naming
parentbe8a60a4d95978e1b6cdb32fefca58f424e61178 (diff)
downloadcheckstyle-8381754587bee0de49489e9bfb11e5912f664e87.tar.gz
Issue #2290: Fix NPE in isOverriddenMethod during validation of methods with implicit modifiers
Diffstat (limited to 'src/test/java/com/puppycrawl/tools/checkstyle/checks/naming')
-rw-r--r--src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/ParameterNameCheckTest.java10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/ParameterNameCheckTest.java b/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/ParameterNameCheckTest.java
index e595e4999..1c35fd32e 100644
--- a/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/ParameterNameCheckTest.java
+++ b/src/test/java/com/puppycrawl/tools/checkstyle/checks/naming/ParameterNameCheckTest.java
@@ -106,6 +106,11 @@ public class ParameterNameCheckTest
final String[] expected = {
"11:28: " + getCheckMessage(MSG_INVALID_PATTERN, "object", pattern),
"15:30: " + getCheckMessage(MSG_INVALID_PATTERN, "aaaa", pattern),
+ "19:19: " + getCheckMessage(MSG_INVALID_PATTERN, "abc", pattern),
+ "19:28: " + getCheckMessage(MSG_INVALID_PATTERN, "bd", pattern),
+ "21:18: " + getCheckMessage(MSG_INVALID_PATTERN, "abc", pattern),
+ "28:33: " + getCheckMessage(MSG_INVALID_PATTERN, "field", pattern),
+ "28:62: " + getCheckMessage(MSG_INVALID_PATTERN, "packageNames", pattern),
};
verify(checkConfig, getPath("InputOverrideAnnotation.java"), expected);
}
@@ -124,6 +129,11 @@ public class ParameterNameCheckTest
"6:34: " + getCheckMessage(MSG_INVALID_PATTERN, "o", pattern),
"11:28: " + getCheckMessage(MSG_INVALID_PATTERN, "object", pattern),
"15:30: " + getCheckMessage(MSG_INVALID_PATTERN, "aaaa", pattern),
+ "19:19: " + getCheckMessage(MSG_INVALID_PATTERN, "abc", pattern),
+ "19:28: " + getCheckMessage(MSG_INVALID_PATTERN, "bd", pattern),
+ "21:18: " + getCheckMessage(MSG_INVALID_PATTERN, "abc", pattern),
+ "28:33: " + getCheckMessage(MSG_INVALID_PATTERN, "field", pattern),
+ "28:62: " + getCheckMessage(MSG_INVALID_PATTERN, "packageNames", pattern),
};
verify(checkConfig, getPath("InputOverrideAnnotation.java"), expected);
}