Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 138137 Details for
Bug 276526
[content assist] Error - Type Duplicate interface Iterable for the type TestClass
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Tests plugin patch - v-0.5
276526-tests-patch-v0.5.txt (text/plain), 3.05 KB, created by
Pradeep Balachandran
on 2009-06-03 08:49:24 EDT
(
hide
)
Description:
Tests plugin patch - v-0.5
Filename:
MIME Type:
Creator:
Pradeep Balachandran
Created:
2009-06-03 08:49:24 EDT
Size:
3.05 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.core.tests.model >Index: src/org/eclipse/jdt/core/tests/model/CompletionTests.java >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.core.tests.model/src/org/eclipse/jdt/core/tests/model/CompletionTests.java,v >retrieving revision 1.203 >diff -u -r1.203 CompletionTests.java >--- src/org/eclipse/jdt/core/tests/model/CompletionTests.java 7 May 2009 08:49:30 -0000 1.203 >+++ src/org/eclipse/jdt/core/tests/model/CompletionTests.java 3 Jun 2009 12:43:11 -0000 >@@ -20102,4 +20102,61 @@ > requestor.getResults()); > } > >+public void test276526a() throws JavaModelException { >+ // This test is to ensure that an existing super interface is not offered as a completion choice, >+ // when all of them are in the same compilation unit. >+ this.workingCopies = new ICompilationUnit[1]; >+ this.workingCopies[0] = getWorkingCopy( >+ "/Completion/src/test/Test276526a.java", >+ "package test;\n" + >+ "interface IFoo {}\n" + >+ "interface IBar {}\n" + >+ "class Foo implements IFoo, test. {}\n"); >+ >+ CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(); >+ String str = this.workingCopies[0].getSource(); >+ String completeBehind = "test."; >+ int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); >+ >+ // In the absence of the fix, it would have been: >+ // "IBar[TYPE_REF]{IBar, test, Ltest.IBar;, null, 39}\n" + >+ // "IFoo[TYPE_REF]{IFoo, test, Ltest.IFoo;, null, 39}" >+ this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); >+ assertResults( >+ "IBar[TYPE_REF]{IBar, test, Ltest.IBar;, null, 39}", >+ requestor.getResults()); >+} >+ >+public void test276526b() throws JavaModelException { >+ // This test is to ensure that an existing super interface is not offered as a completion choice, >+ // when they are in different compilation units. >+ this.workingCopies = new ICompilationUnit[3]; >+ this.workingCopies[0] = getWorkingCopy( >+ "/Completion/src/test/Test276526b1.java", >+ "package test;\n" + >+ "public class TestClazz implements Interface1, test. {}"); >+ >+ this.workingCopies[1] = getWorkingCopy( >+ "/Completion/src/test/Test276526b2.java", >+ "package test;\n" + >+ "public interface Interface1 {}"); >+ >+ this.workingCopies[2] = getWorkingCopy( >+ "/Completion/src/test/Test276526b3.java", >+ "package test;\n" + >+ "public interface Interface2 {}"); >+ >+ CompletionTestsRequestor2 requestor = new CompletionTestsRequestor2(); >+ String str = this.workingCopies[0].getSource(); >+ String completeBehind = "test."; >+ int cursorLocation = str.lastIndexOf(completeBehind) + completeBehind.length(); >+ >+ this.workingCopies[0].codeComplete(cursorLocation, requestor, this.wcOwner); >+ assertResults( >+ // In the absence of the fix, it would also complete to Interface1: >+ //"Interface1[TYPE_REF]{Interface1, test, Ltest.Interface1;, null, 39}\n"+ >+ "Interface2[TYPE_REF]{Interface2, test, Ltest.Interface2;, null, 39}", >+ requestor.getResults()); >+} >+ > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 276526
:
138136
|
138137
|
138631
|
142634
|
142636
|
142862