Index: editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/utilities/ast/DartElementLocatorTest.java |
diff --git a/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/utilities/ast/DartElementLocatorTest.java b/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/utilities/ast/DartElementLocatorTest.java |
index ee0eb18df5ca2a7b1cecf1e0c0cada7f7771921d..b4bfafc3d25b8d6ca0e8bbb6586c83235516e467 100644 |
--- a/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/utilities/ast/DartElementLocatorTest.java |
+++ b/editor/tools/plugins/com.google.dart.tools.core_test/src/com/google/dart/tools/core/utilities/ast/DartElementLocatorTest.java |
@@ -46,6 +46,7 @@ public class DartElementLocatorTest extends TestCase { |
@SuppressWarnings("unchecked") |
private static <T extends DartElement> T assertLocation(CompilationUnit unit, String posMarker, |
Class<?> expectedElementType, String expectedMarker, int expectedLen) throws Exception { |
+ TestProject.waitForAutoBuild(); |
String source = unit.getSource(); |
// prepare DartUnit |
DartUnit dartUnit; |
@@ -188,6 +189,7 @@ public class DartElementLocatorTest extends TestCase { |
" aaa.A a;", |
"}", |
"")).getResource(); |
+ TestProject.waitForAutoBuild(); |
DartLibrary libraryA = testProject.getDartProject().getDartLibrary(libResourceA); |
DartLibrary libraryTest = testProject.getDartProject().getDartLibrary(resourceTest); |
// usage of "aaa" = "libraryA" |
@@ -318,6 +320,25 @@ public class DartElementLocatorTest extends TestCase { |
4); |
} |
+ public void test_Method_call() throws Exception { |
+ testElementLocator( |
+ formatLines( |
+ "// filler filler filler filler filler filler filler filler filler filler filler", |
+ "class A {", |
+ " call() {", |
+ " }", |
+ "}", |
+ "f() {", |
+ " A a = new A();", |
+ " a(); // marker", |
+ "}", |
+ ""), |
+ "; // marker", |
+ Method.class, |
+ "call() {", |
+ 4); |
+ } |
+ |
public void test_Method_getter_onDeclaration() throws Exception { |
testElementLocator( |
formatLines( |