Acceptance testing/Browsers

From MoodleDocs
Revision as of 10:27, 9 January 2014 by David Monllaó Olivé (talk | contribs) (Created page with "== Drivers == There are Selenium drivers (http://docs.seleniumhq.org/projects/webdriver/) to run acceptance tests in different browsers: * Firefox - https://code.google.com/...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Drivers

There are Selenium drivers (http://docs.seleniumhq.org/projects/webdriver/) to run acceptance tests in different browsers:

Each driver should be downloaded and Selenium .jar should be started specifying the path to the driver; depending on the driver there could be other requirements.

Examples

 # Linux (firefox by default + chrome)
 java -jar /opt/selenium-server-standalone.jar -Dwebdriver.chrome.driver=/opt/chromedriver
 # OSx (firefox & safari by default + chrome)
 java -jar /Users/moodle/Downloads/selenium-server-standalone.jar -Dwebdriver.chrome.driver=/Users/moodle/Downloads/chromedriver
 # Windows (started using git bash) (firefox by default + chrome + internet explorer)
 java -jar /c/seleniumdrivers/selenium-server-standalone.jar -Dwebdriver.chrome.driver=/c/seleniumdrivers/chromedriver.exe -Dwebdriver.ie.driver=/c/seleniumdrivers/IEDriverServer.exe

Compatibility

Not all the drivers can execute all of Moodle's step definitions; we tagged the step definitions that are using feature not supported by all browsers or that should be considered:

File uploads (@_upload) Switch window (@_switch_window) Switch frame (@_switch_iframe)
Firefox Yes Yes Yes
Chrome Yes No Yes
Internet Explorer Yes Yes Yes
Safari Yes No Yes
PhantomJS No No Yes