gecko-dev/testing/web-platform/tests/url
James Graham 1859b9b1e6 Bug 1302423 - Update web-platform-tests to revision 6b48d45a1c7f3243945bf1678008f607e70acf2e, a=testonly
MozReview-Commit-ID: 7u0jU4PkBVg


--HG--
rename : testing/web-platform/tests/domparsing/insert_adjacent_html.xhtml => testing/web-platform/tests/domparsing/insert_adjacent_html-xhtml.xhtml
2016-09-13 14:49:17 +01:00
..
OWNERS Bug 1270508 - Update web-platform-tests to revision 26663baa852c0b42b91e7e72d3aa940e43371571, a=testonly 2016-05-07 09:05:37 +01:00
README.md Bug 1252424 - Update web-platform-tests to revision 827c4f521be3452fc00630ec7874a4cac0a270c0, a=testonly 2016-03-01 11:45:08 +00:00
a-element-xhtml.xhtml Bug 1253226 - Update web-platform-tests to revision 833a6d13372424758a6e3a770ecc6e8d1ffaae67, a=testonly 2016-03-04 16:16:51 +00:00
a-element.html Bug 1253226 - Update web-platform-tests to revision 833a6d13372424758a6e3a770ecc6e8d1ffaae67, a=testonly 2016-03-04 16:16:51 +00:00
a-element.js Bug 1273176 - Update web-platform-tests to revision 55905788bebbdfacb49c94e579e93c19531e0199, a=testonly 2016-05-16 17:05:32 +01:00
historical.html Bug 1263631 - Update web-platform-tests to revision 8d896c2015ab1e50ad00a0013700f87813d9364c, a=testonly 2016-04-11 23:23:45 +01:00
historical.worker.js Bug 1263631 - Update web-platform-tests to revision 8d896c2015ab1e50ad00a0013700f87813d9364c, a=testonly 2016-04-11 23:23:45 +01:00
interfaces.html Bug 1225032 - Update web-platform-tests to revision a5f15d6bdbeeec010465dc906e542873d64797ec, a=testonly 2015-11-16 13:52:16 +00:00
setters_tests.json Bug 1274534 - Update web-platform-tests to revision e806420984568cd76da78de27c832b0a927d9fc6, a=testonly 2016-05-24 08:41:15 +01:00
url-constructor.html Bug 1279809 - Update web-platform-tests to revision 664c6072db0f96031ff775f4a6c0a744e77c3265, a=testonly 2016-06-23 10:36:47 +01:00
url-domainToUnicode.html Bug 1290859 - Update web-platform-tests to revision 6744ac43d76207bdd1ececa4b91c9bfeef3ad522, a=testonly 2016-08-01 13:56:46 +01:00
url-setters.html Bug 1274534 - Update web-platform-tests to revision e806420984568cd76da78de27c832b0a927d9fc6, a=testonly 2016-05-24 08:41:15 +01:00
urlsearchparams-append.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-constructor.html Bug 1230948 - Update web-platform-tests to revision 63bf7b5e1e12b308ba6ed20480ad7dc93afa1943, a=testonly 2015-12-07 16:31:18 +00:00
urlsearchparams-delete.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-get.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-getall.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-has.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-set.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urlsearchparams-stringifier.html Bug 1225909 - Update web-platform-tests to revision 623c1536821f7536d8ee2859bbeaf0d9738ea707, a=testonly 2015-11-18 17:20:47 +00:00
urltestdata.json Bug 1302423 - Update web-platform-tests to revision 6b48d45a1c7f3243945bf1678008f607e70acf2e, a=testonly 2016-09-13 14:49:17 +01:00

README.md

These tests are for browsers, but the data for a-element.html, url-constructor.html, and a-element-xhtml.xhtml is in urltestdata.json and can be re-used by non-browser implementations. This file contains a JSON array of comments as strings and test cases as objects. The keys for each test case are:

  • base: an absolute URL as a string whose parsing without a base of its own should succeed. This key is always present, and may have a value like "about:blank" when input is an absolute URL.
  • input: an URL as a string to be parsed with base as its base URL.
  • Either:
    • failure with the value true, indicating that parsing input should return failure,

    • or href, origin, protocol, username, password, host, hostname, port, pathname, search, and hash with string values; indicating that parsing input should return an URL record and that the getters of each corresponding attribute in that URLs API should return the corresponding value.

      The origin key may be missing. In that case, the APIs origin attribute is not tested.

annevk/url hosts some other files that might be of interest if you want to create additional tests.

Similar to a-element.html it would be trivial to add more tests for other objects that expose links (e.g. URL and <area>). There's also room for enhancement and bits that require independent tests:

  • The encoding part of the URL parser
  • The state override part of the URL parser (setting individual properties of a URL)
  • Origin serialization
  • application/x-www-form-urlencoded