diff options
author | jugglinmike <mike@mikepennisi.com> | 2017-05-01 12:04:05 -0400 |
---|---|---|
committer | Leo Balter <leonardo.balter@gmail.com> | 2017-05-01 12:04:05 -0400 |
commit | 74954bfa915136c7998f8a0d9ca40b885075d409 (patch) | |
tree | 61c91d90c8f612dad18bffee1e59720f734998c9 /CONTRIBUTING.md | |
parent | 7bb4cd8f417f9568521d62d282a7aec9b46699c1 (diff) | |
download | qtdeclarative-testsuites-74954bfa915136c7998f8a0d9ca40b885075d409.tar.gz |
Introduce automated validation for test format (#994)
This script is intended to identify common test file formatting errors
prior to their acceptance into the project. It is designed to support
future extensions for additional validation rules.
Diffstat (limited to 'CONTRIBUTING.md')
-rw-r--r-- | CONTRIBUTING.md | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index bee74e42a..8e007afc1 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -249,6 +249,19 @@ p.then(function () { As above, exceptions that are thrown from a `then` clause are passed to a later `$DONE` function and reported asynchronously. +## Linting + +Some of the expectations documented here are enforced via a "linting" script. This script is used to validate patches automatically at submission time, but it may also be invoked locally via the following command: + + python tools/lint/lint.py --whitelist lint.whitelist [paths to tests] + +...where `[paths to tests]` is a list of one or more paths to test files or directories containing test files. + +In some cases, it may be necessary for a test to intentionally violate the rules enforced by the linting tool. Such violations can be allowed by including the path of the test(s) in the `lint.whitelist` file. Each path must appear on a dedicated line in that file, and a space-separated list of rules to ignore must follow each path. Lines beginning with the pound sign (`#`) will be ignored. For example: + + # This file documents authorship information and is not itself a test + test/built-ins/Simd/AUTHORS FRONTMATTER LICENSE + ## Procedurally-generated tests Some language features are expressed through a number of distinct syntactic forms. Test262 maintains these tests as a set of "test cases" and "test templates" in order to ensure equivalent coverage across all forms. The sub-directories within the `src/` directory describe the various language features that benefit from this approach. |