UNPKG

1.63 kBTypeScriptView Raw
1/**
2 * @module Core
3 */
4/// <reference types="node" />
5import { EventEmitter } from 'events';
6/**
7 * List reporter to show the tests progress on stdout in
8 * a list format
9 */
10declare class ListReporter {
11 private _store;
12 constructor(emitter: EventEmitter);
13 private get _indent();
14 /**
15 * When test runner has started. We just need to initiate
16 * the store on this event
17 */
18 private _onStart;
19 /**
20 * Everytime a new group starts
21 */
22 private _onGroupStart;
23 /**
24 * Everytime a group has completed running all tests
25 */
26 private _onGroupEnd;
27 /**
28 * Print count for a label
29 */
30 private _printCount;
31 /**
32 * Prints the error for the test. If error is an assertion error, then
33 * there is no need to print the stack.
34 */
35 private _printTestError;
36 /**
37 * Everytime tests ends
38 */
39 private _onTestEnd;
40 /**
41 * Returns a boolean if the error stack fine part of the
42 * japa core
43 */
44 private _isNativeStackLine;
45 /**
46 * Returns a boolean telling if error stack is part
47 * of japa core by finding the sorroundings.
48 */
49 private _isNativeSorroundedLine;
50 /**
51 * Returns the title for the failing test
52 */
53 private _getFailingTitle;
54 /**
55 * Cleans up the error stack
56 */
57 private _cleanupErrorStack;
58 /**
59 * Returns the error stack by filtering the japa core
60 * lines from it.
61 */
62 private _formatErrorStack;
63 /**
64 * When test runner stops
65 */
66 private _onEnd;
67}
68export default function listReporter(emitter: any): ListReporter;
69export {};