merge misspelled (hashCode, toString, setUp, tearDown, compareTo) inspections

This commit is contained in:
Anna.Kozlova
2016-07-20 09:29:54 +02:00
parent 235d77f357
commit 0f82a3bf77
22 changed files with 150 additions and 509 deletions
@@ -15,12 +15,12 @@
*/
package com.intellij.codeInspection.deadCode;
import com.intellij.codeInspection.ex.InspectionElementsMerger;
import com.intellij.codeInspection.ex.InspectionElementsMergerBase;
import com.intellij.codeInspection.unusedSymbol.UnusedSymbolLocalInspection;
import com.intellij.openapi.util.WriteExternalException;
import org.jdom.Element;
public class UnusedDeclarationInspectionMerger extends InspectionElementsMerger {
public class UnusedDeclarationInspectionMerger extends InspectionElementsMergerBase {
private static final String UNUSED_SYMBOL = "UNUSED_SYMBOL";
private static final String UNUSED_DECLARATION = "UnusedDeclaration";
@@ -360,6 +360,22 @@ public class InspectionProfileTest extends LightIdeaTestCase {
"</profile>");
}
public void testMergedMisspelledInspections() throws Exception {
checkMergedNoChanges("<profile version=\"1.0\">\n" +
" <option name=\"myName\" value=\"" + PROFILE + "\" />\n" +
" <inspection_tool class=\"MethodNamesDifferOnlyByCase\" enabled=\"true\" level=\"WARNING\" enabled_by_default=\"false\">\n" +
" <option name=\"ignoreIfMethodIsOverride\" value=\"false\" />\n" +
" </inspection_tool>\n" +
"</profile>");
checkMergedNoChanges("<profile version=\"1.0\">\n" +
" <option name=\"myName\" value=\"" + PROFILE + "\" />\n" +
" <inspection_tool class=\"MethodNamesDifferOnlyByCase\" enabled=\"true\" level=\"WARNING\" enabled_by_default=\"false\">\n" +
" <option name=\"ignoreIfMethodIsOverride\" value=\"false\" />\n" +
" </inspection_tool>\n" +
" <inspection_tool class=\"MisspelledSetUp\" enabled=\"true\" level=\"WARNING\" enabled_by_default=\"false\" />\n" +
"</profile>");
}
public void testDisabledUnusedDeclarationWithChanges() throws Exception {
checkMergedNoChanges("<profile version=\"1.0\">\n" +
" <option name=\"myName\" value=\"" + PROFILE + "\" />\n" +