-
Notifications
You must be signed in to change notification settings - Fork 784
/
tap-outputs.js
618 lines (573 loc) 路 11.5 KB
/
tap-outputs.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
'use strict';
// Expected outputs from the TapReporter for the commands run in CLI tests
module.exports = {
qunit:
`TAP version 13
ok 1 First > 1
ok 2 Second > 1
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
"qunit 'glob/**/*-test.js'":
`TAP version 13
ok 1 A-Test > derp
ok 2 Nested-Test > herp
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit single.js':
`TAP version 13
ok 1 Single > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit single.js double.js':
`TAP version 13
ok 1 Double > has a test
ok 2 Double > has another test
ok 3 Single > has a test
1..3
# pass 3
# skip 0
# todo 0
# fail 0`,
'qunit test':
`TAP version 13
ok 1 First > 1
ok 2 Second > 1
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit fail/throws-match.js':
`TAP version 13
not ok 1 Throws match > bad
---
message: match error
severity: failed
actual : Error: Match me with a pattern
expected: "/incorrect pattern/"
stack: |
at /qunit/test/cli/fixtures/fail/throws-match.js:3:12
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
"qunit test single.js 'glob/**/*-test.js'":
`TAP version 13
ok 1 A-Test > derp
ok 2 Nested-Test > herp
ok 3 Single > has a test
ok 4 First > 1
ok 5 Second > 1
1..5
# pass 5
# skip 0
# todo 0
# fail 0`,
"qunit --seed s33d test single.js 'glob/**/*-test.js'": `Running tests with seed: s33d
TAP version 13
ok 1 Second > 1
ok 2 Single > has a test
ok 3 First > 1
ok 4 Nested-Test > herp
ok 5 A-Test > derp
1..5
# pass 5
# skip 0
# todo 0
# fail 0`,
'qunit --reporter npm-reporter': 'Run ended!',
'qunit --reporter does-not-exist': `No reporter found matching "does-not-exist".
Built-in reporters: console, tap
Extra reporters found among package dependencies: npm-reporter`,
'qunit --reporter': `Built-in reporters: console, tap
Extra reporters found among package dependencies: npm-reporter`,
'qunit hanging-test': `Error: Process exited before tests finished running
Last test to run (hanging) has an async hold. Ensure all assert.async() callbacks are invoked and Promises resolve. You should also set a standard timeout via QUnit.config.testTimeout.`,
/* eslint-enable max-len */
'qunit unhandled-rejection.js':
`not ok 1 global failure
---
message: Error: outside of a test context
severity: failed
stack: |
Error: outside of a test context
at /qunit/test/cli/fixtures/unhandled-rejection.js:17:18
at qunit.js
at /qunit/test/cli/fixtures/unhandled-rejection.js:3:7
at internal
...
Bail out! Error: outside of a test context
TAP version 13
not ok 2 Unhandled Rejections > test passes just fine, but has a rejected promise
---
message: global failure: Error: Error thrown in non-returned promise!
severity: failed
actual : undefined
expected: undefined
stack: |
Error: Error thrown in non-returned promise!
at /qunit/test/cli/fixtures/unhandled-rejection.js:10:13
at internal
...
1..2
# pass 0
# skip 0
# todo 0
# fail 2`,
// The last frame differs between Node 10 and 12+ (changes in processing of ticks)
'qunit no-tests':
`TAP version 13
not ok 1 global failure
---
message: No tests were run.
severity: failed
actual : undefined
expected: undefined
stack: |
Error: No tests were run.
at qunit.js
at internal
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
'qunit sourcemap/source.js':
`TAP version 13
ok 1 Example > good
not ok 2 Example > bad
---
message: failed
severity: failed
actual : false
expected: true
stack: |
at /qunit/test/cli/fixtures/sourcemap/source.js:7:16
...
1..2
# pass 1
# skip 0
# todo 0
# fail 1`,
'qunit sourcemap/source.min.js':
`TAP version 13
ok 1 Example > good
not ok 2 Example > bad
---
message: failed
severity: failed
actual : false
expected: true
stack: |
at /qunit/test/cli/fixtures/sourcemap/sourcemap/source.js:7:10
...
1..2
# pass 1
# skip 0
# todo 0
# fail 1`,
'qunit ../../es2018/esm.mjs':
`TAP version 13
ok 1 ESM test suite > sum()
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit timeout':
`TAP version 13
not ok 1 timeout > first
---
message: Test took longer than 10ms; test timed out.
severity: failed
actual : null
expected: undefined
stack: |
at internal
...
ok 2 timeout > second
1..2
# pass 1
# skip 0
# todo 0
# fail 1`,
'qunit hooks-global-context.js':
`TAP version 13
ok 1 A > A1
ok 2 A > AB > AB1
ok 3 B
1..3
# pass 3
# skip 0
# todo 0
# fail 0`,
'qunit zero-assertions.js':
`TAP version 13
ok 1 Zero assertions > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
"qunit --filter 'no matches' test":
`TAP version 13
not ok 1 global failure
---
message: "No tests matched the filter \\"no matches\\"."
severity: failed
actual : undefined
expected: undefined
stack: |
Error: No tests matched the filter "no matches".
at qunit.js
at internal
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
'qunit single.js --require require-dep --require ./node_modules/require-dep/module.js':
`required require-dep/index.js
required require-dep/module.js
TAP version 13
ok 1 Single > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
"node --expose-gc ../../../bin/qunit.js 'memory-leak/*.js'":
`TAP version 13
ok 1 some nested module > can call method on foo
ok 2 some nested module > child module > child test
ok 3 later thing > has released all foos
1..3
# pass 3
# skip 0
# todo 0
# fail 0`,
"node --expose-gc ../../../bin/qunit.js --filter !child 'memory-leak/*.js'":
`TAP version 13
ok 1 some nested module > can call method on foo
ok 2 later thing > has released all foos
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit only/test.js':
`TAP version 13
ok 1 run this test
ok 2 all tests with only run
1..3
# pass 3
# skip 0
# todo 0
# fail 0`,
'qunit only/module.js':
`TAP version 13
not ok 1 # TODO module B > Only this module should run > a todo test
---
message: not implemented yet
severity: todo
actual : false
expected: true
stack: |
at /qunit/test/cli/fixtures/only/module.js:17:18
...
ok 2 # SKIP module B > Only this module should run > implicitly skipped test
ok 3 module B > Only this module should run > normal test
ok 4 module D > test D
ok 5 module E > module F > test F
ok 6 module E > test E
1..8
# pass 6
# skip 1
# todo 1
# fail 0`,
'qunit only/module-then-test.js':
`TAP version 13
ok 1 module A > module B > test B
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit only/module-flat.js':
`TAP version 13
not ok 1 # TODO module B > test B
---
message: not implemented yet
severity: todo
actual : false
expected: true
stack: |
at /qunit/test/cli/fixtures/only/module-flat.js:8:14
...
ok 2 # SKIP module B > test C
ok 3 module B > test D
1..4
# pass 2
# skip 1
# todo 1
# fail 0`,
'qunit module-nested.js':
`TAP version 13
ok 1 module 1 > test in module 1
ok 2 module 3 > test in module 3
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit incorrect-hooks-warning/test.js':
`TAP version 13
ok 1 module providing hooks > module not providing hooks > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit async-module-warning/test.js':
`TAP version 13
ok 1 resulting parent module > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit async-module-warning/promise-test.js':
`TAP version 13
ok 1 module manually returning a promise > has a test
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit config-filter-string.js':
`TAP version 13
ok 1 filter > foo test
ok 2 filter > bar test
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit config-filter-regex.js':
`TAP version 13
ok 1 filter > foo test
ok 2 filter > FOO test
ok 3 filter > bar test
1..3
# pass 3
# skip 0
# todo 0
# fail 0`,
'qunit config-filter-regex-exclude.js':
`TAP version 13
ok 1 filter > foo test
ok 2 filter > Bar test
1..2
# pass 2
# skip 0
# todo 0
# fail 0`,
'qunit config-module.js':
`TAP version 13
ok 1 Module B > Test B
1..1
# pass 1
# skip 0
# todo 0
# fail 0`,
'qunit config-moduleId.js':
`TAP version 13
ok 1 module A scoped > module C nested > test C1
ok 2 module D scoped > test D1
ok 3 module D scoped > module E nested > test E1
ok 4 module D scoped > test D2
ok 5 module F flat > test F1
1..5
# pass 5
# skip 0
# todo 0
# fail 0`,
'qunit config-testId.js':
`TAP version 13
ok 1 test 2
ok 2 module A > module B > test 1
ok 3 module A > module C > test 2
ok 4 module D > test 1
1..0
# pass 0
# skip 0
# todo 0
# fail 0`,
'qunit config-testTimeout.js':
`TAP version 13
not ok 1 slow
---
message: Test took longer than 10ms; test timed out.
severity: failed
actual : null
expected: undefined
stack: |
at internal
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
'qunit bad-callbacks/begin-throw.js':
`TAP version 13
not ok 1 global failure
---
message: Error: No dice
severity: failed
stack: |
Error: No dice
at /qunit/test/cli/fixtures/bad-callbacks/begin-throw.js:2:9
at qunit.js
at internal
...
Bail out! Error: No dice`,
'qunit bad-callbacks/done-throw.js':
`TAP version 13
ok 1 module1 > test1
1..1
# pass 1
# skip 0
# todo 0
# fail 0
Bail out! Error: No dice
---
message: Error: No dice
severity: failed
stack: |
Error: No dice
at /qunit/test/cli/fixtures/bad-callbacks/done-throw.js:2:9
at qunit.js
at internal
...`,
'qunit done-after-timeout.js':
`TAP version 13
not ok 1 times out before scheduled done is called
---
message: Test took longer than 10ms; test timed out.
severity: failed
actual : null
expected: undefined
stack: |
at internal
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
'qunit drooling-done.js':
`TAP version 13
not ok 1 Test A
---
message: |+
Died on test #2: this is an intentional error
at /qunit/test/cli/fixtures/drooling-done.js:5:7
at internal
severity: failed
actual : null
expected: undefined
stack: |
Error: this is an intentional error
at /qunit/test/cli/fixtures/drooling-done.js:8:9
...
ok 2 Test B
1..2
# pass 1
# skip 0
# todo 0
# fail 1`,
'qunit drooling-extra-done.js':
`TAP version 13
ok 1 Test A
not ok 2 Test B
---
message: |+
Died on test #2: Unexpected release of async pause during a different test.
> Test: Test A [async #1]
at /qunit/test/cli/fixtures/drooling-extra-done.js:13:7
at internal
severity: failed
actual : null
expected: undefined
stack: |
Error: Unexpected release of async pause during a different test.
> Test: Test A [async #1]
...
1..2
# pass 1
# skip 0
# todo 0
# fail 1`,
'qunit drooling-extra-done-outside.js':
`TAP version 13
ok 1 extra done scheduled outside any test
1..1
# pass 1
# skip 0
# todo 0
# fail 0
Bail out! Error: Unexpected release of async pause after tests finished.
---
message: |+
Error: Unexpected release of async pause after tests finished.
> Test: extra done scheduled outside any test [async #1]
severity: failed
stack: |
Error: Unexpected release of async pause after tests finished.
> Test: extra done scheduled outside any test [async #1]
at qunit.js
at internal
...`,
'qunit too-many-done-calls.js':
`TAP version 13
not ok 1 Test A
---
message: |+
Died on test #2: Tried to release async pause that was already released.
> Test: Test A [async #1]
at /qunit/test/cli/fixtures/too-many-done-calls.js:1:7
at internal
severity: failed
actual : null
expected: undefined
stack: |
Error: Tried to release async pause that was already released.
> Test: Test A [async #1]
...
1..1
# pass 0
# skip 0
# todo 0
# fail 1`,
'qunit assert-expect/no-tests.js':
`TAP version 13
1..0
# pass 0
# skip 0
# todo 0
# fail 0`
};