mirror of
https://github.com/servo/servo.git
synced 2025-08-10 16:05:43 +01:00
Update web-platform-tests to revision 4a65f5002f1e2e778f62a9b99f4298dc8948f26c
This commit is contained in:
parent
4c3f878026
commit
e0938d4233
282 changed files with 3027 additions and 1009 deletions
|
@ -106,7 +106,7 @@ the test (for a typical testharness test, the only content on the page
|
|||
will be rendered by the harness itself).
|
||||
|
||||
|
||||
### Be Minimal
|
||||
### Be Conservative
|
||||
|
||||
Tests should generally avoid depending on edge case behavior of
|
||||
features that they don't explicitly intend on testing. For example,
|
||||
|
@ -117,6 +117,30 @@ This is not, however, to discourage testing of edge cases or
|
|||
interactions between multiple features; such tests are an essential
|
||||
part of ensuring interoperability of the web platform.
|
||||
|
||||
Tests should pass when the feature under test exposes the expected behavior,
|
||||
and they should fail when the feature under test is not implemented or is
|
||||
implemented incorrectly. Tests should not rely on unrelated features if doing
|
||||
so causes failures in the latest stable release of [Apple
|
||||
Safari][apple-safari], [Google Chrome][google-chrome], or [Mozilla
|
||||
Firefox][mozilla-firefox]. They should, therefore, not rely on any features
|
||||
aside from the one under test unless they are supported in all three browsers.
|
||||
|
||||
Existing tests can be used as a guide to identify acceptable features. For
|
||||
language features that are not used in existing tests, community-maintained
|
||||
projects such as [the ECMAScript compatibility tables][es-compat] and
|
||||
[caniuse.com][caniuse] provide an overview of basic feature support across the
|
||||
browsers listed above.
|
||||
|
||||
For JavaScript code that is re-used across many tests (e.g. `testharness.js`
|
||||
and the files located in the directory named `common`), only use language
|
||||
features that have been supported by each of the major browser engines above
|
||||
for over a year. This practice avoids introducing test failures for consumers
|
||||
maintaining older JavaScript runtimes.
|
||||
|
||||
Patches to make tests run on older versions or other browsers will be accepted
|
||||
provided they are relatively simple and do not add undue complexity to the
|
||||
test.
|
||||
|
||||
|
||||
### Be Cross-Platform
|
||||
|
||||
|
@ -197,3 +221,8 @@ for CSS have some additional requirements for:
|
|||
[css-metadata]: css-metadata
|
||||
[css-user-styles]: css-user-styles
|
||||
[file-name-flags]: file-names
|
||||
[mozilla-firefox]: https://mozilla.org/firefox
|
||||
[google-chrome]: https://google.com/chrome/browser/desktop/
|
||||
[apple-safari]: https://apple.com/safari
|
||||
[es-compat]: https://kangax.github.io/compat-table/
|
||||
[caniuse]: https://caniuse.com/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue