瀏覽代碼

335619

tags/V1_6_11RC1
aclement 13 年之前
父節點
當前提交
91c176061b

+ 5
- 0
tests/multiIncremental/PR278496_9/base/src/a/b/c/Azpect.java 查看文件

@@ -0,0 +1,5 @@
package a.b.c;

public aspect Azpect {
before():staticinitialization(Code2) {}
}

+ 13
- 0
tests/multiIncremental/PR278496_9/base/src/a/b/c/Code.java 查看文件

@@ -0,0 +1,13 @@
package a.b.c;
import java.util.List;
import java.util.ArrayList;

public class Code {
public void m() {
List l = new ArrayList();
}

static class CodeInner {
}
}


+ 10
- 0
tests/multiIncremental/PR278496_9/base/src/a/b/c/Code2.java 查看文件

@@ -0,0 +1,10 @@
package a.b.c;
import java.util.List;
import java.util.ArrayList;

public class Code2 {
public void m() {
List l = new ArrayList();
}
}


+ 12
- 0
tests/src/org/aspectj/systemtest/ajc1611/Ajc1611Tests.java 查看文件

@@ -36,6 +36,18 @@ public class Ajc1611Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
public void testDeclareField_328840() {
runTest("pr328840");
}
// public void testAnnoStyleAdviceChain_333274() {
// runTest("anno style advice chain");
// }
//
// public void testAnnoStyleAdviceChain_333274_2() {
// runTest("code style advice chain");
// }
//
// public void testAnnoStyleAdviceChain_333274_3() {
// runTest("code style advice chain - no inline");
// }

// ---


+ 50
- 0
tests/src/org/aspectj/systemtest/ajc1611/ajc1611.xml 查看文件

@@ -1,6 +1,56 @@
<!DOCTYPE suite SYSTEM "../tests/ajcTestSuite.dtd"[]>

<suite>
<ajc-test dir="bugs1611/pr333274" title="anno style advice chain">
<compile files="ma/Annotation1.java ma/aspect1/Aspect1.java ma/aspect3/Aspect3.java ma/Main.java ma/Precedence.java" options="-1.5"/>
<run class="ma.Main">
<stdout>
<line text="&gt;In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="=In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="&lt;In Aspect1"/>
</stdout>
</run>
</ajc-test>
<ajc-test dir="bugs1611/pr333274" title="code style advice chain - no inline">
<compile files="ma2/Annotation1.java ma2/aspect1/Aspect1.java ma2/aspect3/Aspect3.java ma2/Main.java ma2/Precedence.java" options="-1.5 -XnoInline"/>
<run class="ma2.Main">
<stdout>
<line text="&gt;In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="=In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="&lt;In Aspect1"/>
</stdout>
</run>
</ajc-test>
<ajc-test dir="bugs1611/pr333274" title="code style advice chain">
<compile files="ma2/Annotation1.java ma2/aspect1/Aspect1.java ma2/aspect3/Aspect3.java ma2/Main.java ma2/Precedence.java" options="-1.5 "/>
<run class="ma2.Main">
<stdout>
<line text="&gt;In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="=In Aspect1"/>
<line text="&gt;In Aspect3"/>
<line text="Method call"/>
<line text="&lt;In Aspect3"/>
<line text="&lt;In Aspect1"/>
</stdout>
</run>
</ajc-test>

<ajc-test dir="bugs1611/pr328840" title="pr328840">
<compile files="Wibble.aj" options="-1.5 -showWeaveInfo">

+ 15
- 0
tests/src/org/aspectj/systemtest/incremental/tools/IncrementalCompilationTests.java 查看文件

@@ -276,6 +276,21 @@ public class IncrementalCompilationTests extends AbstractMultiProjectIncremental
IProgramElement ipe = model.findElementForHandleOrCreate("=PR278496_1<a.b.c{Code.java", false);
assertNull(ipe);
}
// inner classes
public void testDeletion_278496_9() throws Exception {
String p = "PR278496_9";
initialiseProject(p);
configureNonStandardCompileOptions(p, "-Xset:minimalModel=true");
build(p);
checkWasFullBuild();
printModel(p);

AspectJElementHierarchy model = (AspectJElementHierarchy) getModelFor(p).getHierarchy();
// Node for "Code.java" should not be there:
IProgramElement ipe = model.findElementForHandleOrCreate("=PR278496_9<a.b.c{Code.java", false);
assertNull(ipe);
}

// deleting unaffected model entries
public void testDeletion_278496_2() throws Exception {

Loading…
取消
儲存