Please find the code below which i am running from Ant :
@Test
public void Browser() {
FirefoxDriver driver=new FirefoxDriver();
driver.get("http://flipkart.com");
driver.quit();
}
I am trying to launch browser and generating XSLT reports for the same.
Which version of firefox and selenium are you using
I am sure you havnt kept all jars of selenium under class path
Sir,
I am using Selenium 2.53.0 and Firefox version is 46.0.1.
For to be on safer side i have added all the jars to my project which is provided by you. (\\Selenium_Pack_Nov\jars).
Now am getting following error :
[color=#FF4080:v84mhcaq]org.openqa.selenium.WebDriverException: org.openqa.selenium.WebDriverException: Unable to bind to locking port 7054 within
45000 ms[/color:v84mhcaq]
System info: os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1', java.version: '1.8.0_111'
Driver info: driver.version: firefox
System info: os.name: 'Windows 7', os.arch: 'x86', os.version: '6.1', java.version: '1.8.0_111'
Driver info: driver.version: firefox
at org.openqa.selenium.firefox.internal.ExtensionConnectionFactory.connectTo(ExtensionConnectionFactory.java:46)
at org.openqa.selenium.firefox.FirefoxDriver.connectTo(FirefoxDriver.java:139)
at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:129)
at org.openqa.selenium.firefox.FirefoxDriver.<init>(FirefoxDriver.java:109)
at test.NewTest.Browser(NewTest.java:10)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.testng.internal.Met
Any suggestions to resolve the error
[color=#BF0000:24ygfgea]"org.openqa.selenium.WebDriverException: org.openqa.selenium.WebDriverException: Unable to bind to locking port 7054 within 45000 ms"[/color:24ygfgea]
Reduced to FF 43.. Still same issue am facing.
Please guide me sir.
How to sync Selenium, TestNg,Eclipse, JDK and Browser versions all together .Really confusing
just hit and try selenium with different versions of firefox.
every selenium version only works with few specific versions of firefox. to find these versions you hit and try a different version.
[quote:16s6h8s2]How to sync Selenium, TestNg,Eclipse, JDK and Browser versions all together .Really confusing
[/quote:16s6h8s2]
let's not get ahead of ourselves.
Hi,
I am also facing same issue-Not able to launch Firefox using ANT and TestNG. Getting "java.lang.IncompatibleClassChangeError" in my code.
Were you able to identify the cause? Could you please let me know the solution.
Thanks in Advance.
Trying this code
public class launchfirefox {
@Test
public void launchMozilla(){
System.setProperty("webdriver.gecko.driver","C:/Tools/TestingTools/selenium/geckodriver.exe");
WebDriver driver=new FirefoxDriver();
driver.get("http://gmail.com");
}
}
firefox version 52.0.2
Selenium version 3.0.1
Attached are the screenshot of the report and cmd prompt.
Please let me know if any other details required.
Thanks