]> source.dussan.org Git - aspectj.git/commitdiff
389678: overweaving test resources
authorAndy Clement <aclement@pivotal.io>
Mon, 21 Jan 2019 17:47:07 +0000 (09:47 -0800)
committerAndy Clement <aclement@pivotal.io>
Mon, 21 Jan 2019 17:47:07 +0000 (09:47 -0800)
tests/bugs193/389678/OverWeave_1/src/Application.java [new file with mode: 0644]
tests/bugs193/389678/OverWeave_1/src/MyAspect.aj [new file with mode: 0644]
tests/bugs193/389678/OverWeave_2/src/MyAspect2.aj [new file with mode: 0644]
tests/bugs193/389678/OverWeave_4/src/MyAspect3.aj [new file with mode: 0644]
tests/bugs193/389678/ow1.jar [new file with mode: 0644]
tests/bugs193/389678/ow2.jar [new file with mode: 0644]
tests/bugs193/389678/ow4.jar [new file with mode: 0644]
tests/bugs193/389678/run.sh [new file with mode: 0755]
tests/bugs193/389678/runow.sh [new file with mode: 0755]

diff --git a/tests/bugs193/389678/OverWeave_1/src/Application.java b/tests/bugs193/389678/OverWeave_1/src/Application.java
new file mode 100644 (file)
index 0000000..1d98f01
--- /dev/null
@@ -0,0 +1,9 @@
+public class Application {\r
+       public static void main(String[] args) {\r
+               sayHelloTo("world");\r
+       }\r
+\r
+       public static void sayHelloTo(String subject) {\r
+               System.out.println("Hello " + subject + "!");\r
+       }\r
+}\r
diff --git a/tests/bugs193/389678/OverWeave_1/src/MyAspect.aj b/tests/bugs193/389678/OverWeave_1/src/MyAspect.aj
new file mode 100644 (file)
index 0000000..cb9d420
--- /dev/null
@@ -0,0 +1,5 @@
+public aspect MyAspect {\r
+       before() : execution(* Application.*(..)) {\r
+               System.out.println(this.getClass().getName() + " -> " + thisJoinPointStaticPart);\r
+       }\r
+}\r
diff --git a/tests/bugs193/389678/OverWeave_2/src/MyAspect2.aj b/tests/bugs193/389678/OverWeave_2/src/MyAspect2.aj
new file mode 100644 (file)
index 0000000..b59a246
--- /dev/null
@@ -0,0 +1,5 @@
+public aspect MyAspect2 {\r
+       before() : execution(* *(..)) {\r
+               System.out.println(this.getClass().getName() + " -> " + thisJoinPointStaticPart);\r
+       }\r
+}\r
diff --git a/tests/bugs193/389678/OverWeave_4/src/MyAspect3.aj b/tests/bugs193/389678/OverWeave_4/src/MyAspect3.aj
new file mode 100644 (file)
index 0000000..2c40e42
--- /dev/null
@@ -0,0 +1,5 @@
+public aspect MyAspect3 {\r
+       before() : execution(* *(..)) {\r
+               System.out.println(this.getClass().getName() + " -> " + thisJoinPointStaticPart);\r
+       }\r
+}\r
diff --git a/tests/bugs193/389678/ow1.jar b/tests/bugs193/389678/ow1.jar
new file mode 100644 (file)
index 0000000..acb5cc6
Binary files /dev/null and b/tests/bugs193/389678/ow1.jar differ
diff --git a/tests/bugs193/389678/ow2.jar b/tests/bugs193/389678/ow2.jar
new file mode 100644 (file)
index 0000000..b04346f
Binary files /dev/null and b/tests/bugs193/389678/ow2.jar differ
diff --git a/tests/bugs193/389678/ow4.jar b/tests/bugs193/389678/ow4.jar
new file mode 100644 (file)
index 0000000..85f5a05
Binary files /dev/null and b/tests/bugs193/389678/ow4.jar differ
diff --git a/tests/bugs193/389678/run.sh b/tests/bugs193/389678/run.sh
new file mode 100755 (executable)
index 0000000..883bc7a
--- /dev/null
@@ -0,0 +1,10 @@
+echo "ow1"
+ajc -1.8 -sourceroots OverWeave_1/src -outjar ow1.jar -showWeaveInfo
+echo "ow2"
+ajc -1.8 -sourceroots OverWeave_2/src -outjar ow2.jar -showWeaveInfo
+echo "ow4 build"
+ajc -1.8 -sourceroots OverWeave_4/src -outjar ow4.jar -showWeaveInfo
+echo "ow3"
+ajc -1.8 -d out -inpath ow1.jar -aspectpath ow2.jar -showWeaveInfo -sourceroots OverWeave_3/src -outjar ow3.jar
+
+java -classpath out:/Users/aclement/installs/aspectj192/lib/aspectjrt.jar:ow2.jar  Application
diff --git a/tests/bugs193/389678/runow.sh b/tests/bugs193/389678/runow.sh
new file mode 100755 (executable)
index 0000000..c2ca8d3
--- /dev/null
@@ -0,0 +1,4 @@
+ajc -1.8 -sourceroots OverWeave_1/src -outjar ow1.jar
+ajc -1.8 -sourceroots OverWeave_2/src -outjar ow2.jar
+ajc -1.8 -Xset:overWeaving=true -d out -inpath ow1.jar -aspectpath ow2.jar -sourceroots OverWeave_3/src
+java -classpath out:/Users/aclement/installs/aspectj192/lib/aspectjrt.jar:ow2.jar  Application