Added test documentation link to wpt's README.md

This commit is contained in:
Prudhvi Rampey 2017-02-17 05:49:32 +05:30
parent 216a89f776
commit f304c56f68

View file

@ -1,5 +1,6 @@
This folder contains the web platform tests, CSS WG tests, and the This folder contains the web platform tests, CSS WG tests, and the
code required to integrate them with Servo. code required to integrate them with Servo.
To learn how to write tests, go [here](http://web-platform-tests.org/writing-tests/index.html).
Contents Contents
======== ========
@ -116,18 +117,20 @@ The simplest way to create a new test is to use the following command:
./mach create-wpt tests/wpt/path/to/new/test.html ./mach create-wpt tests/wpt/path/to/new/test.html
This will create test.html in the appropriate directory using the WPT This will create test.html in the appropriate directory using the WPT
template for JavaScript tests. To create a new reference test instead, template for JavaScript tests. Tests are written using [testharness.js](https://github.com/w3c/testharness.js/). Documentation can be found [here](http://testthewebforward.org/docs/testharness-library.html).
use the following: To create a new reference test instead, use the following:
./mach create-wpt --reftest tests/wpt/path/to/new/reftest.html --reference tests/wpt/path/to/reference.html ./mach create-wpt --reftest tests/wpt/path/to/new/reftest.html --reference tests/wpt/path/to/reference.html
`reference.html` will be created if it does not exist, and `reftest.html` `reference.html` will be created if it does not exist, and `reftest.html`
will be created using the WPT reftest template. These new tests can then will be created using the WPT reftest template. To know more about reftests, check [this](http://web-platform-tests.org/writing-tests/reftests.html).
be run in the following manner like any other WPT test: These new tests can then be run in the following manner like any other WPT test:
./mach test-wpt tests/wpt/path/to/new/test.html ./mach test-wpt tests/wpt/path/to/new/test.html
./mach test-wpt tests/wpt/path/to/new/reftest.html ./mach test-wpt tests/wpt/path/to/new/reftest.html
Editing tests Editing tests
============= =============