--- /dev/null
+import org.aspectj.lang.annotation.*;
+
+public @Aspect class Bug {
+ @Pointcut("args(i) && if() && within(Foo)")
+ public static boolean pc(int i) {
+ return i < 0;
+ }
+
+ @Before("pc(*)")
+ public void advice() { System.out.println("advice running");}
+
+ public static void main(String []argv) {
+ new Foo().trigger(-1);
+ new Foo().trigger(+1);
+ }
+}
+
+class Foo {
+ public void trigger(int i) {}
+}
+
public void testArgNamesDoesNotWork_pr148381_2() { runTest("argNames does not work - error1");}
public void testArgNamesDoesNotWork_pr148381_3() { runTest("argNames does not work - error2");}
public void testArgNamesDoesNotWork_pr148381_4() { runTest("argNames does not work - error3");}
- //public void testAsteriskInAtPointcut_pr209051() { runTest("asterisk in at aj pointcut");}
public void testDecpProblemWhenTargetAlreadyImplements_pr169432_1() { runTest("declare parents problem when target already implements interface - 1");}
public void testDecpProblemWhenTargetAlreadyImplements_pr169432_2() { runTest("declare parents problem when target already implements interface - 2");}
public void testDecpProblemWhenTargetAlreadyImplements_pr169432_3() { runTest("declare parents problem when target already implements interface - 3");}
<stdout/>
</run>
</ajc-test>
-
- <ajc-test dir="bugs154/pr209051" title="asterisk in at aj pointcut">
- <compile options="-1.5" files="Bug.java"/>
- <run class="Bug">
- <stdout>
- <line text="x"/>
- </stdout>
- </run>
- </ajc-test>
<!-- very basic with all code style, should be fine -->
<ajc-test dir="bugs154/pr209019/case1" title="various issues with ltw and around advice - 1">
public class Ajc162Tests extends org.aspectj.testing.XMLBasedAjcTestCase {
// AspectJ1.6.2
+// public void testStarInAnnoStyle_pr209951() { runTest("asterisk in at aj pointcut"); }
public void testMissingMarkers_pr197720() { runTest("missing markers on inherited annotated method"); }
public void testLostGenericsSigOnItd_pr211146() { runTest("lost generic sig on itd"); }
public void testLostGenericsSigOnItd_pr211146_2() { runTest("lost generic sig on itd - 2"); }
<!-- AspectJ v1.6.2 Tests -->
<suite>
+
+ <ajc-test dir="bugs162/pr209051" title="asterisk in at aj pointcut">
+ <compile options="-1.5" files="Bug.java"/>
+ <run class="Bug">
+ <stdout>
+ <line text="x"/>
+ </stdout>
+ </run>
+ </ajc-test>
+
<ajc-test dir="bugs162/pr197720" title="missing markers on inherited annotated method">
<compile files="C1.java C2.java C3.java MyAnn.java MyAnnAspect.java" options="-1.5 -showWeaveInfo">
<message kind="weave" text="Join point 'method-call(void test.aspects.C1.aMethod())' in Type 'test.aspects.C1' (C1.java:12) advised by around advice from 'test.aspects.MyAnnAspect' (MyAnnAspect.java:16)"/>