servo/tests/wpt/web-platform-tests/webdriver
2016-02-12 09:41:14 +01:00
..
command_contexts Update web-platform-tests to revision 5a754b40cd49c0404863c431b58cc311dc5d167c 2015-11-17 10:54:05 +01:00
cookie Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
ecmascript Update web-platform-tests to revision 0d318188757a9c996e20b82db201fd04de5aa255 2015-04-03 23:28:54 +01:00
element_location Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
element_state Update web-platform-tests to revision 5a754b40cd49c0404863c431b58cc311dc5d167c 2015-11-17 10:54:05 +01:00
javascript Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
modal Update web-platform-tests to revision 5a754b40cd49c0404863c431b58cc311dc5d167c 2015-11-17 10:54:05 +01:00
navigation Update web-platform-tests to revision 5a754b40cd49c0404863c431b58cc311dc5d167c 2015-11-17 10:54:05 +01:00
screenshot Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
timeouts Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
user_input Update web-platform-tests to revision 5a754b40cd49c0404863c431b58cc311dc5d167c 2015-11-17 10:54:05 +01:00
windows Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
base_test.py Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
network.py Update web-platform-tests to revision 0d318188757a9c996e20b82db201fd04de5aa255 2015-04-03 23:28:54 +01:00
OWNERS Update web-platform-tests to revision 95aad3bd9b82b5c65d84d53517b65ba084de9394 2016-02-12 09:41:14 +01:00
README.md Update web-platform-tests to revision 0d318188757a9c996e20b82db201fd04de5aa255 2015-04-03 23:28:54 +01:00
runtests.py Update web-platform-tests to revision 0d318188757a9c996e20b82db201fd04de5aa255 2015-04-03 23:28:54 +01:00
runtests_p0.py Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00
webdriver.cfg Update web-platform-tests to revision 7123012427f92f0dc38a120e6e86a75b6c03aab5 2015-10-31 16:21:44 +01:00

W3C Browser Automation Specification Tests

This repository defines a set of conformance tests for the W3C web browser automation specification known as WebDriver. The purpose is for the different driver implementations to be tested to determine whether they meet the recognized standard.

How to run the tests

  1. Go to the WebDriver tests: cd _WEBDRIVER_TEST_ROOT_
  2. Run the tests: python runtests.py
  3. Run the test against a different config specified in webdriver.cfg: WD_BROWSER=chrome python runtests.py

To be run a specific test file you can just run python test_file.py

Similarly you can specify a different browser to run against if in webdriver.cfg: WD_BROWSER=chrome python ecmascript/ecmascript_test.py

Note: that you will need likely need to start the driver's server before running.

Updating configuration

The webdriver.cfg file holds any configuration that the tests might require. Change the value of browser to your needs. This will then be picked up by WebDriverBaseTest when tests are run.

Be sure not to commit your webdriver.cfg changes when your create or modify tests.

How to write tests

  1. Create a test file per section from the specification.
  2. For each test there needs to be one or more corresponding HTML files that will be used for testing. HTML files are not to be reused between tests. HTML files and other support files should be stored in a folder named 'res'.
  3. Test name should explain the intention of the test e.g. def test_navigate_and_return_title(self):