testaro 4.2.3 → 4.2.6

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "testaro",
3
- "version": "4.2.3",
3
+ "version": "4.2.6",
4
4
  "description": "Automation of accessibility testing",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -0,0 +1,276 @@
1
+ {
2
+ "id": "a11yorgs",
3
+ "what": "Pages expected to pass all accessibility tests",
4
+ "hosts": [
5
+ {
6
+ "id": "iaap",
7
+ "which": "https://www.accessibilityassociation.org/s/",
8
+ "what": "IAAP"
9
+ },
10
+ {
11
+ "id": "w3cwaiaria",
12
+ "which": "https://www.w3.org/WAI/standards-guidelines/aria/",
13
+ "what": "W3C WAI-ARIA"
14
+ },
15
+ {
16
+ "id": "mozilla",
17
+ "which": "https://www.mozilla.org/en-US/",
18
+ "what": "Mozilla"
19
+ },
20
+ {
21
+ "id": "uswds",
22
+ "which": "https://designsystem.digital.gov/documentation/accessibility/",
23
+ "what": "U.S. Web Design System"
24
+ },
25
+ {
26
+ "id": "deque",
27
+ "which": "https://deque.com/",
28
+ "what": "Deque"
29
+ },
30
+ {
31
+ "id": "levelaccess",
32
+ "which": "https://www.levelaccess.com/",
33
+ "what": "Level Access"
34
+ },
35
+ {
36
+ "id": "tpgi",
37
+ "which": "https://www.tpgi.com/",
38
+ "what": "TPGi"
39
+ },
40
+ {
41
+ "id": "usablenet",
42
+ "which": "https://usablenet.com/",
43
+ "what": "UsableNet"
44
+ },
45
+ {
46
+ "id": "evinced",
47
+ "which": "https://www.evinced.com/",
48
+ "what": "Evinced"
49
+ },
50
+ {
51
+ "id": "accessibe",
52
+ "which": "https://accessibe.com/",
53
+ "what": "AccessiBe"
54
+ },
55
+ {
56
+ "id": "siteimprove",
57
+ "which": "https://siteimprove.com/en-us/accessibility/",
58
+ "what": "Siteimprove"
59
+ },
60
+ {
61
+ "id": "a11yshield",
62
+ "which": "https://www.accessibilityshield.com/",
63
+ "what": "Accessibility Shield"
64
+ },
65
+ {
66
+ "id": "barrierbreak",
67
+ "which": "https://www.barrierbreak.com/",
68
+ "what": "Barrier Break"
69
+ },
70
+ {
71
+ "id": "converge",
72
+ "which": "https://convergeaccessibility.com/",
73
+ "what": "Converge Accessibility"
74
+ },
75
+ {
76
+ "id": "crawford",
77
+ "which": "https://www.crawfordtech.com/accessibilitynow",
78
+ "what": "Crawford Technologies"
79
+ },
80
+ {
81
+ "id": "essential",
82
+ "which": "https://www.essentialaccessibility.com/",
83
+ "what": "eSSENTIAL Accessibility"
84
+ },
85
+ {
86
+ "id": "microassist",
87
+ "which": "https://www.microassist.com/",
88
+ "what": "Microassist"
89
+ },
90
+ {
91
+ "id": "mindscreen",
92
+ "which": "https://www.mindscreen.de/",
93
+ "what": "mindscreen"
94
+ },
95
+ {
96
+ "id": "onlineada",
97
+ "which": "https://onlineada.com/",
98
+ "what": "Online ADA"
99
+ },
100
+ {
101
+ "id": "tenon",
102
+ "which": "https://tenon.io/",
103
+ "what": "Tenon"
104
+ },
105
+ {
106
+ "id": "weco",
107
+ "which": "https://theweco.com/",
108
+ "what": "WeCo"
109
+ },
110
+ {
111
+ "id": "zugang",
112
+ "which": "https://www.access-for-all.ch/ch/",
113
+ "what": "Zugang für alle"
114
+ },
115
+ {
116
+ "id": "aph",
117
+ "which": "https://www.aph.org/accessibility-solutions/",
118
+ "what": "American Printing House"
119
+ },
120
+ {
121
+ "id": "dac",
122
+ "which": "https://www.digitalaccessibilitycentre.org/",
123
+ "what": "Digital Accessibility Centre"
124
+ },
125
+ {
126
+ "id": "ubb",
127
+ "which": "https://www.bfit-bund.de/DE/Home/home_node.html",
128
+ "what": "Überwachungsstelle des BFIT-Bund"
129
+ },
130
+ {
131
+ "id": "hearcolors",
132
+ "which": "https://www.hearcolors.com.mx/",
133
+ "what": "Fundación Hearcolors"
134
+ },
135
+ {
136
+ "id": "knowbility",
137
+ "which": "https://knowbility.org/",
138
+ "what": "Knowbility"
139
+ },
140
+ {
141
+ "id": "peat",
142
+ "which": "https://www.peatworks.org/",
143
+ "what": "PEAT"
144
+ },
145
+ {
146
+ "id": "viscardi",
147
+ "which": "https://www.viscardicenter.org/digital-accessibility-services/web-accessibility/",
148
+ "what": "Viscardi Center"
149
+ },
150
+ {
151
+ "id": "blindspot",
152
+ "which": "https://myblindspot.org/",
153
+ "what": "My Blind Spot"
154
+ },
155
+ {
156
+ "id": "a11yoz",
157
+ "which": "https://www.accessibilityoz.com/",
158
+ "what": "AccessibilityOz"
159
+ },
160
+ {
161
+ "id": "visionaus",
162
+ "which": "https://www.visionaustralia.org/services/digital-access",
163
+ "what": "Vision Australia"
164
+ },
165
+ {
166
+ "id": "abilitynet",
167
+ "which": "https://www.abilitynet.org.uk/",
168
+ "what": "AbilityNet"
169
+ },
170
+ {
171
+ "id": "audioeye",
172
+ "which": "https://www.audioeye.com/",
173
+ "what": "AudioEye"
174
+ },
175
+ {
176
+ "id": "funka",
177
+ "which": "https://www.funka.com/en/",
178
+ "what": "Funka"
179
+ },
180
+ {
181
+ "id": "accessibleweb",
182
+ "which": "https://accessibleweb.com/",
183
+ "what": "Accessible Web"
184
+ },
185
+ {
186
+ "id": "atos",
187
+ "which": "https://atos.net/en/lp/accessibility-and-assistive-technology-iux",
188
+ "what": "Atos"
189
+ },
190
+ {
191
+ "id": "equalentry",
192
+ "which": "https://equalentry.com/",
193
+ "what": "Equal Entry"
194
+ },
195
+ {
196
+ "id": "gatechcidi",
197
+ "which": "https://cidi.gatech.edu/",
198
+ "what": "Georgia Tech CIDI"
199
+ },
200
+ {
201
+ "id": "webaim",
202
+ "which": "https://webaim.org/",
203
+ "what": "WebAIM"
204
+ },
205
+ {
206
+ "id": "csuncd",
207
+ "which": "https://www.csun.edu/cod",
208
+ "what": "CSUN Center on Disabilities"
209
+ },
210
+ {
211
+ "id": "makesense",
212
+ "which": "https://mk-sense.com/",
213
+ "what": "Make-Sense"
214
+ },
215
+ {
216
+ "id": "faciliti",
217
+ "which": "https://www.facil-iti.fr/",
218
+ "what": "FACIL’iti"
219
+ },
220
+ {
221
+ "id": "aaatraq",
222
+ "which": "https://aaatraq.com/",
223
+ "what": "AAAtraq"
224
+ },
225
+ {
226
+ "id": "accessibleorg",
227
+ "which": "https://accessible.org/",
228
+ "what": "Accessible.org"
229
+ },
230
+ {
231
+ "id": "ab11y",
232
+ "which": "https://www.ab11y.com/",
233
+ "what": "Ab11y"
234
+ },
235
+ {
236
+ "id": "digitala11y",
237
+ "which": "https://www.digitala11y.com/",
238
+ "what": "DigitalA11Y"
239
+ },
240
+ {
241
+ "id": "teachaccess",
242
+ "which": "https://teachaccess.org/",
243
+ "what": "Teach Access"
244
+ },
245
+ {
246
+ "id": "tetralogical",
247
+ "which": "https://tetralogical.com/",
248
+ "what": "TetraLogical"
249
+ },
250
+ {
251
+ "id": "adaexpertise",
252
+ "which": "https://adaexpertise.com/",
253
+ "what": "ADA Expertise Consulting"
254
+ },
255
+ {
256
+ "id": "aten",
257
+ "which": "https://atendesigngroup.com/",
258
+ "what": "Aten Design Group"
259
+ },
260
+ {
261
+ "id": "holistica11y",
262
+ "which": "https://holistica11y.com/",
263
+ "what": "HolisticA11Y"
264
+ },
265
+ {
266
+ "id": "zenythgroup",
267
+ "which": "https://zenythgroup.com/index",
268
+ "what": "Zenyth Group"
269
+ },
270
+ {
271
+ "id": "boia",
272
+ "which": "https://www.boia.org/",
273
+ "what": "Bureau of Internet Accessibility"
274
+ }
275
+ ]
276
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "id": "doordash",
3
+ "what": "DoorDash",
4
+ "hosts": [
5
+ {
6
+ "id": "doordash",
7
+ "which": "https://www.doordash.com/",
8
+ "what": "DoorDash"
9
+ }
10
+ ]
11
+ }
@@ -0,0 +1,36 @@
1
+ {
2
+ "id": "greiner",
3
+ "what": "Greiner’s Fine Men’s Clothing",
4
+ "hosts": [
5
+ {
6
+ "id": "greinerhome",
7
+ "which": "http://greinersclothing.com/",
8
+ "what": "Greiner’s Fine Men’s Clothing: Home"
9
+ },
10
+ {
11
+ "id": "greinerabout",
12
+ "which": "https://greinersclothing.com/about-us/",
13
+ "what": "Greiner’s Fine Men’s Clothing: About Us"
14
+ },
15
+ {
16
+ "id": "greinercol",
17
+ "which": "https://greinersclothing.com/collections-fw2018-2/",
18
+ "what": "Greiner’s Fine Men’s Clothing: Collections"
19
+ },
20
+ {
21
+ "id": "greinermasks",
22
+ "which": "https://greinersclothing.com/covid19masks/",
23
+ "what": "Greiner’s Fine Men’s Clothing: COVID-19 Masks"
24
+ },
25
+ {
26
+ "id": "greinermeasure",
27
+ "which": "https://greinersclothing.com/made-to-measure/",
28
+ "what": "Greiner’s Fine Men’s Clothing: Made to Measure"
29
+ },
30
+ {
31
+ "id": "greinercontact",
32
+ "which": "https://greinersclothing.com/contact-2/",
33
+ "what": "Greiner’s Fine Men’s Clothing: Contact + Locations"
34
+ }
35
+ ]
36
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "id": "siteimprove",
3
+ "what": "Siteimprove",
4
+ "hosts": [
5
+ {
6
+ "id": "siteimprove",
7
+ "which": "https://www.siteimprove.com/",
8
+ "what": "Siteimprove"
9
+ }
10
+ ]
11
+ }
@@ -0,0 +1,11 @@
1
+ {
2
+ "id": "siteimprovea11y",
3
+ "what": "Siteimprove accessibility",
4
+ "hosts": [
5
+ {
6
+ "id": "siteimprovea11y",
7
+ "which": "https://www.siteimprove.com/platform/accessibility/",
8
+ "what": "Siteimprove accessibility"
9
+ }
10
+ ]
11
+ }
@@ -0,0 +1,22 @@
1
+ {
2
+ "id": "alfa",
3
+ "what": "Alfa test package",
4
+ "strict": true,
5
+ "commands": [
6
+ {
7
+ "type": "launch",
8
+ "which": "chromium",
9
+ "what": "used for most tests"
10
+ },
11
+ {
12
+ "type": "url",
13
+ "which": "https://*",
14
+ "what": "any page"
15
+ },
16
+ {
17
+ "type": "test",
18
+ "which": "alfa",
19
+ "what": "Siteimprove alfa"
20
+ }
21
+ ]
22
+ }
@@ -0,0 +1,23 @@
1
+ {
2
+ "id": "ibm",
3
+ "what": "IBM Equal Access test package",
4
+ "strict": true,
5
+ "commands": [
6
+ {
7
+ "type": "launch",
8
+ "which": "chromium",
9
+ "what": "used for most tests"
10
+ },
11
+ {
12
+ "type": "url",
13
+ "which": "https://*",
14
+ "what": "any page"
15
+ },
16
+ {
17
+ "type": "test",
18
+ "which": "ibm",
19
+ "withItems": true,
20
+ "what": "IBM Equal Access"
21
+ }
22
+ ]
23
+ }
File without changes
File without changes
package/tests/ibm.js CHANGED
@@ -24,29 +24,35 @@ const {getCompliance} = require('accessibility-checker');
24
24
  const run = async content => {
25
25
  const nowLabel = (new Date()).toISOString().slice(0, 19);
26
26
  // Return the result of a test.
27
- const report = await getCompliance(content, nowLabel);
28
- return report;
27
+ const ibmReport = await getCompliance(content, nowLabel);
28
+ return ibmReport;
29
29
  };
