]> source.dussan.org Git - aspectj.git/commitdiff
@testcase PR#36673 privileged aspect main verify error
authorwisberg <wisberg>
Sat, 19 Apr 2003 20:47:30 +0000 (20:47 +0000)
committerwisberg <wisberg>
Sat, 19 Apr 2003 20:47:30 +0000 (20:47 +0000)
tests/ajcTestsFailing.xml
tests/new/verifyError/Privilege.java [new file with mode: 0644]

index 1b2b82f8cb6243bc51ae65732e623066a9538266..a2441ef7841141c10cbeec924f244487f083c235 100644 (file)
@@ -4,6 +4,9 @@
 <!-- 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>
 </suite>
diff --git a/tests/new/verifyError/Privilege.java b/tests/new/verifyError/Privilege.java
new file mode 100644 (file)
index 0000000..a49850f
--- /dev/null
@@ -0,0 +1,19 @@
+
+import org.aspectj.testing.Tester;
+
+class C {
+       private int i;
+}
+
+privileged aspect A {
+       private int C.j = 1;
+}
+
+/** @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");
+       }       
+}
+