diff options
author | mwebster <mwebster> | 2006-08-15 15:34:56 +0000 |
---|---|---|
committer | mwebster <mwebster> | 2006-08-15 15:34:56 +0000 |
commit | 3b517caf402c6d7c52d4bcbdc86c7528ab828ec9 (patch) | |
tree | 35747fa504d6694aae47bc22ce4e4f6f9920e5c2 /tests/ltw | |
parent | 82e3e13c66720ed17399821d478c31151b2d2234 (diff) | |
download | aspectj-3b517caf402c6d7c52d4bcbdc86c7528ab828ec9.tar.gz aspectj-3b517caf402c6d7c52d4bcbdc86c7528ab828ec9.zip |
Bug 153907 "Facilitate LTW testing in a custom ClassLoader hierarchy" (TestServer, TestServerTest and LTWServerTests)
Diffstat (limited to 'tests/ltw')
-rw-r--r-- | tests/ltw/Child.java | 9 | ||||
-rw-r--r-- | tests/ltw/Parent.java | 5 | ||||
-rw-r--r-- | tests/ltw/ant-server.xml | 33 | ||||
-rw-r--r-- | tests/ltw/server-helloworld.properties | 5 | ||||
-rw-r--r-- | tests/ltw/server-parentandchild.properties | 6 |
5 files changed, 58 insertions, 0 deletions
diff --git a/tests/ltw/Child.java b/tests/ltw/Child.java new file mode 100644 index 000000000..4719933f0 --- /dev/null +++ b/tests/ltw/Child.java @@ -0,0 +1,9 @@ +public class Child extends Parent { + public Child () { + System.out.println("Child"); + } + + public static void main (String[] args) { + new Child(); + } +}
\ No newline at end of file diff --git a/tests/ltw/Parent.java b/tests/ltw/Parent.java new file mode 100644 index 000000000..b239a9829 --- /dev/null +++ b/tests/ltw/Parent.java @@ -0,0 +1,5 @@ +public class Parent { + public Parent () { + System.out.println("Parent"); + } +}
\ No newline at end of file diff --git a/tests/ltw/ant-server.xml b/tests/ltw/ant-server.xml new file mode 100644 index 000000000..15ec3b945 --- /dev/null +++ b/tests/ltw/ant-server.xml @@ -0,0 +1,33 @@ +<!-- ajc-ant script, not to be used from Ant commant line - see AntSpec --> +<project name="ltw"> + + <!-- using this we can debug the forked VM --> + <property + name="jdwp" + value="-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005"/> + + <target name="TestServer with HelloWorld"> + <copy file="${aj.root}/tests/ltw/server-helloworld.properties" + tofile="${aj.sandbox}/server.properties"/> + <java fork="yes" classname="org.aspectj.testing.server.TestServer" failonerror="yes"> + <classpath refid="aj.path"/> + <jvmarg value="-javaagent:${aj.root}/lib/test/loadtime5.jar"/> + <jvmarg value="-Daj.weaving.verbose=true"/> + <jvmarg value="-Dorg.aspectj.weaver.showWeaveInfo=true"/> + <arg path="${aj.sandbox}"/> + </java> + </target> + + <target name="TestServer with Parent and Child"> + <copy file="${aj.root}/tests/ltw/server-parentandchild.properties" + tofile="${aj.sandbox}/server.properties"/> + <java fork="yes" classname="org.aspectj.testing.server.TestServer" failonerror="yes"> + <classpath refid="aj.path"/> + <jvmarg value="-javaagent:${aj.root}/lib/test/loadtime5.jar"/> + <jvmarg value="-Daj.weaving.verbose=true"/> + <jvmarg value="-Dorg.aspectj.weaver.showWeaveInfo=true"/> + <arg path="${aj.sandbox}"/> + </java> + </target> + +</project> diff --git a/tests/ltw/server-helloworld.properties b/tests/ltw/server-helloworld.properties new file mode 100644 index 000000000..baf42dbe0 --- /dev/null +++ b/tests/ltw/server-helloworld.properties @@ -0,0 +1,5 @@ +# loader.XXX=Name,Classpath[,Parent] +loader.application=Application,hello.jar;handler.jar + +# main=Class,Loader +main=HelloWorld,Application
\ No newline at end of file diff --git a/tests/ltw/server-parentandchild.properties b/tests/ltw/server-parentandchild.properties new file mode 100644 index 000000000..d0a7af85e --- /dev/null +++ b/tests/ltw/server-parentandchild.properties @@ -0,0 +1,6 @@ +# loader.XXX=Name,Classpath[,Parent] +loader.parent=Parent,parent.jar +loader.child=Child,child.jar,Parent + +# main=Class,Loader +main=Child,Child
\ No newline at end of file |