Selenium RC stopped working

16 views
Skip to first unread message

jp

unread,
Oct 14, 2009, 9:47:47 PM10/14/09
to selenium-users...@googlegroups.com
I was able to get my java selenium code to work when running it as a stand alone application.

Now I'm trying to get it to work on a java tomcat server but I'm getting this error message:

{code:java}Exception in thread "Thread-8" java.lang.NoClassDefFoundError: com/thoughtworks/selenium/SeleniumException\\ \\     at utils.RegistrationProcessor.run(RegistrationProcessor.java:23)\\ \\     at java.lang.Thread.run(Unknown Source)\\ \\ Caused by: java.lang.ClassNotFoundException: com.thoughtworks.selenium.SeleniumException\\ \\     at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1387)\\ \\     at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1233)\\ \\     at java.lang.ClassLoader.loadClassInternal(Unknown Source)\\ \\     ... 2 more{code}
RegistrationProcessor is a class I wrote and on line 23 of that class it's creating an instance of a class that will perform the Selenium code.  I've included all of the jars into the build path like before.  Is there something different because I'm running it as a server?

jp

unread,
Oct 17, 2009, 3:05:19 PM10/17/09
to selenium-users...@googlegroups.com
Any ideas yet?  I thought maybe it would have something to do with how the server configuration (I'm using Eclipse) handles JAR files but I'm using other external JARs as well and I don't seem to have any problems with that.

shraddha

unread,
Oct 21, 2009, 7:10:31 AM10/21/09
to selenium-users...@googlegroups.com
Hi JP,

It doesnot matter for selenium whether you are running your application as a stand alone or a web service.
As you know java  follows  MVC arcitecture.
In a stand alone application you donot have a controller which will be communicating with ur front end and back end where as web service you do conatin one.
So selenium is no way concerened with the back-end of the application you have used.
So as far as adding jars are concerned in eclipse follow the below mentioned step.
1.Right click on build path and add
Selenium java client driver jar and Junit jar(if using junit framework) as external jars to your java project.

Revert back if you have any doubt.add the code snippets for reference.

Thanks!
Shraddha

Reply all
Reply to author
Forward
0 new messages