Open Bug 1208209 Opened 5 years ago Updated 4 years ago

Convert current selenium test scripts from using SeleniumRC to the newer Selenium::Remote::Driver

Categories

(Bugzilla :: QA Test Scripts, enhancement)

enhancement
Not set

Tracking

()

People

(Reporter: dkl, Unassigned)

Details

Selenium WebDriver is the successor of Selenium Remote Control which has been officially deprecated. Our test scripts currently work at the moment, but in the future, Firefox may change in way that no longer works with SeleniumRC and we will have to migrate anyway. WebDriver is actively maintained, drives the browser natively and also adds additional features. WebDriver also overcomes the limitation of Selenium RC's Single Host origin policy.

Also we would no longer need to use selenium-standalone-X.XX.jar as we would talk to the browser directly.

Perl bindings:
https://github.com/gempesaw/Selenium-Remote-Driver
https://metacpan.org/release/Selenium-Remote-Driver

Downside: Major rewrite of our test scripts as the syntax is different and relies and WebObjects instead of CSS selectors.

Something I would want to do is to capture errors and store screenshots automatically for use by headless systems (Travis, Taskcluster, etc).

dkl
You will only do the conversion in master, right?
(In reply to Frédéric Buclin from comment #1)
> You will only do the conversion in master, right?

That is correct. If Firefox stops working in the older branches for SeleniumRC we will worry about it then.

dkl
FYI, I wrote a test script using Selenium::Remote::Driver which doesn't depend on selenium-server-standalone-2.48.2.jar, and despite it's working fine with Firefox 41, it fails to start with Firefox 43:

prove -v test_simple.t 
test_simple.t .. Unable to connect to the /usr/local/bin/firefox binary on port 9090 at /usr/lib/perl5/site_perl/5.20.1/Selenium/CanStartBinary.pm line 132.


Our current Selenium scripts based on WWW::Selenium have the same problem: they work fine with Firefox 41 but totally fail to start with Firefox 43.

Before we start converting our scripts to use Selenium::Remote::Driver, someone would have to find what's wrong with Firefox 43.
Workaround for Firefox 43:

After Selenium::Remote::Driver is installed, edit Selenium/Firefox/webdriver_prefs.json and add

  "xpinstall.signatures.required": false

at the end of the "frozen" list.

From what I heard, this pref won't work in Firefox 44 anymore. We will have to move to Marionnette, see https://developer.mozilla.org/en-US/docs/Mozilla/QA/Marionette/WebDriver
You need to log in before you can comment on or make changes to this bug.