geoffroy
geoffroy

Reputation: 585

Can't test a remote HTML/CSS/JS/Java website with Cucumber + Selenium Webdriver + Chrome + Capybara

I'm trying to test with Cucumber + Selenium + Capybara a remote HTML/CSS/JS website which uses a Java . The website works fine on the Chrome browser, but when I launch my test, the Chrome browser is launched on the website, but the Java applet is not loaded at all.

Looks like the Chrome browser environment launched by Webdriver does not load any third party chrome plugins like Java.

Is there any way to circumvent this ?

Thanks in advance, best regards

Geoffroy

Upvotes: 0

Views: 472

Answers (2)

Sam Woods
Sam Woods

Reputation: 1850

You can load a custom profile with the following code:

DesiredCapabilities capabilities = DesiredCapabilities.chrome(); capabilities.setCapability("chrome.switches", Arrays.asList("--user-data-dir=/path/to/profile/directory")); WebDriver driver = new ChromeDriver(capabilities);

See the selenium chrome documentation: http://code.google.com/p/selenium/wiki/ChromeDriver

Upvotes: 1

Danish
Danish

Reputation: 3798

You can maybe try Selenium Remote Control instead of Webdriver. I haven't personally tried Selenium RC with third party tools, but it could an option to try while you're looking for alternatives.

Upvotes: 1

Related Questions