I am using Selenium to test a website in Java and trying to run it in Firefox on a MAC. But when I am trying to execute the code below
Selenium selenium = new DefaultSelenium("localhost", 4444, "*firefox", "http://www.example.com/");
I am getting the following runtime exception
java.lang.RuntimeException: Could not start Selenium session: Failed to start new browser session: Browser not supported: /Users/sumitghosh/Desktop/*firefox3
(Did you forget to add a *?)
Supported browsers include:
*firefox
*mock
*firefoxproxy
*pifirefox
*chrome
*iexploreproxy
*iexplore
*firefox3
*safariproxy
*googlechrome
*konqueror
*firefox2
*safari
*piiexplore
*firefoxchrome
*opera
*iehta
*custom
I have also tried changing the browser to *googlechrome
, but the same error was firing!
But when *safari
was used it ran successfully.
Since I want the application to run on Windows and MAC also, I was trying for *firefox
or *googlechrome
to run, but both browsers are giving exceptions both on Windows and MAC!
I have only ever got firefox 3.X to work on MACOSX with selenium.
Try downloading and installing a 3.X version (I got 3.18 to work).
Instead of "*firefox"
you can try "*firefox /Apps/Firefox/firefox.exe"
or any other absolute path to the file firefox.exe which works for your computer.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With