Share
Go down
ankur_infy
Posts : 3
Join date : 2012-05-15

using google chrome with selenium RC

on Tue May 15, 2012 3:09 pm
Hi

i have selenium RC server with me. i could launch IE and firefox using this but i need to launch safari and chrome as well. i am facing issue with this. kindly help



Thanks
avatar
rohit13
Master
Master
Posts : 180
Join date : 2012-03-29
Age : 31
Location : INDIA
http://radical-qa.blogspot.in/

Re: using google chrome with selenium RC

on Tue May 15, 2012 3:31 pm
which issues you are facing??
Which parameter you are passing for chrome / safari ??

Can you please provide more information??

_________________
Radical QA
http://radical-qa.blogspot.in/
ankur_infy
Posts : 3
Join date : 2012-05-15

Re: using google chrome with selenium RC

on Tue May 15, 2012 3:48 pm
i tried writing "*googlechrome" as browser name parameter. i was unable to launch chrome. someone told me to use web driver but i am not very comfortable with it. so i wanted to use it with RC itself. do you have any snippet for running chrome using selenium RC and opening any website say google.com through it.

Thanks
avatar
rohit13
Master
Master
Posts : 180
Join date : 2012-03-29
Age : 31
Location : INDIA
http://radical-qa.blogspot.in/

Re: using google chrome with selenium RC

on Tue May 15, 2012 4:04 pm
selenium = new DefaultSelenium("localhost", 4444, "*googlechrome", "http://www.google.com");
and for safari browser you can use *safari / *safariproxy.

Below is sample working code for googlechrome browser


Code:
public class google extends SeleneseTestCase {
    @Before
    public void setUp() throws Exception {
        selenium = new DefaultSelenium("localhost", 4444, "*googlechrome", "http://www.yatra.com/flights-india-vx/");
        selenium.start();
    }

    @Test
    public void test() throws Exception {
        selenium.open("/flights-india-vx/");
        selenium.click("id=auto_origin");
        selenium.click("xpath=(//*[@class="ui-corner-all"])[5]");
        selenium.click("id=auto_destination");
        selenium.click("id=ui-active-menuitem");
        selenium.click("id=datePickerDepart_dom1");
        selenium.click("link=12");
        selenium.click("id=btnFindFlights");
        selenium.waitForPageToLoad("30000");
    }

_________________
Radical QA
http://radical-qa.blogspot.in/
Sponsored content

Re: using google chrome with selenium RC

Back to top
Permissions in this forum:
You cannot reply to topics in this forum