30
- // Reports the result of an IBM test.
31
- const report = (result, withItems) => {
30
+ // Trims an IBM report.
31
+ const report = (ibmReport, withItems) => {
32
32
  const data = {};
33
- if (result) {
34
- data.totals = result.report.summary.counts;
35
- if (withItems) {
36
- data.items = result.report.results;
37
- data.items.forEach(item => {
38
- delete item.apiArgs;
39
- delete item.category;
40
- delete item.ignored;
41
- delete item.messageArgs;
42
- delete item.reasonId;
43
- delete item.ruleTime;
44
- delete item.value;
45
- });
33
+ if (ibmReport && ibmReport.report && ibmReport.report.summary) {
34
+ const totals = ibmReport.report.summary.counts;
35
+ if (totals) {
36
+ data.totals = totals;
37
+ if (withItems) {
38
+ data.items = ibmReport.report.results;
39
+ data.items.forEach(item => {
40
+ delete item.apiArgs;
41
+ delete item.category;
42
+ delete item.ignored;
43
+ delete item.messageArgs;
44
+ delete item.reasonId;
45
+ delete item.ruleTime;
46
+ delete item.value;
47
+ });
48
+ }
49
+ }
50
+ else {
51
+ data.error = 'ERROR: ibm test delivered no totals';
46
52
  }
47
53
  }
48
54
  else {
49
- data.error = 'ERROR: ibm test failed';
55
+ data.error = 'ERROR: ibm test delivered no report summary';
50
56
  }
51
57
  return data;
52
58
  };
@@ -56,13 +62,13 @@ const doTest = async (content, withItems, timeLimit) => {
56
62
  let timeoutID;
57
63
  const wait = new Promise(resolve => {
58
64
  timeoutID = setTimeout(() => {
59
- resolve('');
65
+ resolve({});
60
66
  }, 1000 * timeLimit);
61
67
  });
62
68
  // Conduct and report the test.
63
- const result = run(content);
69
+ const ibmReport = run(content);
64
70
  // Wait for the report until the time limit expires.
65
- const resultIfFast = await Promise.race([result, wait]);
71
+ const ibmReportIfFast = await Promise.race([ibmReport, wait]);
66
72
  // Delete the report files.
67
73
  try {
68
74
  const reportNames = await fs.readdir('results');
@@ -74,14 +80,16 @@ const doTest = async (content, withItems, timeLimit) => {
74
80
  console.log('ibm test created no result files.');
75
81
  }
76
82
  // Return the result.
77
- if (resultIfFast) {
83
+ if (ibmReportIfFast.report) {
78
84
  clearTimeout(timeoutID);
79
- const typeResult = report(result, withItems);
80
- return typeResult;
85
+ const ibmTypeReport = report(ibmReportIfFast, withItems);
86
+ return ibmTypeReport;
81
87
  }
82
88
  else {
83
89
  console.log('ERROR: getting ibm test report took too long');
84
- return 'ERROR: getting ibm test report took too long';
90
+ return {
91
+ error: 'ERROR: getting ibm test report took too long'
92
+ };
85
93
  }
86
94
  };
87
95
  // Returns results of one or two IBM tests.