Chrome Extension - Selenium

541 views
Skip to first unread message

propovip

unread,
Jun 16, 2011, 3:58:45 AM6/16/11
to webdriver
I am able to install chrome extension by default and i uderstand the
same is loaded in to user profile.
Whenever i am opening the chrome browser using selenium chromedriver i
am unable to see the extension. does selenium Webdriver doesnt load
already installed chrome extensions?

Daniel Wagner-Hall

unread,
Jun 16, 2011, 8:16:14 AM6/16/11
to webd...@googlegroups.com
As far as I know, it loads with a clean profile. You can pass command
line flags to the ChromeDriver, which will let you use
--load-extension="path-to-extension" with the following:

DesiredCapabilities caps = DesiredCapabilities.chrome();
caps.setCapability("chrome.switches",
Arrays.asList("--load-extension=/path/to/extension"));
WebDriver driver = new ChromeDriver(caps);

this will be better documented soon. You may also want to create a
feature request for allowing profiles to be passed to the ChromeDriver
on https://code.google.com/p/selenium/issues/entry

> --
> You received this message because you are subscribed to the Google Groups "webdriver" group.
> To post to this group, send email to webd...@googlegroups.com.
> To unsubscribe from this group, send email to webdriver+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/webdriver?hl=en.
>
>

Muhil

unread,
Jun 16, 2011, 11:11:41 AM6/16/11
to webd...@googlegroups.com
Thank you Daniel!!!! I will raise a ticket as i saw the custom profile was one of the limitations of webdriver i thought its an known issue.
Reply all
Reply to author
Forward
0 new messages