From 499b8bcb0e89b39a63008fc68b44df9ed39d0750 Mon Sep 17 00:00:00 2001 From: aclement Date: Thu, 18 Oct 2007 11:02:00 +0000 Subject: [PATCH] these tests are now for 1.5.4, not 1.6.0 --- tests/{bugs160 => bugs154}/pr165631/Bug.java | 0 tests/{bugs160 => bugs154}/pr165631/Bug2.java | 0 .../pr165885/Abstract.java | 0 .../{bugs160 => bugs154}/pr165885/Aspect.java | 0 .../pr165885/Concrete.java | 0 .../{bugs160 => bugs154}/pr166084/Simple.java | 0 tests/{bugs160 => bugs154}/pr166084/X.java | 0 .../{bugs160 => bugs154}/pr166084/simple.jar | Bin .../pr168044/AbstractNode.java | 0 tests/{bugs160 => bugs154}/pr168063/A.java | 0 tests/{bugs160 => bugs154}/pr169706/A.java | 0 tests/{bugs160 => bugs154}/pr169706/B.java | 0 tests/{bugs160 => bugs154}/pr169706/C.java | 0 .../pr169706/MyAnnotation.java | 0 .../pr169706/MyAspect.java | 0 tests/{bugs160 => bugs154}/pr169706/Test.java | 0 tests/{bugs160 => bugs154}/pr170467/Bug.aj | 0 tests/{bugs160 => bugs154}/pr170467/Bug2.aj | 0 tests/{bugs160 => bugs154}/pr171952/Foo.java | 0 .../pr171952/FooAspect.java | 0 .../pr171953/test/AbstractExecutable.java | 0 .../pr171953/test/AnotherExecutable.java | 0 .../pr171953/test/Executable.java | 0 .../pr171953/test/ExecutionAspect.aj | 0 .../pr171953/test/RunnableAspect.aj | 0 .../pr171953/test/SecondTestExecutable.java | 0 .../pr171953/test/SubTestExecutable.java | 0 .../pr171953/test/TestExecutable.java | 0 .../pr171953_2/test/AbstractProcessor.java | 0 .../pr171953_2/test/ListFactory.java | 0 .../pr171953_2/test/ListFactoryAspect.aj | 0 .../pr171953_2/test/ListFactoryConsumer.java | 0 .../pr171953_2/test/Processor.java | 0 .../test/SimpleListFactoryConsumer.java | 0 .../pr172107/Instrumentation.aj | 0 .../pr172107/ReadWriteAJBug172107.java | 0 tests/{bugs160 => bugs154}/pr174449/Foo.java | 0 tests/{bugs160 => bugs154}/pr175806/A.java | 0 tests/bugs154/pr197719/test/aspects/C1.java | 14 ++++++ tests/bugs154/pr197719/test/aspects/C3.java | 43 ++++++++++++++++++ .../bugs154/pr197719/test/aspects/MyAnn.java | 13 ++++++ .../pr197719/test/aspects/MyAnnAspect.java | 24 ++++++++++ tests/bugs154/pr197719/test/aspects2/C2.java | 34 ++++++++++++++ tests/bugs154/pr205907/Test.aj | 6 +++ tests/bugs154/pr206732/Advised.aj | 12 +++++ tests/bugs154/pr206732/Ref.aj | 17 +++++++ 46 files changed, 163 insertions(+) rename tests/{bugs160 => bugs154}/pr165631/Bug.java (100%) rename tests/{bugs160 => bugs154}/pr165631/Bug2.java (100%) rename tests/{bugs160 => bugs154}/pr165885/Abstract.java (100%) rename tests/{bugs160 => bugs154}/pr165885/Aspect.java (100%) rename tests/{bugs160 => bugs154}/pr165885/Concrete.java (100%) rename tests/{bugs160 => bugs154}/pr166084/Simple.java (100%) rename tests/{bugs160 => bugs154}/pr166084/X.java (100%) rename tests/{bugs160 => bugs154}/pr166084/simple.jar (100%) rename tests/{bugs160 => bugs154}/pr168044/AbstractNode.java (100%) rename tests/{bugs160 => bugs154}/pr168063/A.java (100%) rename tests/{bugs160 => bugs154}/pr169706/A.java (100%) rename tests/{bugs160 => bugs154}/pr169706/B.java (100%) rename tests/{bugs160 => bugs154}/pr169706/C.java (100%) rename tests/{bugs160 => bugs154}/pr169706/MyAnnotation.java (100%) rename tests/{bugs160 => bugs154}/pr169706/MyAspect.java (100%) rename tests/{bugs160 => bugs154}/pr169706/Test.java (100%) rename tests/{bugs160 => bugs154}/pr170467/Bug.aj (100%) rename tests/{bugs160 => bugs154}/pr170467/Bug2.aj (100%) rename tests/{bugs160 => bugs154}/pr171952/Foo.java (100%) rename tests/{bugs160 => bugs154}/pr171952/FooAspect.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/AbstractExecutable.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/AnotherExecutable.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/Executable.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/ExecutionAspect.aj (100%) rename tests/{bugs160 => bugs154}/pr171953/test/RunnableAspect.aj (100%) rename tests/{bugs160 => bugs154}/pr171953/test/SecondTestExecutable.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/SubTestExecutable.java (100%) rename tests/{bugs160 => bugs154}/pr171953/test/TestExecutable.java (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/AbstractProcessor.java (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/ListFactory.java (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/ListFactoryAspect.aj (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/ListFactoryConsumer.java (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/Processor.java (100%) rename tests/{bugs160 => bugs154}/pr171953_2/test/SimpleListFactoryConsumer.java (100%) rename tests/{bugs160 => bugs154}/pr172107/Instrumentation.aj (100%) rename tests/{bugs160 => bugs154}/pr172107/ReadWriteAJBug172107.java (100%) rename tests/{bugs160 => bugs154}/pr174449/Foo.java (100%) rename tests/{bugs160 => bugs154}/pr175806/A.java (100%) create mode 100644 tests/bugs154/pr197719/test/aspects/C1.java create mode 100644 tests/bugs154/pr197719/test/aspects/C3.java create mode 100644 tests/bugs154/pr197719/test/aspects/MyAnn.java create mode 100644 tests/bugs154/pr197719/test/aspects/MyAnnAspect.java create mode 100644 tests/bugs154/pr197719/test/aspects2/C2.java create mode 100644 tests/bugs154/pr205907/Test.aj create mode 100644 tests/bugs154/pr206732/Advised.aj create mode 100644 tests/bugs154/pr206732/Ref.aj diff --git a/tests/bugs160/pr165631/Bug.java b/tests/bugs154/pr165631/Bug.java similarity index 100% rename from tests/bugs160/pr165631/Bug.java rename to tests/bugs154/pr165631/Bug.java diff --git a/tests/bugs160/pr165631/Bug2.java b/tests/bugs154/pr165631/Bug2.java similarity index 100% rename from tests/bugs160/pr165631/Bug2.java rename to tests/bugs154/pr165631/Bug2.java diff --git a/tests/bugs160/pr165885/Abstract.java b/tests/bugs154/pr165885/Abstract.java similarity index 100% rename from tests/bugs160/pr165885/Abstract.java rename to tests/bugs154/pr165885/Abstract.java diff --git a/tests/bugs160/pr165885/Aspect.java b/tests/bugs154/pr165885/Aspect.java similarity index 100% rename from tests/bugs160/pr165885/Aspect.java rename to tests/bugs154/pr165885/Aspect.java diff --git a/tests/bugs160/pr165885/Concrete.java b/tests/bugs154/pr165885/Concrete.java similarity index 100% rename from tests/bugs160/pr165885/Concrete.java rename to tests/bugs154/pr165885/Concrete.java diff --git a/tests/bugs160/pr166084/Simple.java b/tests/bugs154/pr166084/Simple.java similarity index 100% rename from tests/bugs160/pr166084/Simple.java rename to tests/bugs154/pr166084/Simple.java diff --git a/tests/bugs160/pr166084/X.java b/tests/bugs154/pr166084/X.java similarity index 100% rename from tests/bugs160/pr166084/X.java rename to tests/bugs154/pr166084/X.java diff --git a/tests/bugs160/pr166084/simple.jar b/tests/bugs154/pr166084/simple.jar similarity index 100% rename from tests/bugs160/pr166084/simple.jar rename to tests/bugs154/pr166084/simple.jar diff --git a/tests/bugs160/pr168044/AbstractNode.java b/tests/bugs154/pr168044/AbstractNode.java similarity index 100% rename from tests/bugs160/pr168044/AbstractNode.java rename to tests/bugs154/pr168044/AbstractNode.java diff --git a/tests/bugs160/pr168063/A.java b/tests/bugs154/pr168063/A.java similarity index 100% rename from tests/bugs160/pr168063/A.java rename to tests/bugs154/pr168063/A.java diff --git a/tests/bugs160/pr169706/A.java b/tests/bugs154/pr169706/A.java similarity index 100% rename from tests/bugs160/pr169706/A.java rename to tests/bugs154/pr169706/A.java diff --git a/tests/bugs160/pr169706/B.java b/tests/bugs154/pr169706/B.java similarity index 100% rename from tests/bugs160/pr169706/B.java rename to tests/bugs154/pr169706/B.java diff --git a/tests/bugs160/pr169706/C.java b/tests/bugs154/pr169706/C.java similarity index 100% rename from tests/bugs160/pr169706/C.java rename to tests/bugs154/pr169706/C.java diff --git a/tests/bugs160/pr169706/MyAnnotation.java b/tests/bugs154/pr169706/MyAnnotation.java similarity index 100% rename from tests/bugs160/pr169706/MyAnnotation.java rename to tests/bugs154/pr169706/MyAnnotation.java diff --git a/tests/bugs160/pr169706/MyAspect.java b/tests/bugs154/pr169706/MyAspect.java similarity index 100% rename from tests/bugs160/pr169706/MyAspect.java rename to tests/bugs154/pr169706/MyAspect.java diff --git a/tests/bugs160/pr169706/Test.java b/tests/bugs154/pr169706/Test.java similarity index 100% rename from tests/bugs160/pr169706/Test.java rename to tests/bugs154/pr169706/Test.java diff --git a/tests/bugs160/pr170467/Bug.aj b/tests/bugs154/pr170467/Bug.aj similarity index 100% rename from tests/bugs160/pr170467/Bug.aj rename to tests/bugs154/pr170467/Bug.aj diff --git a/tests/bugs160/pr170467/Bug2.aj b/tests/bugs154/pr170467/Bug2.aj similarity index 100% rename from tests/bugs160/pr170467/Bug2.aj rename to tests/bugs154/pr170467/Bug2.aj diff --git a/tests/bugs160/pr171952/Foo.java b/tests/bugs154/pr171952/Foo.java similarity index 100% rename from tests/bugs160/pr171952/Foo.java rename to tests/bugs154/pr171952/Foo.java diff --git a/tests/bugs160/pr171952/FooAspect.java b/tests/bugs154/pr171952/FooAspect.java similarity index 100% rename from tests/bugs160/pr171952/FooAspect.java rename to tests/bugs154/pr171952/FooAspect.java diff --git a/tests/bugs160/pr171953/test/AbstractExecutable.java b/tests/bugs154/pr171953/test/AbstractExecutable.java similarity index 100% rename from tests/bugs160/pr171953/test/AbstractExecutable.java rename to tests/bugs154/pr171953/test/AbstractExecutable.java diff --git a/tests/bugs160/pr171953/test/AnotherExecutable.java b/tests/bugs154/pr171953/test/AnotherExecutable.java similarity index 100% rename from tests/bugs160/pr171953/test/AnotherExecutable.java rename to tests/bugs154/pr171953/test/AnotherExecutable.java diff --git a/tests/bugs160/pr171953/test/Executable.java b/tests/bugs154/pr171953/test/Executable.java similarity index 100% rename from tests/bugs160/pr171953/test/Executable.java rename to tests/bugs154/pr171953/test/Executable.java diff --git a/tests/bugs160/pr171953/test/ExecutionAspect.aj b/tests/bugs154/pr171953/test/ExecutionAspect.aj similarity index 100% rename from tests/bugs160/pr171953/test/ExecutionAspect.aj rename to tests/bugs154/pr171953/test/ExecutionAspect.aj diff --git a/tests/bugs160/pr171953/test/RunnableAspect.aj b/tests/bugs154/pr171953/test/RunnableAspect.aj similarity index 100% rename from tests/bugs160/pr171953/test/RunnableAspect.aj rename to tests/bugs154/pr171953/test/RunnableAspect.aj diff --git a/tests/bugs160/pr171953/test/SecondTestExecutable.java b/tests/bugs154/pr171953/test/SecondTestExecutable.java similarity index 100% rename from tests/bugs160/pr171953/test/SecondTestExecutable.java rename to tests/bugs154/pr171953/test/SecondTestExecutable.java diff --git a/tests/bugs160/pr171953/test/SubTestExecutable.java b/tests/bugs154/pr171953/test/SubTestExecutable.java similarity index 100% rename from tests/bugs160/pr171953/test/SubTestExecutable.java rename to tests/bugs154/pr171953/test/SubTestExecutable.java diff --git a/tests/bugs160/pr171953/test/TestExecutable.java b/tests/bugs154/pr171953/test/TestExecutable.java similarity index 100% rename from tests/bugs160/pr171953/test/TestExecutable.java rename to tests/bugs154/pr171953/test/TestExecutable.java diff --git a/tests/bugs160/pr171953_2/test/AbstractProcessor.java b/tests/bugs154/pr171953_2/test/AbstractProcessor.java similarity index 100% rename from tests/bugs160/pr171953_2/test/AbstractProcessor.java rename to tests/bugs154/pr171953_2/test/AbstractProcessor.java diff --git a/tests/bugs160/pr171953_2/test/ListFactory.java b/tests/bugs154/pr171953_2/test/ListFactory.java similarity index 100% rename from tests/bugs160/pr171953_2/test/ListFactory.java rename to tests/bugs154/pr171953_2/test/ListFactory.java diff --git a/tests/bugs160/pr171953_2/test/ListFactoryAspect.aj b/tests/bugs154/pr171953_2/test/ListFactoryAspect.aj similarity index 100% rename from tests/bugs160/pr171953_2/test/ListFactoryAspect.aj rename to tests/bugs154/pr171953_2/test/ListFactoryAspect.aj diff --git a/tests/bugs160/pr171953_2/test/ListFactoryConsumer.java b/tests/bugs154/pr171953_2/test/ListFactoryConsumer.java similarity index 100% rename from tests/bugs160/pr171953_2/test/ListFactoryConsumer.java rename to tests/bugs154/pr171953_2/test/ListFactoryConsumer.java diff --git a/tests/bugs160/pr171953_2/test/Processor.java b/tests/bugs154/pr171953_2/test/Processor.java similarity index 100% rename from tests/bugs160/pr171953_2/test/Processor.java rename to tests/bugs154/pr171953_2/test/Processor.java diff --git a/tests/bugs160/pr171953_2/test/SimpleListFactoryConsumer.java b/tests/bugs154/pr171953_2/test/SimpleListFactoryConsumer.java similarity index 100% rename from tests/bugs160/pr171953_2/test/SimpleListFactoryConsumer.java rename to tests/bugs154/pr171953_2/test/SimpleListFactoryConsumer.java diff --git a/tests/bugs160/pr172107/Instrumentation.aj b/tests/bugs154/pr172107/Instrumentation.aj similarity index 100% rename from tests/bugs160/pr172107/Instrumentation.aj rename to tests/bugs154/pr172107/Instrumentation.aj diff --git a/tests/bugs160/pr172107/ReadWriteAJBug172107.java b/tests/bugs154/pr172107/ReadWriteAJBug172107.java similarity index 100% rename from tests/bugs160/pr172107/ReadWriteAJBug172107.java rename to tests/bugs154/pr172107/ReadWriteAJBug172107.java diff --git a/tests/bugs160/pr174449/Foo.java b/tests/bugs154/pr174449/Foo.java similarity index 100% rename from tests/bugs160/pr174449/Foo.java rename to tests/bugs154/pr174449/Foo.java diff --git a/tests/bugs160/pr175806/A.java b/tests/bugs154/pr175806/A.java similarity index 100% rename from tests/bugs160/pr175806/A.java rename to tests/bugs154/pr175806/A.java diff --git a/tests/bugs154/pr197719/test/aspects/C1.java b/tests/bugs154/pr197719/test/aspects/C1.java new file mode 100644 index 000000000..363c79a93 --- /dev/null +++ b/tests/bugs154/pr197719/test/aspects/C1.java @@ -0,0 +1,14 @@ +package test.aspects; + +public class C1 { + + @MyAnn + protected void aMethod() { + System.out.println("Calling aMethod"); + } + + public void callAMethod() { + aMethod(); // Should be a marker here... + } + +} diff --git a/tests/bugs154/pr197719/test/aspects/C3.java b/tests/bugs154/pr197719/test/aspects/C3.java new file mode 100644 index 000000000..abcde9b58 --- /dev/null +++ b/tests/bugs154/pr197719/test/aspects/C3.java @@ -0,0 +1,43 @@ +package test.aspects; + +import test.aspects2.C2; + + +public class C3 { + /* + public void callAMethodC2() { + C1 c1 = new C1(); + c1.aMethod(); // Should be a marker here... + + C2 c2 = new C2(); + c2.aMethod(); // Should be a marker here... + } + + public void innerClassCall() { + InnerClass ic = new InnerClass(); + + ic.foo(); + } + protected class InnerClass { + public void foo() { + C1 c1 = new C1(); + c1.aMethod(); // Should be a marker here... + + C2 c2 = new C2(); + c2.aMethod(); // Should be a marker here... + } + } + + public static void main(String [] args) { + C1 c1 = new C1(); + + c1.aMethod(); // Should be a marker here... + c1.callAMethod(); + + C3 c2 = new C3(); + + c2.callAMethodC2(); + c2.innerClassCall(); + } + */ +} diff --git a/tests/bugs154/pr197719/test/aspects/MyAnn.java b/tests/bugs154/pr197719/test/aspects/MyAnn.java new file mode 100644 index 000000000..6610201b8 --- /dev/null +++ b/tests/bugs154/pr197719/test/aspects/MyAnn.java @@ -0,0 +1,13 @@ +package test.aspects; + +import java.lang.annotation.ElementType; +import java.lang.annotation.Inherited; +import java.lang.annotation.Retention; +import java.lang.annotation.RetentionPolicy; +import java.lang.annotation.Target; + +@Inherited +@Retention(RetentionPolicy.RUNTIME) +@Target(ElementType.METHOD) +public @interface MyAnn { +} diff --git a/tests/bugs154/pr197719/test/aspects/MyAnnAspect.java b/tests/bugs154/pr197719/test/aspects/MyAnnAspect.java new file mode 100644 index 000000000..e29619767 --- /dev/null +++ b/tests/bugs154/pr197719/test/aspects/MyAnnAspect.java @@ -0,0 +1,24 @@ +package test.aspects; + +import org.aspectj.lang.ProceedingJoinPoint; +import org.aspectj.lang.annotation.Around; +import org.aspectj.lang.annotation.Aspect; +import org.aspectj.lang.annotation.Pointcut; + +@Aspect +public class MyAnnAspect { + + @Pointcut("call(@MyAnn * *(..))") + void validatedMethod() {} + + + @Around("validatedMethod()") + public Object validateMethodImpl(ProceedingJoinPoint thisJoinPoint) throws Throwable { + return doInvoke(thisJoinPoint); + } + + private Object doInvoke(final ProceedingJoinPoint thisJoinPoint) throws Throwable { + System.out.println("Invoking : " + thisJoinPoint); + return thisJoinPoint.proceed(); + } +} diff --git a/tests/bugs154/pr197719/test/aspects2/C2.java b/tests/bugs154/pr197719/test/aspects2/C2.java new file mode 100644 index 000000000..799e7ac75 --- /dev/null +++ b/tests/bugs154/pr197719/test/aspects2/C2.java @@ -0,0 +1,34 @@ +package test.aspects2; + +import test.aspects.C1; + + +public class C2 extends C1 { + public void callAMethodC2() { + aMethod(); // Should be a marker here... + } + + public void innerClassCall() { + InnerClass ic = new InnerClass(); + + ic.foo(); + } + protected class InnerClass { + public void foo() { + aMethod(); // Should be a marker here... + } + } + + public static void main(String [] args) { + C1 c1 = new C1(); + + c1.callAMethod(); + + C2 c2 = new C2(); + + c2.aMethod(); // Should be a marker here... + c2.callAMethod(); + c2.callAMethodC2(); + c2.innerClassCall(); + } +} diff --git a/tests/bugs154/pr205907/Test.aj b/tests/bugs154/pr205907/Test.aj new file mode 100644 index 000000000..c06be67b2 --- /dev/null +++ b/tests/bugs154/pr205907/Test.aj @@ -0,0 +1,6 @@ +aspect Test { + + pointcut p(): bean(foo*); + + before(): p() { } +} \ No newline at end of file diff --git a/tests/bugs154/pr206732/Advised.aj b/tests/bugs154/pr206732/Advised.aj new file mode 100644 index 000000000..1e3abf13f --- /dev/null +++ b/tests/bugs154/pr206732/Advised.aj @@ -0,0 +1,12 @@ +package bugs; + + + +public class Advised {} + +aspect ITD { + + public void Advised.f() {} + +} + diff --git a/tests/bugs154/pr206732/Ref.aj b/tests/bugs154/pr206732/Ref.aj new file mode 100644 index 000000000..85f6f42e5 --- /dev/null +++ b/tests/bugs154/pr206732/Ref.aj @@ -0,0 +1,17 @@ +package notbugs; + + + +import bugs.Advised; + + + +public class Ref { + + public void g() { + + new Advised().f(); + + } + +} \ No newline at end of file -- 2.39.5