Checkout our demo site to practice selenium https://magento.softwaretestingboard.com/

1 like 0 dislike
441 views
by
edited by

where i need to set the property?

public class wpLogin {

//System.setProperty("webdriver.gecko.driver","D:\\rs\\Softwares\\selenium_SW\\Sel_3.0.1\\geckodriver-v0.11.1-win64\\geckodriver.exe");

WebDriver driver;

public void main(String username, String password) throws InterruptedException {

// TODO Auto-generated method stub

System.setProperty("webdriver.gecko.driver","D:\\rs\\Softwares\\selenium_SW\\Sel_3.0.1\\geckodriver-v0.11.1-win64\\geckodriver.exe");

driver=new FirefoxDriver(); driver.manage().window().maximize(); driver.manage().timeouts().implicitlyWait(20, TimeUnit.SECONDS); ***************************************************************************************** 1477964536897 geckodriver INFO Listening on 127.0.0.1:10217 Nov 01, 2016 7:12:17 AM org.openqa.selenium.remote.ProtocolHandshake createSession INFO: Attempting bi-dialect session, assuming Postel's Law holds true on the remote end 1477964537585 mozprofile::profile INFO Using profile path C:\Users\initech\AppData\Local\Temp\rust_mozprofile.Uy8R8xCgecbs 1477964537590 geckodriver::marionette INFO Starting browser C:\Program Files (x86)\Mozilla Firefox\firefox.exe Nov 01, 2016 7:12:17 AM org.openqa.selenium.remote.ProtocolHandshake createSession INFO: Falling back to original OSS JSON Wire Protocol. 1477964537632 mozprofile::profile INFO Using profile path C:\Users\initech\AppData\Local\Temp\rust_mozprofile.UBgSWI3jToRu 1477964537655 geckodriver::marionette INFO Starting browser C:\Program Files (x86)\Mozilla Firefox\firefox.exe 1477964567850 geckodriver::marionette INFO Connecting to Marionette on localhost:61722 1477964568822 addons.xpi-utils ERROR Failed to write add-ons list to profile directory: [Exception... "Component returned failure code: 0x8052000e (NS_ERROR_FILE_IS_LOCKED) [nsIFile.moveTo]" nsresult: "0x8052000e (NS_ERROR_FILE_IS_LOCKED)" location: "JS frame :: resource://gre/modules/addons/XPIProvider.jsm -> resource://gre

1 Answer

0 like 0 dislike
by
Now its working for me Mayur. I have used in  main()...

public class wpLogin {

WebDriver driver;

public void main(String username, String password) throws InterruptedException {

System.setProperty("webdriver.gecko.driver","D:\\rs\\Softwares\\selenium_SW\\Sel_3.0.1\\geckodriver-v0.11.1-win64\\geckodriver.exe");

driver=new FirefoxDriver(); driver.manage().window().maximize(); driver.manage().timeouts().implicitlyWait(20, TimeUnit.SECONDS);
by The go-to Tester (181 points)
Thank you for sharing your solution.


This site is for software testing professionals, where you can ask all your questions and get answers from 1300+ masters of the profession. Click here to submit yours now!

1.4k questions

1.6k answers

866 comments

1.9k users

...