• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1TAP version 13
2# Subtest: sync pass todo
3ok 1 - sync pass todo # TODO
4  ---
5  duration_ms: *
6  ...
7# Subtest: sync pass todo with message
8ok 2 - sync pass todo with message # TODO this is a passing todo
9  ---
10  duration_ms: *
11  ...
12# Subtest: sync fail todo
13not ok 3 - sync fail todo # TODO
14  ---
15  duration_ms: *
16  failureType: 'testCodeFailure'
17  error: 'thrown from sync fail todo'
18  code: 'ERR_TEST_FAILURE'
19  stack: |-
20    *
21    *
22    *
23    *
24    *
25    *
26    *
27  ...
28# Subtest: sync fail todo with message
29not ok 4 - sync fail todo with message # TODO this is a failing todo
30  ---
31  duration_ms: *
32  failureType: 'testCodeFailure'
33  error: 'thrown from sync fail todo with message'
34  code: 'ERR_TEST_FAILURE'
35  stack: |-
36    *
37    *
38    *
39    *
40    *
41    *
42    *
43  ...
44# Subtest: sync skip pass
45ok 5 - sync skip pass # SKIP
46  ---
47  duration_ms: *
48  ...
49# Subtest: sync skip pass with message
50ok 6 - sync skip pass with message # SKIP this is skipped
51  ---
52  duration_ms: *
53  ...
54# Subtest: sync pass
55ok 7 - sync pass
56  ---
57  duration_ms: *
58  ...
59# Subtest: sync throw fail
60not ok 8 - sync throw fail
61  ---
62  duration_ms: *
63  failureType: 'testCodeFailure'
64  error: 'thrown from sync throw fail'
65  code: 'ERR_TEST_FAILURE'
66  stack: |-
67    *
68    *
69    *
70    *
71    *
72    *
73    *
74  ...
75# Subtest: async skip pass
76ok 9 - async skip pass # SKIP
77  ---
78  duration_ms: *
79  ...
80# Subtest: async pass
81ok 10 - async pass
82  ---
83  duration_ms: *
84  ...
85# Subtest: mixing describe/it and test should work
86ok 11 - mixing describe/it and test should work
87  ---
88  duration_ms: *
89  ...
90# Subtest: async throw fail
91not ok 12 - async throw fail
92  ---
93  duration_ms: *
94  failureType: 'testCodeFailure'
95  error: 'thrown from async throw fail'
96  code: 'ERR_TEST_FAILURE'
97  stack: |-
98    *
99    *
100    *
101    *
102    *
103    *
104    *
105  ...
106# Subtest: async skip fail
107not ok 13 - async skip fail # SKIP
108  ---
109  duration_ms: *
110  failureType: 'callbackAndPromisePresent'
111  error: 'passed a callback but also returned a Promise'
112  code: 'ERR_TEST_FAILURE'
113  ...
114# Subtest: async assertion fail
115not ok 14 - async assertion fail
116  ---
117  duration_ms: *
118  failureType: 'testCodeFailure'
119  error: |-
120    Expected values to be strictly equal:
121
122    true !== false
123
124  code: 'ERR_ASSERTION'
125  name: 'AssertionError'
126  expected: false
127  actual: true
128  operator: 'strictEqual'
129  stack: |-
130    *
131    *
132    *
133    *
134    *
135    *
136    *
137  ...
138# Subtest: resolve pass
139ok 15 - resolve pass
140  ---
141  duration_ms: *
142  ...
143# Subtest: reject fail
144not ok 16 - reject fail
145  ---
146  duration_ms: *
147  failureType: 'testCodeFailure'
148  error: 'rejected from reject fail'
149  code: 'ERR_TEST_FAILURE'
150  stack: |-
151    *
152    *
153    *
154    *
155    *
156    *
157    *
158  ...
159# Subtest: unhandled rejection - passes but warns
160ok 17 - unhandled rejection - passes but warns
161  ---
162  duration_ms: *
163  ...
164# Subtest: async unhandled rejection - passes but warns
165ok 18 - async unhandled rejection - passes but warns
166  ---
167  duration_ms: *
168  ...
169# Subtest: immediate throw - passes but warns
170ok 19 - immediate throw - passes but warns
171  ---
172  duration_ms: *
173  ...
174# Subtest: immediate reject - passes but warns
175ok 20 - immediate reject - passes but warns
176  ---
177  duration_ms: *
178  ...
179# Subtest: immediate resolve pass
180ok 21 - immediate resolve pass
181  ---
182  duration_ms: *
183  ...
184# Subtest: subtest sync throw fail
185    # Subtest: +sync throw fail
186    not ok 1 - +sync throw fail
187      ---
188      duration_ms: *
189      failureType: 'testCodeFailure'
190      error: 'thrown from subtest sync throw fail'
191      code: 'ERR_TEST_FAILURE'
192      stack: |-
193        *
194        *
195        *
196        *
197        *
198        *
199        new Promise (<anonymous>)
200        *
201        *
202        Array.map (<anonymous>)
203      ...
204    # Subtest: mixing describe/it and test should work
205    ok 2 - mixing describe/it and test should work
206      ---
207      duration_ms: *
208      ...
209    1..2
210not ok 22 - subtest sync throw fail
211  ---
212  duration_ms: *
213  type: 'suite'
214  failureType: 'subtestsFailed'
215  error: '1 subtest failed'
216  code: 'ERR_TEST_FAILURE'
217  ...
218# Subtest: sync throw non-error fail
219not ok 23 - sync throw non-error fail
220  ---
221  duration_ms: *
222  failureType: 'testCodeFailure'
223  error: 'Symbol(thrown symbol from sync throw non-error fail)'
224  code: 'ERR_TEST_FAILURE'
225  ...
226# Subtest: level 0a
227    # Subtest: level 1a
228    ok 1 - level 1a
229      ---
230      duration_ms: *
231      ...
232    # Subtest: level 1b
233    ok 2 - level 1b
234      ---
235      duration_ms: *
236      ...
237    # Subtest: level 1c
238    ok 3 - level 1c
239      ---
240      duration_ms: *
241      ...
242    # Subtest: level 1d
243    ok 4 - level 1d
244      ---
245      duration_ms: *
246      ...
247    1..4
248ok 24 - level 0a
249  ---
250  duration_ms: *
251  type: 'suite'
252  ...
253# Subtest: invalid subtest - pass but subtest fails
254ok 25 - invalid subtest - pass but subtest fails
255  ---
256  duration_ms: *
257  type: 'suite'
258  ...
259# Subtest: sync skip option
260ok 26 - sync skip option # SKIP
261  ---
262  duration_ms: *
263  ...
264# Subtest: sync skip option with message
265ok 27 - sync skip option with message # SKIP this is skipped
266  ---
267  duration_ms: *
268  ...
269# Subtest: sync skip option is false fail
270not ok 28 - sync skip option is false fail
271  ---
272  duration_ms: *
273  failureType: 'testCodeFailure'
274  error: 'this should be executed'
275  code: 'ERR_TEST_FAILURE'
276  stack: |-
277    *
278    *
279    *
280    *
281    *
282    *
283    *
284  ...
285# Subtest: <anonymous>
286ok 29 - <anonymous>
287  ---
288  duration_ms: *
289  ...
290# Subtest: functionOnly
291ok 30 - functionOnly
292  ---
293  duration_ms: *
294  ...
295# Subtest: <anonymous>
296ok 31 - <anonymous>
297  ---
298  duration_ms: *
299  ...
300# Subtest: test with only a name provided
301ok 32 - test with only a name provided
302  ---
303  duration_ms: *
304  ...
305# Subtest: <anonymous>
306ok 33 - <anonymous>
307  ---
308  duration_ms: *
309  ...
310# Subtest: <anonymous>
311ok 34 - <anonymous> # SKIP
312  ---
313  duration_ms: *
314  ...
315# Subtest: test with a name and options provided
316ok 35 - test with a name and options provided # SKIP
317  ---
318  duration_ms: *
319  ...
320# Subtest: functionAndOptions
321ok 36 - functionAndOptions # SKIP
322  ---
323  duration_ms: *
324  ...
325# Subtest: escaped description \\ \# \\\#\\
326ok 37 - escaped description \\ \# \\\#\\
327  ---
328  duration_ms: *
329  ...
330# Subtest: escaped skip message
331ok 38 - escaped skip message # SKIP \#skip
332  ---
333  duration_ms: *
334  ...
335# Subtest: escaped todo message
336ok 39 - escaped todo message # TODO \#todo
337  ---
338  duration_ms: *
339  ...
340# Subtest: callback pass
341ok 40 - callback pass
342  ---
343  duration_ms: *
344  ...
345# Subtest: callback fail
346not ok 41 - callback fail
347  ---
348  duration_ms: *
349  failureType: 'testCodeFailure'
350  error: 'callback failure'
351  code: 'ERR_TEST_FAILURE'
352  stack: |-
353    *
354    *
355  ...
356# Subtest: sync t is this in test
357ok 42 - sync t is this in test
358  ---
359  duration_ms: *
360  ...
361# Subtest: async t is this in test
362ok 43 - async t is this in test
363  ---
364  duration_ms: *
365  ...
366# Subtest: callback t is this in test
367ok 44 - callback t is this in test
368  ---
369  duration_ms: *
370  ...
371# Subtest: callback also returns a Promise
372not ok 45 - callback also returns a Promise
373  ---
374  duration_ms: *
375  failureType: 'callbackAndPromisePresent'
376  error: 'passed a callback but also returned a Promise'
377  code: 'ERR_TEST_FAILURE'
378  ...
379# Subtest: callback throw
380not ok 46 - callback throw
381  ---
382  duration_ms: *
383  failureType: 'testCodeFailure'
384  error: 'thrown from callback throw'
385  code: 'ERR_TEST_FAILURE'
386  stack: |-
387    *
388    *
389    *
390    *
391    *
392    *
393    *
394  ...
395# Subtest: callback called twice
396not ok 47 - callback called twice
397  ---
398  duration_ms: *
399  failureType: 'multipleCallbackInvocations'
400  error: 'callback invoked multiple times'
401  code: 'ERR_TEST_FAILURE'
402  stack: |-
403    *
404    *
405  ...
406# Subtest: callback called twice in different ticks
407ok 48 - callback called twice in different ticks
408  ---
409  duration_ms: *
410  ...
411# Subtest: callback called twice in future tick
412not ok 49 - callback called twice in future tick
413  ---
414  duration_ms: *
415  failureType: 'uncaughtException'
416  error: 'callback invoked multiple times'
417  code: 'ERR_TEST_FAILURE'
418  stack: |-
419    *
420  ...
421# Subtest: callback async throw
422not ok 50 - callback async throw
423  ---
424  duration_ms: *
425  failureType: 'uncaughtException'
426  error: 'thrown from callback async throw'
427  code: 'ERR_TEST_FAILURE'
428  stack: |-
429    *
430    *
431  ...
432# Subtest: callback async throw after done
433ok 51 - callback async throw after done
434  ---
435  duration_ms: *
436  ...
437# Subtest: custom inspect symbol fail
438not ok 52 - custom inspect symbol fail
439  ---
440  duration_ms: *
441  failureType: 'testCodeFailure'
442  error: 'customized'
443  code: 'ERR_TEST_FAILURE'
444  ...
445# Subtest: custom inspect symbol that throws fail
446not ok 53 - custom inspect symbol that throws fail
447  ---
448  duration_ms: *
449  failureType: 'testCodeFailure'
450  error: |-
451    {
452      foo: 1,
453      [Symbol(nodejs.util.inspect.custom)]: [Function: [nodejs.util.inspect.custom]]
454    }
455  code: 'ERR_TEST_FAILURE'
456  ...
457# Subtest: subtest sync throw fails
458    # Subtest: sync throw fails at first
459    not ok 1 - sync throw fails at first
460      ---
461      duration_ms: *
462      failureType: 'testCodeFailure'
463      error: 'thrown from subtest sync throw fails at first'
464      code: 'ERR_TEST_FAILURE'
465      stack: |-
466        *
467        *
468        *
469        *
470        *
471        *
472        new Promise (<anonymous>)
473        *
474        *
475        Array.map (<anonymous>)
476      ...
477    # Subtest: sync throw fails at second
478    not ok 2 - sync throw fails at second
479      ---
480      duration_ms: *
481      failureType: 'testCodeFailure'
482      error: 'thrown from subtest sync throw fails at second'
483      code: 'ERR_TEST_FAILURE'
484      stack: |-
485        *
486        *
487        *
488        *
489        *
490        *
491        *
492        *
493        *
494        async Promise.all (index 0)
495      ...
496    1..2
497not ok 54 - subtest sync throw fails
498  ---
499  duration_ms: *
500  type: 'suite'
501  failureType: 'subtestsFailed'
502  error: '2 subtests failed'
503  code: 'ERR_TEST_FAILURE'
504  ...
505# Subtest: describe sync throw fails
506    # Subtest: should not run
507    not ok 1 - should not run
508      ---
509      duration_ms: ZERO
510      failureType: 'cancelledByParent'
511      error: 'test did not finish before its parent and was cancelled'
512      code: 'ERR_TEST_FAILURE'
513      ...
514    1..1
515not ok 55 - describe sync throw fails
516  ---
517  duration_ms: *
518  type: 'suite'
519  failureType: 'testCodeFailure'
520  error: 'thrown from describe'
521  code: 'ERR_TEST_FAILURE'
522  stack: |-
523    *
524    *
525    *
526    *
527    *
528    *
529    *
530    *
531    *
532    *
533  ...
534# Subtest: describe async throw fails
535    # Subtest: should not run
536    not ok 1 - should not run
537      ---
538      duration_ms: ZERO
539      failureType: 'cancelledByParent'
540      error: 'test did not finish before its parent and was cancelled'
541      code: 'ERR_TEST_FAILURE'
542      ...
543    1..1
544not ok 56 - describe async throw fails
545  ---
546  duration_ms: *
547  type: 'suite'
548  failureType: 'testCodeFailure'
549  error: 'thrown from describe'
550  code: 'ERR_TEST_FAILURE'
551  stack: |-
552    *
553    *
554    *
555    *
556    *
557    *
558    *
559    *
560    *
561    *
562  ...
563# Subtest: timeouts
564    # Subtest: timed out async test
565    not ok 1 - timed out async test
566      ---
567      duration_ms: *
568      failureType: 'testTimeoutFailure'
569      error: 'test timed out after 5ms'
570      code: 'ERR_TEST_FAILURE'
571      stack: |-
572        async Promise.all (index 0)
573      ...
574    # Subtest: timed out callback test
575    not ok 2 - timed out callback test
576      ---
577      duration_ms: *
578      failureType: 'testTimeoutFailure'
579      error: 'test timed out after 5ms'
580      code: 'ERR_TEST_FAILURE'
581      ...
582    # Subtest: large timeout async test is ok
583    ok 3 - large timeout async test is ok
584      ---
585      duration_ms: *
586      ...
587    # Subtest: large timeout callback test is ok
588    ok 4 - large timeout callback test is ok
589      ---
590      duration_ms: *
591      ...
592    1..4
593not ok 57 - timeouts
594  ---
595  duration_ms: *
596  type: 'suite'
597  failureType: 'subtestsFailed'
598  error: '2 subtests failed'
599  code: 'ERR_TEST_FAILURE'
600  ...
601# Subtest: successful thenable
602    # Subtest: successful thenable
603    ok 1 - successful thenable
604      ---
605      duration_ms: *
606      ...
607    # Subtest: rejected thenable
608    not ok 2 - rejected thenable
609      ---
610      duration_ms: *
611      failureType: 'testCodeFailure'
612      error: 'custom error'
613      code: 'ERR_TEST_FAILURE'
614      stack: |-
615        *
616        *
617      ...
618    1..2
619not ok 58 - successful thenable
620  ---
621  duration_ms: *
622  type: 'suite'
623  failureType: 'subtestsFailed'
624  error: '1 subtest failed'
625  code: 'ERR_TEST_FAILURE'
626  ...
627# Subtest: rejected thenable
628not ok 59 - rejected thenable
629  ---
630  duration_ms: *
631  type: 'suite'
632  failureType: 'testCodeFailure'
633  error: 'custom error'
634  code: 'ERR_TEST_FAILURE'
635  stack: |-
636    *
637  ...
638# Subtest: invalid subtest fail
639not ok 60 - invalid subtest fail
640  ---
641  duration_ms: *
642  failureType: 'parentAlreadyFinished'
643  error: 'test could not be started because its parent finished'
644  code: 'ERR_TEST_FAILURE'
645  stack: |-
646    *
647  ...
6481..60
649# Warning: Test "unhandled rejection - passes but warns" generated asynchronous activity after the test ended. This activity created the error "Error: rejected from unhandled rejection fail" and would have caused the test to fail, but instead triggered an unhandledRejection event.
650# Warning: Test "async unhandled rejection - passes but warns" generated asynchronous activity after the test ended. This activity created the error "Error: rejected from async unhandled rejection fail" and would have caused the test to fail, but instead triggered an unhandledRejection event.
651# Warning: Test "immediate throw - passes but warns" generated asynchronous activity after the test ended. This activity created the error "Error: thrown from immediate throw fail" and would have caused the test to fail, but instead triggered an uncaughtException event.
652# Warning: Test "immediate reject - passes but warns" generated asynchronous activity after the test ended. This activity created the error "Error: rejected from immediate reject fail" and would have caused the test to fail, but instead triggered an unhandledRejection event.
653# Warning: Test "callback called twice in different ticks" generated asynchronous activity after the test ended. This activity created the error "Error [ERR_TEST_FAILURE]: callback invoked multiple times" and would have caused the test to fail, but instead triggered an uncaughtException event.
654# Warning: Test "callback async throw after done" generated asynchronous activity after the test ended. This activity created the error "Error: thrown from callback async throw after done" and would have caused the test to fail, but instead triggered an uncaughtException event.
655# tests 67
656# suites 9
657# pass 29
658# fail 19
659# cancelled 4
660# skipped 10
661# todo 5
662# duration_ms *
663