Lines 6348-6351
Link Here
|
6348 |
""+ getExternalJCLPathString("1.5") + " java.lang.CloneNotSupportedException EXACT_MATCH" |
6348 |
""+ getExternalJCLPathString("1.5") + " java.lang.CloneNotSupportedException EXACT_MATCH" |
6349 |
); |
6349 |
); |
6350 |
} |
6350 |
} |
|
|
6351 |
static { |
6352 |
TESTS_PREFIX = "testBug137984"; |
6353 |
} |
6354 |
/** |
6355 |
* Bug 137984: [search] Field references not found when type is a qualified member type [regression] |
6356 |
* @see "https://bugs.eclipse.org/bugs/show_bug.cgi?id=137984" |
6357 |
*/ |
6358 |
public void testBug137984_jar() throws CoreException { |
6359 |
IType type = getPackageFragment("JavaSearchBugs", "lib/b137984.jar", "").getClassFile("CJ.class").getType(); |
6360 |
IField field = type.getField("c3"); |
6361 |
search(field, REFERENCES); |
6362 |
assertSearchResults( |
6363 |
"lib/b137984.jar CJ(int) EXACT_MATCH" |
6364 |
); |
6365 |
} |
6366 |
public void testBug137984_cu() throws CoreException { |
6367 |
ICompilationUnit unit = getCompilationUnit("JavaSearchBugs", "src", "b137984", "C.java"); |
6368 |
IField field = unit.getType("C").getField("c3"); |
6369 |
search(field, REFERENCES); |
6370 |
assertSearchResults( |
6371 |
"src/b137984/C.java b137984.C(int) [c3] EXACT_MATCH" |
6372 |
); |
6373 |
} |
6374 |
public void testBug137984_wc() throws CoreException { |
6375 |
workingCopies = new ICompilationUnit[1]; |
6376 |
workingCopies[0] = getWorkingCopy("/JavaSearchBugs/src/CW.java", |
6377 |
"public class CW {\n" + |
6378 |
" CW2 c2;\n" + |
6379 |
" CW2.CW3 c3;\n" + |
6380 |
" CW(int c) {\n" + |
6381 |
" c2 = new CW2(c);\n" + |
6382 |
" c3 = c2.new CW3(c);\n" + |
6383 |
" }\n" + |
6384 |
" class CW2 {\n" + |
6385 |
" CW2(int x) {}\n" + |
6386 |
" class CW3 {\n" + |
6387 |
" CW3(int x) {}\n" + |
6388 |
" }\n" + |
6389 |
" }\n" + |
6390 |
"}\n" |
6391 |
); |
6392 |
IField field = workingCopies[0].getType("CW").getField("c3"); |
6393 |
search(field, REFERENCES); |
6394 |
assertSearchResults( |
6395 |
"src/CW.java CW(int) [c3] EXACT_MATCH" |
6396 |
); |
6397 |
} |
6351 |
} |
6398 |
} |