Lines 800-805
Link Here
|
800 |
this.deltaListener.getCompilationUnitAST(this.workingCopy)); |
800 |
this.deltaListener.getCompilationUnitAST(this.workingCopy)); |
801 |
} |
801 |
} |
802 |
/* |
802 |
/* |
|
|
803 |
* Ensures that the AST broadcasted doesn't have a type root that is caching its contents |
804 |
* (regression test for https://bugs.eclipse.org/bugs/show_bug.cgi?id=222213 ) |
805 |
*/ |
806 |
public void testBroadcastAST5() throws JavaModelException { |
807 |
setWorkingCopyContents( |
808 |
"package p1;\n" + |
809 |
"import p2.*;\n" + |
810 |
"public class X {\n" + |
811 |
"}"); |
812 |
this.workingCopy.reconcile(AST.JLS3, false/*don't force problem detection*/, null/*primary owner*/, null/*no progress*/); |
813 |
org.eclipse.jdt.core.dom.CompilationUnit compilationUnit = this.deltaListener.getCompilationUnitAST(this.workingCopy); |
814 |
String newContents = |
815 |
"package p1;\n" + |
816 |
"public class X {\n" + |
817 |
"}"; |
818 |
setWorkingCopyContents(newContents); |
819 |
org.eclipse.jdt.internal.compiler.env.ICompilationUnit compilerCU = (org.eclipse.jdt.internal.compiler.env.ICompilationUnit) compilationUnit.getTypeRoot(); |
820 |
assertSourceEquals("Unexpected contents", newContents, new String(compilerCU.getContents())); |
821 |
} |
822 |
/* |
803 |
* Ensures that reconciling a subclass doesn't close the buffer while resolving its superclass. |
823 |
* Ensures that reconciling a subclass doesn't close the buffer while resolving its superclass. |
804 |
* (regression test for bug 62854 refactoring does not trigger reconcile) |
824 |
* (regression test for bug 62854 refactoring does not trigger reconcile) |
805 |
*/ |
825 |
*/ |