Lines 8196-8199
Link Here
|
8196 |
"Test270[TYPE_REF]{Test270, test, Ltest.Test270;, null, null, " + (R_DEFAULT + R_INTERESTING + R_CASE + R_EXPECTED_TYPE + R_UNQUALIFIED + R_EXACT_NAME + R_NON_RESTRICTED) + "}", |
8196 |
"Test270[TYPE_REF]{Test270, test, Ltest.Test270;, null, null, " + (R_DEFAULT + R_INTERESTING + R_CASE + R_EXPECTED_TYPE + R_UNQUALIFIED + R_EXACT_NAME + R_NON_RESTRICTED) + "}", |
8197 |
requestor.getResults()); |
8197 |
requestor.getResults()); |
8198 |
} |
8198 |
} |
|
|
8199 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8200 |
public void test0271() throws JavaModelException { |
8201 |
this.workingCopies = new ICompilationUnit[2]; |
8202 |
this.workingCopies[0] = getWorkingCopy( |
8203 |
"/Completion/src/test/Test.java", |
8204 |
"package test;\n"+ |
8205 |
"public class Test {\n"+ |
8206 |
" void foo() {\n"+ |
8207 |
" TestCollections.<Object>zzz\n"+ |
8208 |
" }\n"+ |
8209 |
"}\n"); |
8210 |
|
8211 |
this.workingCopies[1] = getWorkingCopy( |
8212 |
"/Completion/src/test/TestCollections.java", |
8213 |
"package test;\n"+ |
8214 |
"public class TestCollections {\n"+ |
8215 |
" public <T> void zzz1(T t) {}\n"+ |
8216 |
" public static <T> void zzz2(T t) {}\n"+ |
8217 |
"}"); |
8218 |
|
8219 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8220 |
|
8221 |
String str = this.workingCopies[0].getSource(); |
8222 |
String completeBehind = "zzz"; |
8223 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8224 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8225 |
|
8226 |
assertResults( |
8227 |
"zzz2[METHOD_REF]{zzz2(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8228 |
requestor.getResults()); |
8229 |
} |
8230 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8231 |
public void test0272() throws JavaModelException { |
8232 |
this.workingCopies = new ICompilationUnit[2]; |
8233 |
this.workingCopies[0] = getWorkingCopy( |
8234 |
"/Completion/src/test/Test.java", |
8235 |
"package test;\n"+ |
8236 |
"public class Test {\n"+ |
8237 |
" void foo(TestCollections t) {\n"+ |
8238 |
" t.<Object>zzz\n"+ |
8239 |
" }\n"+ |
8240 |
"}\n"); |
8241 |
|
8242 |
this.workingCopies[1] = getWorkingCopy( |
8243 |
"/Completion/src/test/TestCollections.java", |
8244 |
"package test;\n"+ |
8245 |
"public class TestCollections {\n"+ |
8246 |
" public <T> void zzz1(T t) {}\n"+ |
8247 |
" public static <T> void zzz2(T t) {}\n"+ |
8248 |
"}"); |
8249 |
|
8250 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8251 |
|
8252 |
String str = this.workingCopies[0].getSource(); |
8253 |
String completeBehind = "zzz"; |
8254 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8255 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8256 |
|
8257 |
assertResults( |
8258 |
"zzz2[METHOD_REF]{zzz2(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}\n" + |
8259 |
"zzz1[METHOD_REF]{zzz1(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz1, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_STATIC + R_NON_RESTRICTED) + "}", |
8260 |
requestor.getResults()); |
8261 |
} |
8262 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8263 |
public void test0273() throws JavaModelException { |
8264 |
this.workingCopies = new ICompilationUnit[2]; |
8265 |
this.workingCopies[0] = getWorkingCopy( |
8266 |
"/Completion/src/test/Test.java", |
8267 |
"package test;\n"+ |
8268 |
"public class Test {\n"+ |
8269 |
" TestCollections bar() {\n"+ |
8270 |
" return null;\n"+ |
8271 |
" }\n"+ |
8272 |
" void foo() {\n"+ |
8273 |
" bar().<Object>zzz\n"+ |
8274 |
" }\n"+ |
8275 |
"}\n"); |
8276 |
|
8277 |
this.workingCopies[1] = getWorkingCopy( |
8278 |
"/Completion/src/test/TestCollections.java", |
8279 |
"package test;\n"+ |
8280 |
"public class TestCollections {\n"+ |
8281 |
" public <T> void zzz1(T t) {}\n"+ |
8282 |
" public static <T> void zzz2(T t) {}\n"+ |
8283 |
"}"); |
8284 |
|
8285 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8286 |
|
8287 |
String str = this.workingCopies[0].getSource(); |
8288 |
String completeBehind = "zzz"; |
8289 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8290 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8291 |
|
8292 |
assertResults( |
8293 |
"zzz2[METHOD_REF]{zzz2(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}\n" + |
8294 |
"zzz1[METHOD_REF]{zzz1(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz1, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_STATIC + R_NON_RESTRICTED) + "}", |
8295 |
requestor.getResults()); |
8296 |
} |
8297 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8298 |
public void test0274() throws JavaModelException { |
8299 |
this.workingCopies = new ICompilationUnit[2]; |
8300 |
this.workingCopies[0] = getWorkingCopy( |
8301 |
"/Completion/src/test/Test.java", |
8302 |
"package test;\n"+ |
8303 |
"public class Test {\n"+ |
8304 |
" void foo() {\n"+ |
8305 |
" int.<Object>zzz\n"+ |
8306 |
" }\n"+ |
8307 |
"}\n"); |
8308 |
|
8309 |
this.workingCopies[1] = getWorkingCopy( |
8310 |
"/Completion/src/test/TestCollections.java", |
8311 |
"package test;\n"+ |
8312 |
"public class TestCollections {\n"+ |
8313 |
" public <T> void zzz1(T t) {}\n"+ |
8314 |
" public static <T> void zzz2(T t) {}\n"+ |
8315 |
"}"); |
8316 |
|
8317 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8318 |
|
8319 |
String str = this.workingCopies[0].getSource(); |
8320 |
String completeBehind = "zzz"; |
8321 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8322 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8323 |
|
8324 |
assertResults( |
8325 |
"", |
8326 |
requestor.getResults()); |
8327 |
} |
8328 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8329 |
public void test0275() throws JavaModelException { |
8330 |
this.workingCopies = new ICompilationUnit[2]; |
8331 |
this.workingCopies[0] = getWorkingCopy( |
8332 |
"/Completion/src/test/Test.java", |
8333 |
"package test;\n"+ |
8334 |
"public class Test {\n"+ |
8335 |
" void foo(int t) {\n"+ |
8336 |
" t.<Object>zzz\n"+ |
8337 |
" }\n"+ |
8338 |
"}\n"); |
8339 |
|
8340 |
this.workingCopies[1] = getWorkingCopy( |
8341 |
"/Completion/src/test/TestCollections.java", |
8342 |
"package test;\n"+ |
8343 |
"public class TestCollections {\n"+ |
8344 |
" public <T> void zzz1(T t) {}\n"+ |
8345 |
" public static <T> void zzz2(T t) {}\n"+ |
8346 |
"}"); |
8347 |
|
8348 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8349 |
|
8350 |
String str = this.workingCopies[0].getSource(); |
8351 |
String completeBehind = "zzz"; |
8352 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8353 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8354 |
|
8355 |
assertResults( |
8356 |
"", |
8357 |
requestor.getResults()); |
8358 |
} |
8359 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8360 |
public void test0276() throws JavaModelException { |
8361 |
this.workingCopies = new ICompilationUnit[2]; |
8362 |
this.workingCopies[0] = getWorkingCopy( |
8363 |
"/Completion/src/test/Test.java", |
8364 |
"package test;\n"+ |
8365 |
"public class Test {\n"+ |
8366 |
" int bar() {\n"+ |
8367 |
" return 0;\n"+ |
8368 |
" }\n"+ |
8369 |
" void foo() {\n"+ |
8370 |
" bar().<Object>zzz\n"+ |
8371 |
" }\n"+ |
8372 |
"}\n"); |
8373 |
|
8374 |
this.workingCopies[1] = getWorkingCopy( |
8375 |
"/Completion/src/test/TestCollections.java", |
8376 |
"package test;\n"+ |
8377 |
"public class TestCollections {\n"+ |
8378 |
" public <T> void zzz1(T t) {}\n"+ |
8379 |
" public static <T> void zzz2(T t) {}\n"+ |
8380 |
"}"); |
8381 |
|
8382 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8383 |
|
8384 |
String str = this.workingCopies[0].getSource(); |
8385 |
String completeBehind = "zzz"; |
8386 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8387 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8388 |
|
8389 |
assertResults( |
8390 |
"", |
8391 |
requestor.getResults()); |
8392 |
} |
8393 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8394 |
public void test0277() throws JavaModelException { |
8395 |
this.workingCopies = new ICompilationUnit[2]; |
8396 |
this.workingCopies[0] = getWorkingCopy( |
8397 |
"/Completion/src/test/Test.java", |
8398 |
"package test;\n"+ |
8399 |
"public class Test {\n"+ |
8400 |
" void foo(TestCollections[] o) {\n"+ |
8401 |
" o.<Object>zzz\n"+ |
8402 |
" }\n"+ |
8403 |
"}\n"); |
8404 |
|
8405 |
this.workingCopies[1] = getWorkingCopy( |
8406 |
"/Completion/src/test/TestCollections.java", |
8407 |
"package test;\n"+ |
8408 |
"public class TestCollections {\n"+ |
8409 |
" public <T> void zzz1(T t) {}\n"+ |
8410 |
" public static <T> void zzz2(T t) {}\n"+ |
8411 |
"}"); |
8412 |
|
8413 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8414 |
|
8415 |
String str = this.workingCopies[0].getSource(); |
8416 |
String completeBehind = "zzz"; |
8417 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8418 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8419 |
|
8420 |
assertResults( |
8421 |
"", |
8422 |
requestor.getResults()); |
8423 |
} |
8424 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8425 |
public void test0278() throws JavaModelException { |
8426 |
this.workingCopies = new ICompilationUnit[1]; |
8427 |
this.workingCopies[0] = getWorkingCopy( |
8428 |
"/Completion/src/test/Test.java", |
8429 |
"package test;\n"+ |
8430 |
"public class Test {\n"+ |
8431 |
" public <T> void zzz1(T t) {}\n"+ |
8432 |
" public static <T> void zzz2(T t) {}\n"+ |
8433 |
" void foo(TestCollections[] o) {\n"+ |
8434 |
" this.<Object>zzz\n"+ |
8435 |
" }\n"+ |
8436 |
"}\n"); |
8437 |
|
8438 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8439 |
|
8440 |
String str = this.workingCopies[0].getSource(); |
8441 |
String completeBehind = "zzz"; |
8442 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8443 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8444 |
|
8445 |
assertResults( |
8446 |
"zzz2[METHOD_REF]{zzz2(), Ltest.Test;, (Ljava.lang.Object;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8447 |
requestor.getResults()); |
8448 |
} |
8449 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8450 |
public void test0279() throws JavaModelException { |
8451 |
this.workingCopies = new ICompilationUnit[2]; |
8452 |
this.workingCopies[0] = getWorkingCopy( |
8453 |
"/Completion/src/test/Test.java", |
8454 |
"package test;\n"+ |
8455 |
"public class Test extends TestCollections {\n"+ |
8456 |
" void foo() {\n"+ |
8457 |
" super.<Object>zzz\n"+ |
8458 |
" }\n"+ |
8459 |
"}\n"); |
8460 |
|
8461 |
this.workingCopies[1] = getWorkingCopy( |
8462 |
"/Completion/src/test/TestCollections.java", |
8463 |
"package test;\n"+ |
8464 |
"public class TestCollections {\n"+ |
8465 |
" public <T> void zzz1(T t) {}\n"+ |
8466 |
" public static <T> void zzz2(T t) {}\n"+ |
8467 |
"}"); |
8468 |
|
8469 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8470 |
|
8471 |
String str = this.workingCopies[0].getSource(); |
8472 |
String completeBehind = "zzz"; |
8473 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8474 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8475 |
|
8476 |
assertResults( |
8477 |
"zzz2[METHOD_REF]{zzz2(), Ltest.TestCollections;, (Ljava.lang.Object;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8478 |
requestor.getResults()); |
8479 |
} |
8480 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8481 |
public void test0280() throws JavaModelException { |
8482 |
this.workingCopies = new ICompilationUnit[2]; |
8483 |
this.workingCopies[0] = getWorkingCopy( |
8484 |
"/Completion/src/test/Test.java", |
8485 |
"package test;\n"+ |
8486 |
"public class Test {\n"+ |
8487 |
" void foo() {\n"+ |
8488 |
" TestCollections.<Object, Object>zzz\n"+ |
8489 |
" }\n"+ |
8490 |
"}\n"); |
8491 |
|
8492 |
this.workingCopies[1] = getWorkingCopy( |
8493 |
"/Completion/src/test/TestCollections.java", |
8494 |
"package test;\n"+ |
8495 |
"public class TestCollections {\n"+ |
8496 |
" public <T> void zzz1(T t) {}\n"+ |
8497 |
" public static <T> void zzz2(T t) {}\n"+ |
8498 |
"}"); |
8499 |
|
8500 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8501 |
|
8502 |
String str = this.workingCopies[0].getSource(); |
8503 |
String completeBehind = "zzz"; |
8504 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8505 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8506 |
|
8507 |
assertResults( |
8508 |
"", |
8509 |
requestor.getResults()); |
8510 |
} |
8511 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8512 |
public void test0281() throws JavaModelException { |
8513 |
this.workingCopies = new ICompilationUnit[2]; |
8514 |
this.workingCopies[0] = getWorkingCopy( |
8515 |
"/Completion/src/test/Test.java", |
8516 |
"package test;\n"+ |
8517 |
"public class Test {\n"+ |
8518 |
" void foo() {\n"+ |
8519 |
" TestCollections.zzz\n"+ |
8520 |
" }\n"+ |
8521 |
"}\n"); |
8522 |
|
8523 |
this.workingCopies[1] = getWorkingCopy( |
8524 |
"/Completion/src/test/TestCollections.java", |
8525 |
"package test;\n"+ |
8526 |
"public class TestCollections {\n"+ |
8527 |
" public <T> void zzz1(T t) {}\n"+ |
8528 |
" public static <T> void zzz2(T t) {}\n"+ |
8529 |
"}"); |
8530 |
|
8531 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8532 |
|
8533 |
String str = this.workingCopies[0].getSource(); |
8534 |
String completeBehind = "zzz"; |
8535 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8536 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8537 |
|
8538 |
assertResults( |
8539 |
"zzz2[METHOD_REF]{zzz2(), Ltest.TestCollections;, <T:Ljava.lang.Object;>(TT;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8540 |
requestor.getResults()); |
8541 |
} |
8542 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8543 |
public void test0282() throws JavaModelException { |
8544 |
this.workingCopies = new ICompilationUnit[1]; |
8545 |
this.workingCopies[0] = getWorkingCopy( |
8546 |
"/Completion/src/test/Test.java", |
8547 |
"package test;\n"+ |
8548 |
"public class Test {\n"+ |
8549 |
" public <T> void zzz1(T t) {}\n"+ |
8550 |
" public static <T> void zzz2(T t) {}\n"+ |
8551 |
" void foo(TestCollections[] o) {\n"+ |
8552 |
" this.<Unknown>zzz\n"+ |
8553 |
" }\n"+ |
8554 |
"}\n"); |
8555 |
|
8556 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8557 |
|
8558 |
String str = this.workingCopies[0].getSource(); |
8559 |
String completeBehind = "zzz"; |
8560 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8561 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8562 |
|
8563 |
assertResults( |
8564 |
"zzz2[METHOD_REF]{zzz2(), Ltest.Test;, <T:Ljava.lang.Object;>(TT;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8565 |
requestor.getResults()); |
8566 |
} |
8567 |
// https://bugs.eclipse.org/bugs/show_bug.cgi?id=106450 |
8568 |
public void test0283() throws JavaModelException { |
8569 |
this.workingCopies = new ICompilationUnit[1]; |
8570 |
this.workingCopies[0] = getWorkingCopy( |
8571 |
"/Completion/src/test/Test.java", |
8572 |
"package test;\n"+ |
8573 |
"public class Test {\n"+ |
8574 |
" public <T, U> void zzz1(T t) {}\n"+ |
8575 |
" public static <T> void zzz2(T t) {}\n"+ |
8576 |
" void foo(TestCollections[] o) {\n"+ |
8577 |
" this.<Unknown, Object>zzz\n"+ |
8578 |
" }\n"+ |
8579 |
"}\n"); |
8580 |
|
8581 |
CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(true); |
8582 |
|
8583 |
String str = this.workingCopies[0].getSource(); |
8584 |
String completeBehind = "zzz"; |
8585 |
int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); |
8586 |
this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); |
8587 |
|
8588 |
assertResults( |
8589 |
"zzz2[METHOD_REF]{zzz2(), Ltest.Test;, <T:Ljava.lang.Object;>(TT;)V, zzz2, (t), " + (R_DEFAULT + R_INTERESTING + R_CASE + R_NON_RESTRICTED) + "}", |
8590 |
requestor.getResults()); |
8591 |
} |
8199 |
} |
8592 |
} |