don't highlight Java methods as not callable (PY-9037)

This commit is contained in:
Dmitry Jemerov
2013-03-04 15:14:07 +01:00
parent 7439ebe36b
commit 5e80806668
7 changed files with 103 additions and 17 deletions

View File

@@ -3,14 +3,23 @@ package com.jetbrains.jython;
import com.intellij.testFramework.fixtures.LightCodeInsightFixtureTestCase;
import com.jetbrains.python.PythonTestUtil;
import com.jetbrains.python.inspections.PyCallingNonCallableInspection;
import com.jetbrains.python.inspections.PyUnresolvedReferencesInspection;
/**
* @author yole
*/
public class PyJythonHighlightingTest extends LightCodeInsightFixtureTestCase {
public void testCallableJavaClass() {
myFixture.configureByFile("callableJavaClass.py");
myFixture.enableInspections(PyCallingNonCallableInspection.class);
doCallableTest();
}
public void testCallableStaticMethod() {
doCallableTest();
}
private void doCallableTest() {
myFixture.configureByFile(getTestName(false) + ".py");
myFixture.enableInspections(PyCallingNonCallableInspection.class, PyUnresolvedReferencesInspection.class);
myFixture.checkHighlighting(true, false, false);
}