Issue #3175: sevntu-checkstyle violations were resolved in test area
This commit is contained in:
parent
a9e548ab88
commit
54cdc72ced
|
|
@ -49,7 +49,8 @@
|
|||
files="AbstractViolationReporter.java"
|
||||
lines="152,164"/>
|
||||
|
||||
<!-- Tone down the checking for test code -->
|
||||
<suppress checks="CauseParameterInException|ForbidCCommentsInMethods|IllegalCatchExtended"
|
||||
files=".*[\\/]src[\\/](test|it)[\\/]"/>
|
||||
<!-- testing for catch Error is part of 100% coverage -->
|
||||
<suppress checks="IllegalCatchExtended"
|
||||
files="CheckerTest\.java"
|
||||
lines="569"/>
|
||||
</suppressions>
|
||||
|
|
@ -206,7 +206,7 @@ public class XMLLoggerTest {
|
|||
new LocalizedMessage(1, 1,
|
||||
"messages.properties", null, null, null, getClass(), null);
|
||||
final AuditEvent ev = new AuditEvent(this, "Test.java", message);
|
||||
logger.addException(ev, new TestException());
|
||||
logger.addException(ev, new TestException("msg", new RuntimeException("msg")));
|
||||
logger.auditFinished(null);
|
||||
final String[] expectedLines = {
|
||||
"<exception>",
|
||||
|
|
@ -261,6 +261,10 @@ public class XMLLoggerTest {
|
|||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
TestException(String msg, Throwable cause) {
|
||||
super(msg, cause);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void printStackTrace(PrintWriter printWriter) {
|
||||
printWriter.print("stackTrace");
|
||||
|
|
|
|||
|
|
@ -243,10 +243,6 @@ public class ImportOrderCheckTest extends BaseCheckTestSupport {
|
|||
public void testWildcardUnspecified() throws Exception {
|
||||
final DefaultConfiguration checkConfig = createCheckConfig(ImportOrderCheck.class);
|
||||
|
||||
/*
|
||||
<property name="ordered" value="true"/>
|
||||
<property name="separated" value="true"/>
|
||||
*/
|
||||
checkConfig.addAttribute("groups", "java,javax,org");
|
||||
final String[] expected = CommonUtils.EMPTY_STRING_ARRAY;
|
||||
|
||||
|
|
|
|||
|
|
@ -120,11 +120,9 @@ public class CommitValidationTest {
|
|||
final String commitMessage = commit.getFullMessage();
|
||||
final Matcher matcher = NEWLINE_PATTERN.matcher(commitMessage);
|
||||
if (matcher.find()) {
|
||||
/**
|
||||
* Git by default put newline character at the end of commit message. To check
|
||||
* if commit message has a single line we have to make sure that the only
|
||||
* newline character found is in the end of commit message.
|
||||
*/
|
||||
// Git by default put newline character at the end of commit message. To check
|
||||
// if commit message has a single line we have to make sure that the only
|
||||
// newline character found is in the end of commit message.
|
||||
final boolean isFoundNewLineCharacterAtTheEndOfMessage =
|
||||
matcher.end() == commitMessage.length();
|
||||
assertTrue(getInvalidCommitMessageFormattingError(commitId, commitMessage),
|
||||
|
|
|
|||
Loading…
Reference in New Issue