Pārlūkot izejas kodu

fix for Bugzilla Bug 36736

   compiler error expected for implemented abstract pointcuts 

and for

fix for Bugzilla Bug 36673  
   VerifyError in privileged aspect 
minimally extended coverage for this bug
tags/V1_1_0_RC2
jhugunin pirms 21 gadiem
vecāks
revīzija
fefd4559fb

+ 13
- 0
tests/ajcTests.xml Parādīt failu

@@ -5814,5 +5814,18 @@
<compile files="p1/C.java,p2/A2.java" options="-source14"/>
<run class="p2.A2" vm="1.4"/>
</ajc-test>

<ajc-test dir="new" pr="36736"
title="implemented abstract pointcut">
<compile files="AbstractImplementedPointcut.java">
<message kind="error" line="14"/>
</compile>
</ajc-test>
<ajc-test dir="new/verifyError" pr="36673"
title="privileged aspect main verify error">
<compile files="Privilege.java"/>
<run class="Privilege"/>
</ajc-test>
</suite>

+ 0
- 11
tests/ajcTestsFailing.xml Parādīt failu

@@ -4,16 +4,5 @@
<!-- contains valid tests that the compiler has never passed -->
<suite>

<ajc-test dir="new/verifyError" pr="36673"
title="privileged aspect main verify error">
<compile files="Privilege.java"/>
<run class="Privilege"/>
</ajc-test>

<ajc-test dir="new" pr="36736"
title="implemented abstract pointcut">
<compile files="AbstractImplementedPointcut.java">
<message kind="error" line="14"/>
</compile>
</ajc-test>
</suite>

+ 5
- 9
tests/jimTests.xml Parādīt failu

@@ -1,15 +1,11 @@
<!DOCTYPE suite SYSTEM "../tests/ajcTestSuite.dtd">
<suite>

<ajc-test dir="bugs/interSpecials" title="IllegalAccessError while accessing introduced variable / 1.1rc1"
pr="36110">
<compile files="p1/C.java,p2/A1.java"/>
<run class="p2.A1"/>
</ajc-test>
<ajc-test dir="bugs/interSpecials" title="testing that assert works like .class"
pr="36110">
<compile files="p1/C.java,p2/A2.java" options="-source14"/>
<run class="p2.A2" vm="1.4"/>
<ajc-test dir="new" pr="559"
title="subclass advice not run for join points selected by superclass cflow-based pointcuts"
keywords="from-resolved_10rc3">
<compile files="PR559.java"/>
<run class="PR559"/>
</ajc-test>
<!--

+ 8
- 1
tests/new/verifyError/Privilege.java Parādīt failu

@@ -7,13 +7,20 @@ class C {

privileged aspect A {
private int C.j = 1;
private static String C.s = "hello";
private String C.m() {
return "from A";
}
}

/** @testcase PR#36673 privileged aspect main verify error */
public privileged aspect Privilege {
public static void main(String[] args) {
C c = new C();
Tester.check(1 == c.j, "wrong value for c.j");
Tester.checkEqual(1, c.j, "wrong value for c.j");
Tester.checkEqual("hello", C.s, "wrong value for C.s");
Tester.checkEqual("from A", c.m(), "c.m()");
}
}


Notiek ielāde…
Atcelt
Saglabāt