June 23, 2011

Make Selenium RC run on FF 5

After upgrading from FF 3.6 to FF4 or 5...your selenium RC scripts  not running on FF.?


Here is the solution for that...

You need to do a simple thing..you have to Upgrade the old selenium-server file....to selenium-server-standalone-2.0rc3.

Here is the new server file New Selenium Server Jar File

Then replace the old file with new server file in eclipse..then restart your eclipse...Now your old scripts will run in FF4 or FF5.


19 comments:

  1. Hi,
    i get an UnsupportedClassVersionError: Bad version number in .class file at javava.lang.ClassLoader.defineClass1(Native Method).

    I can't launch the new standalone server.

    Any ideas ? Thanks


    Here is the log

    INFO: Launching a standalone server
    16:25:27.421 INFO - Java: Sun Microsystems Inc. 1.5.0_17-b04
    16:25:27.421 INFO - OS: Windows XP 5.1 x86
    16:25:27.453 INFO - v2.0 [rc3], with Core v2.0 [rc3]
    Exception in thread "main" java.lang.UnsupportedClassVersionError: Bad version n
    umber in .class file
    at java.lang.ClassLoader.defineClass1(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:12
    4)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
    at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:164)
    at org.openqa.selenium.remote.server.DefaultDriverSessions.registerDrive
    r(DefaultDriverSessions.java:76)
    at org.openqa.selenium.remote.server.DefaultDriverSessions.registerDefau
    lts(DefaultDriverSessions.java:67)
    at org.openqa.selenium.remote.server.DefaultDriverSessions.(Defaul
    tDriverSessions.java:56)
    at org.openqa.selenium.remote.server.DefaultDriverSessions.(Defaul
    tDriverSessions.java:51)
    at org.openqa.selenium.server.SeleniumServer.createWebDriverRemoteContex
    t(SeleniumServer.java:309)
    at org.openqa.selenium.server.SeleniumServer.assembleHandlers(SeleniumSe
    rver.java:295)
    at org.openqa.selenium.server.SeleniumServer.createJettyServer(SeleniumS
    erver.java:257)
    at org.openqa.selenium.server.SeleniumServer.(SeleniumServer.java:
    230)
    at org.openqa.selenium.server.SeleniumServer.main(SeleniumServer.java:19
    9)
    at org.openqa.grid.selenium.GridLauncher.main(GridLauncher.java:59)

    ReplyDelete
  2. Nice article , you have indeed cover the topic with great details. I have also documented my experience as how to resolve unsupportedclassversionerror in Java
    . let me know if you find it useful.

    ReplyDelete
  3. Thanks for the tip on "Make Selenium RC run on FF 5". Solved my problem.

    Regards,
    Satish

    ReplyDelete
    Replies
    1. can u please brifely explain me how u configure selenium rc so that it runs on firefox 5.
      please reply me on suresh6835@gmail.com

      Delete
  4. Yeah, Thank Guys it works!

    If you want to use it for tapestry-tests, you have to exclude the old selenium-server version and add the new 2.0rc3 Version!

    ReplyDelete
  5. This was very helpful , appreciate the help.

    ReplyDelete
  6. Also to add, Selenium 2.0 rc3 does NOT work fine with BEA jrockit 1.5, jdk 1.5.. Recommend using JRE6.

    ReplyDelete
  7. I am new to selenium, using selenium server2.3 and FF5 and I am not
    creating any custom profile for firefox5.Testing our application(web-
    based app).
    Issue:
    I constantly get stuck up with
    "com.thoughtworks.selenium.SeleniumException: ERROR: Threw an
    exception: Security error" when executing only a certain set of
    javascripts and there is no detailed explanation about this security
    Error, but the same works fine when i change the browser type from
    *firefox to *firefoxproxy.
    Note:When i tried to run the same set of javascripts through the
    javascript interpreter from the browser(FF5+Firebug) opened from
    selenium, i get successful results(No security Error)
    1.Not able to find the root cause for this Security Error.??
    2.I am not able to get the actual difference between *firefox and
    *firefoxproxy ??
    3.If i use *firefoxproxy as browsertype ,FF5 crashes when I run
    multiple test cases.!
    Kindle help me.! Even if it is a work around.!

    ReplyDelete
  8. Hi Nishok,

    Does your site starts with Https: ?? or Http? Send u r details to my mail ID.

    Thanks,
    Naga

    ReplyDelete
    Replies
    1. Hello sir,
      i am unable to run my script on firefox 5.
      Please guide me sir.
      i am not understood the meaning of selenium-server-standalone-2.0rc3.

      can i use selenium-server-standalone-2.19.0.jar
      please sir

      Delete
    2. u can use, but the FF13 will not work with server-standalone-2.19.0. go for server-standalone-2.25.0.

      Delete
  9. Hi Naga, nice blog, i´m trying to upgrade Selenese, but i dont know which .jar file i have to change exactly. on Eclipse only is java driver and TestNG as external libraries, so what´s wrong?, or just adding the "server-standalone.jar" it can works?

    thanks, kristian from Mexico
    ps. sorry for my english hehe

    ReplyDelete
  10. Hi Naga,

    I mailed ma details..

    Nishok

    ReplyDelete
  11. Hi Has anyone worked with Selenium RC and firefox 6.0. I am trying to run my selenium RC script again firefox 6.0. It just launches firefox and then remains Idle.

    I already upgraded my JRE version to 1.6.0_21 and selenium jars to 2.0. But didnt help much.

    Any thoughts ?

    ReplyDelete
  12. Why doesn't it work with selenium-server-standalone 2.0.0 or 2.5.0?
    I use DefaultSelenium.

    The FF5 window opens, but nothing happens.
    It seems like the window to control the browser is not being opened like with FF 3.6

    Thanks

    ReplyDelete
  13. Thanks its worked for us as well :) Good One

    ReplyDelete


  14. Here is my web blog ... payday loan online
    Have a look at my page :: payday loan,

    ReplyDelete
  15. I think this is one of the most significant information for me.
    And i am glad reading your article. But want to remark on some general things, The site style is perfect, the articles is really excellent :
    D. Good job, cheers

    Look into my website - the tao of badass

    ReplyDelete