You can find the full source code for this website in the Seam package in the directory /examples/wiki. It is licensed under the LGPL.
| Online: | 17 Members of 4546 |
| Forum: Seam Users |
10. Mar 2008, 10:34 CET | Link |
Running ant test on any of the examples e.g. booking throws exceptions at me.
test: [testng] [Parser] Running: [testng] C:\java\jboss-seam-2.0.1.GA\examples\booking\src\org\jboss\seam\example\booking\test\testng.xml [testng] [testng] ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Described: name=BeanDeployer state=PreInstall [testng] java.lang.RuntimeException: java.lang.reflect.UndeclaredThrowableException [testng] at org.jboss.aop.util.ClassInfoMethodHashing.methodHash(ClassInfoMethodHashing.java:70) [testng] at org.jboss.aop.util.ClassInfoMethodHashing.addDeclaredMethods(ClassInfoMethodHashing.java:169) [testng] at org.jboss.aop.util.ClassInfoMethodHashing.populateMethodTables(ClassInfoMethodHashing.java:182)
Anyone know why?
I'm using
java 1.6.0, Apache Ant 1.7.0, seam 2.0.1.GA
I was using JDK 6. Using JDK 5 I can now run the tests.
It is however stated in the documenation at
2.0.1.GA reference
that I could use JDK6, which is very confusing.
Now I however have a new problem running tests on a new project created with the seam generator.
The exception is
What can I do so the class is found?
I think Seam can run on jdk5, but embedded jboss must be running on jdk5.
http://docs.jboss.com/seam/latest/reference/en/html/configuration.html
The test suit might use embedded jboss?
Edit:
On JDK 6 I could run all the examples on the server. The only thing I couldn't was run the tests.
What I don't get is that after changing to JDK5, the tests in the bundled examples work, but when I create a new project with the seam generator and create a action with the generator and run the test it gives me the exception above.
Jars from the lib/test was not included, by the build script generated by seam, when testing. So the information in the documentation
or the seam gen needs to be altered.
Is no one using this script? Or just not testing? Or just not reading this post:) Since everybody would have changed this.
They most certainly are in Seam 2.0.1.GA (which you say you are running).
Read about how to report a bug.
As mentioned before I get
when running ant test. Fixed it by including the jars in the build script when running the target.
Running
might fail with exceptions like 'class not found' if you are running an existing instance of jboss server in the background.. So you might want to check that out.. with best regards,@Jakob,
Could you tell us the changes you made in the build script, so we can do the same to overcome the error?
I added the following in the build.xml file after the path setup for build.classpath
<path id="test.classpath"> <fileset id="lib.test" dir="${lib.dir}/test"> <include name="*.jar" /> </fileset> </path>At the 'test' target I added the following entry to the class path entries for testng:
Running 'ant test' then has the following error:
Do I need to regenerate the project since changing back to JDK 1.5 ?
Has anyone else been able to test a seam-gen generated project?
All is working now
Installed jboss-seam-2.0.2.CR1, created a project, created and action and ran 'ant test'.
I am also running jdk1.5.0-15
No modifications to build.xml required.