@Override

This commit is contained in:
Alexey Kudravtsev
2013-11-01 18:07:29 +04:00
parent e22b7e6428
commit ba6b81fc8f
80 changed files with 387 additions and 163 deletions
@@ -1,3 +1,19 @@
/*
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/*
* User: anna
* Date: 27-Jun-2007
@@ -85,7 +101,7 @@ public class AddAnnotationFixTest extends UsefulTestCase {
addLibrary("/content/anno");
}
private void addLibrary(final @NotNull String... annotationsDirs) {
private void addLibrary(@NotNull final String... annotationsDirs) {
ApplicationManager.getApplication().runWriteAction(new Runnable() {
@Override
public void run() {
@@ -17,7 +17,6 @@ package com.intellij.codeInsight;
import com.intellij.codeInsight.generation.actions.GenerateCreateUIAction;
import com.intellij.psi.PsiClass;
import com.intellij.psi.PsiElement;
import com.intellij.psi.util.PsiTreeUtil;
import com.intellij.testFramework.LightCodeInsightTestCase;
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2011 JetBrains s.r.o.
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -17,7 +17,8 @@ package com.intellij.codeInsight.daemon;
import com.intellij.codeInsight.daemon.quickFix.ChangeNewOperatorTypeTest;
import com.intellij.codeInsight.daemon.quickFix.Simplify2DiamondInspectionsTest;
import com.intellij.refactoring.*;
import com.intellij.refactoring.IntroduceParameterTest;
import com.intellij.refactoring.IntroduceVariableTest;
import junit.framework.Test;
import junit.framework.TestSuite;
@@ -226,6 +226,7 @@ public class HighlightStressTest extends LightDaemonAnalyzerTestCase {
}
final String text = imports + "\n class X {{\n" + usages + "}}";
ApplicationManager.getApplication().runWriteAction(new Runnable() {
@Override
public void run() {
getEditor().getDocument().setText(text);
}
@@ -15,7 +15,7 @@
*/
package com.intellij.codeInsight.daemon;
import com.intellij.ExtensionPoints;
import com.intellij.ToolExtensionPoints;
import com.intellij.codeInsight.daemon.impl.HighlightInfo;
import com.intellij.codeInspection.LocalInspectionTool;
import com.intellij.codeInspection.compiler.JavacQuirksInspection;
@@ -106,7 +106,7 @@ public class LightAdvHighlightingJdk7Test extends LightDaemonAnalyzerTestCase {
}
public void testDynamicallyAddIgnoredAnnotations() throws Exception {
ExtensionPoint<EntryPoint> point = Extensions.getRootArea().getExtensionPoint(ExtensionPoints.DEAD_CODE_TOOL);
ExtensionPoint<EntryPoint> point = Extensions.getRootArea().getExtensionPoint(ToolExtensionPoints.DEAD_CODE_TOOL);
EntryPoint extension = new EntryPoint() {
@NotNull @Override public String getDisplayName() { return "duh"; }
@Override public boolean isEntryPoint(RefElement refElement, PsiElement psiElement) { return false; }
@@ -389,6 +389,6 @@ public class LightAdvHighlightingTest extends LightDaemonAnalyzerTestCase {
public void testInsane() throws IOException {
configureFromFileText("x.java", "class X { \nxxxx\n }");
List<HighlightInfo> infos = highlightErrors();
assertTrue(infos.size() != 0);
assertTrue(!infos.isEmpty());
}
}
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2011 JetBrains s.r.o.
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -15,9 +15,8 @@
*/
package com.intellij.codeInsight.daemon
import com.intellij.testFramework.fixtures.JavaCodeInsightFixtureTestCase
import com.intellij.openapi.application.ApplicationManager
import com.intellij.testFramework.fixtures.JavaCodeInsightFixtureTestCase
/**
* @author peter
*/
@@ -13,13 +13,12 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.intellij.codeInsight.daemon.lambda;
import com.intellij.JavaTestUtil;
import com.intellij.codeInsight.completion.LightFixtureCompletionTestCase;
import com.intellij.testFramework.LightProjectDescriptor;
import org.jetbrains.annotations.NotNull;
package com.intellij.codeInsight.daemon.lambda
import com.intellij.JavaTestUtil
import com.intellij.codeInsight.completion.LightFixtureCompletionTestCase
import com.intellij.testFramework.LightProjectDescriptor
import org.jetbrains.annotations.NotNull
/**
* User: anna
*/
@@ -1,8 +1,23 @@
/*
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.intellij.codeInsight.daemon.quickFix;
import com.intellij.codeInsight.daemon.LightIntentionActionTestCase;
import com.intellij.psi.codeStyle.CodeStyleSettings;
import com.intellij.psi.codeStyle.CodeStyleSettingsManager;
import com.intellij.codeInsight.daemon.LightIntentionActionTestCase;
import org.jdom.Element;
/**
@@ -1,5 +1,5 @@
/*
* Copyright 2000-2012 JetBrains s.r.o.
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -21,7 +21,9 @@
package com.intellij.codeInsight.daemon.quickFix;
import com.intellij.codeInsight.intention.IntentionAction;
import com.intellij.codeInspection.*;
import com.intellij.codeInspection.DefaultHighlightVisitorBasedInspection;
import com.intellij.codeInspection.LocalQuickFix;
import com.intellij.codeInspection.ProblemDescriptor;
import com.intellij.lang.Language;
import com.intellij.lang.LanguageAnnotators;
import com.intellij.lang.annotation.Annotation;
@@ -1,6 +1,20 @@
/*
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.intellij.codeInsight.daemon.quickFix;
import com.intellij.codeInsight.daemon.quickFix.LightQuickFix15TestCase;
import com.intellij.codeInspection.LocalInspectionTool;
import com.intellij.codeInspection.i18n.I18nInspection;
import com.intellij.openapi.util.Comparing;
@@ -1,3 +1,18 @@
/*
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.intellij.codeInsight.daemon.quickFix;
import com.intellij.codeInspection.i18n.I18nQuickFixHandler;
@@ -32,7 +47,7 @@ public class I18nizeTest extends LightCodeInsightTestCase {
action.update(event);
@NonNls String afterFile = getBasePath() + "/after" + getTestName(false) + "." + ext;
boolean afterFileExists = new File(PathManagerEx.getTestDataPath() + afterFile).exists();
I18nQuickFixHandler handler = action.getHandler(event);
I18nQuickFixHandler handler = I18nizeAction.getHandler(event);
try {
if (handler != null) {
handler.checkApplicability(getFile(), getEditor());
@@ -1,12 +1,26 @@
package com.intellij.codeInsight.highlighting;
/*
* Copyright 2000-2013 JetBrains s.r.o.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package com.intellij.codeInsight.highlighting
import com.intellij.JavaTestUtil
import com.intellij.codeInsight.daemon.impl.IdentifierHighlighterPassFactory
import com.intellij.codeInspection.sillyAssignment.SillyAssignmentInspection
import com.intellij.lang.annotation.HighlightSeverity;
import com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase;
import org.jetbrains.annotations.NonNls;
import com.intellij.lang.annotation.HighlightSeverity
import com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase
import org.jetbrains.annotations.NonNls
/**
* @author cdr
*/