testilo 9.0.3 → 10.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +31 -7
- package/package.json +1 -1
- package/procs/score/{sp20b.js → tic21.js} +1252 -991
- package/procs/score/tsp21.js +720 -0
- package/specs/batches/orgs.json +43 -0
- package/specs/scripts/ts21.json +212 -0
- package/toolRules/qualWeb.tsv +121 -0
- package/procs/score/sp10a.js +0 -591
- package/procs/score/sp10b.js +0 -507
- package/procs/score/sp10c.js +0 -465
- package/procs/score/sp11a.js +0 -1968
- package/procs/score/sp12a.js +0 -3000
- package/procs/score/sp12b.js +0 -3315
- package/procs/score/sp14a.js +0 -4101
- package/procs/score/sp15a.js +0 -4899
- package/procs/score/sp15b.js +0 -6279
- package/procs/score/sp15c.js +0 -6282
- package/procs/score/sp16a.js +0 -6362
- package/procs/score/sp16b.js +0 -6370
- package/procs/score/sp16c.js +0 -6364
- package/procs/score/sp17a.js +0 -6099
- package/procs/score/sp18a.js +0 -6378
- package/procs/score/sp20a.js +0 -6379
- package/procs/score/spHover.js +0 -328
- package/procs/score/tsp09a.js +0 -564
- package/scoring/data/correlations.json +0 -327
- package/scoring/data/data.json +0 -26021
- package/scoring/data/dupCounts.json +0 -112
- package/scoring/data/duplications.json +0 -253
- package/scoring/data/groups.json +0 -335
- package/scoring/data/issues.json +0 -304
- package/scoring/data/rulesetData.json +0 -15
- package/scoring/data/testGroups.json +0 -1067
- package/scoring/procs/asp09.js +0 -555
- package/scoring/procs/asp09NoWAVE.js +0 -508
- package/scoring/procs/correlation.js +0 -76
- package/scoring/procs/dupCounts.js +0 -39
- package/scoring/procs/groups.js +0 -61
- package/scoring/procs/packageData.js +0 -171
- package/scoring/procs/packageIssues.js +0 -34
- package/scoring/procs/regroup.js +0 -39
- package/scoring/procs/tempgroup.js +0 -96
- /package/procs/score/{spA11yMessage.js → tspA11yMessage.js} +0 -0
- /package/procs/score/{spProductPrice.js → tspProductPrice.js} +0 -0
- /package/{scoring/data/packageRules → toolRules}/alfa.tsv +0 -0
- /package/{scoring/data/packageRules → toolRules}/axe.js +0 -0
- /package/{scoring/data/packageRules → toolRules}/htmlcs.js +0 -0
- /package/{scoring/data/packageRules → toolRules}/ibm.tsv +0 -0
- /package/{scoring/data/packageRules → toolRules}/tenon.tsv +0 -0
- /package/{scoring/data/packageRules → toolRules}/wave.json +0 -0
- /package/{scoring/data/packageRules → toolRules}/wave.tsv +0 -0
package/README.md
CHANGED
|
@@ -98,7 +98,7 @@ Suppose you have created this script:
|
|
|
98
98
|
}
|
|
99
99
|
```
|
|
100
100
|
|
|
101
|
-
The `acts` array of this script contains three
|
|
101
|
+
The `acts` array of this script contains three acts of type `test` and two acts of type `placeholder`.
|
|
102
102
|
|
|
103
103
|
#### Batch
|
|
104
104
|
|
|
@@ -265,7 +265,7 @@ A user can invoke `merge` in this way:
|
|
|
265
265
|
- `node call merge s b e false`
|
|
266
266
|
- `node call merge s b e`
|
|
267
267
|
|
|
268
|
-
In these statements, replace `s` and `b` with the base names of the script and batch files, respectively. For example, if the script file is named `ts25.json`, then replace `
|
|
268
|
+
In these statements, replace `s` and `b` with the base names of the script and batch files, respectively. For example, if the script file is named `ts25.json`, then replace `s` with `ts25`. Replace `e` with an email address, or with an empty string if the environment variable `process.env.REQUESTER` exists and you want to use it.
|
|
269
269
|
|
|
270
270
|
The first statement will cause a merger with isolation.
|
|
271
271
|
The second and third statements will cause a merger without isolation.
|
|
@@ -278,6 +278,16 @@ The `call` module will save the jobs in the `todo` subdirectory of the `process.
|
|
|
278
278
|
|
|
279
279
|
To test the `merge` module, in the project directory you can execute the statement `node validation/merge/validate`. All logging statements should begin with “Success” and none should begin with “ERROR”.
|
|
280
280
|
|
|
281
|
+
### Examples
|
|
282
|
+
|
|
283
|
+
There are script and batch examples in the `specs` directory.
|
|
284
|
+
|
|
285
|
+
The script example (with ID `ts21`) performs all of the tests available in Testaro, including the tests of 9 dependent tools. It contains 2 `placeholder` acts, one that specifies the Webkit browser for any `launch` act and one that specifies the Chromium browser for any `launch` act.
|
|
286
|
+
|
|
287
|
+
The batch example (with ID `orgs`) specifies 2 targets.
|
|
288
|
+
- One of them has the URL `https://example.com` and requires each placeholder to be replaced with 2 acts: a `launch` act and a `url` act.
|
|
289
|
+
- The other has the URL `https://www.w3.org/WAI/ARIA/apg/example-index/accordion/accordion` and requires each placeholder to be replaced with 3 acts: a `launch` act, a `url` act, and a `button` act.
|
|
290
|
+
|
|
281
291
|
## Report scoring
|
|
282
292
|
|
|
283
293
|
### Introduction
|
|
@@ -307,7 +317,7 @@ A scoring function defines scoring rules. The Testilo package contains a `procs/
|
|
|
307
317
|
|
|
308
318
|
### Invocation
|
|
309
319
|
|
|
310
|
-
There are two ways to
|
|
320
|
+
There are two ways to invoke the `score` module.
|
|
311
321
|
|
|
312
322
|
#### By a module
|
|
313
323
|
|
|
@@ -326,13 +336,13 @@ The first argument to `score()` is a scoring function. In this example, it has b
|
|
|
326
336
|
A user can invoke `score` in this way:
|
|
327
337
|
|
|
328
338
|
```bash
|
|
329
|
-
node call score
|
|
330
|
-
node call score
|
|
339
|
+
node call score tsp25a
|
|
340
|
+
node call score tsp25a 75
|
|
331
341
|
```
|
|
332
342
|
|
|
333
343
|
When a user invokes `score` in this example, the `call` module:
|
|
334
|
-
- gets the scoring module `
|
|
335
|
-
- gets the reports from the
|
|
344
|
+
- gets the scoring module `tsp25a` from its JSON file `tsp25a.json` in the `score` subdirectory of the `process.env.FUNCTIONDIR` directory
|
|
345
|
+
- gets the reports from the `raw` subdirectory of the `process.env.REPORTDIR` directory
|
|
336
346
|
- writes the scored reports to the `scored` subdirectory of the `process.env.REPORTDIR` directory
|
|
337
347
|
|
|
338
348
|
The optional third argument to call (`75` in this example) is a report selector. Without the argument, `call` gets all the reports in the `raw` subdirectory. With the argument, `call` gets only those reports whose names begin with the argument string.
|
|
@@ -341,6 +351,20 @@ The optional third argument to call (`75` in this example) is a report selector.
|
|
|
341
351
|
|
|
342
352
|
To test the `score` module, in the project directory you can execute the statement `node validation/score/validate`. All logging statements should begin with “Success” and none should begin with “ERROR”.
|
|
343
353
|
|
|
354
|
+
### Comprehensive example
|
|
355
|
+
|
|
356
|
+
The module `procs/score/tsp21.js` is an example of a comprehensive score proc. It is designed to score reports produced by Testaro from jobs that Testilo creates from the `ts21` script. That script causes Testaro to perform 1351 tests belonging to Testaro and nine other tools integrated into Testaro as dependencies.
|
|
357
|
+
|
|
358
|
+
The `tsp21` score proc combines the results of those tests into a single score for each report. The `score` property that the proc adds to the report shows how the individual test results are aggregated into a score.
|
|
359
|
+
|
|
360
|
+
The `tsp21` score proc imports the `procs/score/tic21.js` module, which classifies all the tests into 255 “issues”. Any two or more tests classified into the same issue are deemed to be approximately equivalent in intent. Using this classification, the score proc tabulates the test results by issue, so that all instances of the issue, regardless of which tool discovered the instances, are reported together.
|
|
361
|
+
|
|
362
|
+
The issue classification in `tic21` assigns weights to the issues to reflect their estimated severities,and the scoring algorithm of `tsp21` adopts a compromise between issue-based and tool-based summation. Thus, if 3 tools discover 20 instances of an issue, the score increases (i.e. becomes worse) by more than it would if only 1 tool had discovered them, but less than 3 times as much. The motivations are that discovery of issue instances by multiple tools increases confidence that the issues are real, and passing accessibility tests is per se beneficial because it decreases risks associated with alleged inaccessibility.
|
|
363
|
+
|
|
364
|
+
The `tsp21` score proc does **not** attempt to identify instances of issues. Thus, if tool A discovers 4 instances and tool B discovers 7 instances of some issue, `tsp21` does not attempt to say which of the 4 discovered by A are a subset of the 7 discovered by B. Instead,`tsp21` naïvely acts as if the 4 are all a subset of the 7, even though in reality the two sets might be entirely disjoint.
|
|
365
|
+
|
|
366
|
+
In the `tsp21` scoring algorithm, the failure of a tool or of a Testaro test to run on a page increases the score of the page, and messages logged by the browser while tests are being performed on a page, especially error messages, also increase the score.
|
|
367
|
+
|
|
344
368
|
## Report digesting
|
|
345
369
|
|
|
346
370
|
### Introduction
|