0

hi i am using selenium webdriver. i have to connect system and i phone for the testing when i connect its not opening the other system, i am using chrome 38 and ie 10 i am getting stuct, please provide me your answer. check the code

if(browser.equalsIgnoreCase("Internet Explorer")){
    caps = DesiredCapabilities.internetExplorer();
}

if(browser.equalsIgnoreCase("chrome")){
    //System.setProperty("webdriver.chrome.driver","/10.187.143.46/C:/chr/chromedriver.exe");
    //driver=new RemoteWebDriver(new URL("http://10.187.143.46:6767/wd/hub"),caps);
    //ChromeDriver driver = new ChromeDriver();
    // driver.get("http:\\www.google.com");
    System.setProperty("webdriver.chrome.driver","\\10.187.143.46\\c$\\Users\\rr188182\\Desktop\\chromedriver.exe");            
    caps=DesiredCapabilities.chrome();
}

//Version
caps.setVersion(i);
driver1=new RemoteWebDriver(new URL("http://10.187.143.89:6767/wd/hub"),caps);
driver1.get("http://www.google.com");
driver2=new RemoteWebDriver(new URL("http://10.187.143.165:6767/wd/hub"),caps);
driver2.get("http://www.google.com");
driver3=new RemoteWebDriver(new URL("http://10.187.143.25:6767/wd/hub"),caps);
driver3.get("http://www.google.com");
driver4=new RemoteWebDriver(new URL("http://10.187.143.46:5555/wd/hub"),caps);
driver4.get("http://www.google.com");
driver5=new RemoteWebDriver(new URL("http://10.187.143.163:6767/wd/hub"),caps);
driver5.get("http://www.google.com");

public static void main(String[] args) throws MalformedURLException {
    GridConcept gr=new GridConcept();
    //gr.setup("WINDOWS", "internet explorer", "11","http://www.google.com");
    ...
}

if i provide ie and firefox the browser is opening but the next line is not excuting, if i use chrome it shows error as valid path. please provide your comments. Thanks in advance

djangofan
  • 28,471
  • 61
  • 196
  • 289
  • why are you bringing up 5 different drivers??? that means 5 browsers will being going at the same time on the same machine. this can certainly be optimized – ddavison Oct 16 '14 at 20:27
  • @alagarsamy - I can see why you are trying this. You will definitely learn from this exercise. I am not understanding why you have 2 separate Grid hubs in your example shown above. All you need is one Grid hub and one grid node. The grid node will be able to instantiate all your browsers. – djangofan Oct 17 '14 at 00:05
  • hi since i have to connect the other system and each system should be connected with different driver object – alagarsamy Oct 20 '14 at 11:10
  • My problem is to handle or to connect variouse system, system could be identified through ip address. and each system could be connected with driverobject that is webdriver object. My problem here is i am not able to open the browser in other system. but systems are connected. – alagarsamy Oct 20 '14 at 11:14

0 Answers0