test-progress-tracker 2.0.7 → 2.0.8
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 +0 -4
- package/cjs/_virtual/_rolldown/runtime.js +23 -0
- package/cjs/append.d.ts +6 -2
- package/cjs/append.js +30 -38
- package/cjs/append.js.map +1 -1
- package/cjs/compress.js +6 -6
- package/cjs/compress.js.map +1 -1
- package/cjs/constants.js +7 -5
- package/cjs/constants.js.map +1 -1
- package/cjs/index.d.ts +6 -5
- package/cjs/index.js +9 -22
- package/cjs/init.d.ts +6 -2
- package/cjs/init.js +16 -16
- package/cjs/init.js.map +1 -1
- package/cjs/interface.d.ts +32 -29
- package/cjs/load.d.ts +6 -2
- package/cjs/load.js +37 -49
- package/cjs/load.js.map +1 -1
- package/cjs/minify.js +87 -71
- package/cjs/minify.js.map +1 -1
- package/cjs/monitor.d.ts +26 -24
- package/cjs/monitor.js +42 -42
- package/cjs/monitor.js.map +1 -1
- package/cjs/store.js +12 -9
- package/cjs/store.js.map +1 -1
- package/package.json +34 -44
- package/ts/append.ts +19 -19
- package/ts/compress.ts +3 -3
- package/ts/init.ts +6 -6
- package/ts/interface.ts +24 -24
- package/ts/load.ts +28 -29
- package/ts/minify.ts +84 -73
- package/ts/monitor.ts +58 -46
- package/ts/store.ts +7 -7
- package/ts/testResultsExamples.ts +90 -90
- package/cjs/compress.d.ts +0 -3
- package/cjs/constants.d.ts +0 -2
- package/cjs/index.js.map +0 -1
- package/cjs/interface.js +0 -3
- package/cjs/interface.js.map +0 -1
- package/cjs/minify.d.ts +0 -41
- package/cjs/store.d.ts +0 -3
package/ts/interface.ts
CHANGED
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import fs from 'fs'
|
|
1
|
+
import type fs from 'node:fs'
|
|
2
2
|
|
|
3
3
|
export interface FSContext<FSKeys extends keyof typeof fs> {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
4
|
+
fs: Pick<typeof fs, FSKeys>
|
|
5
|
+
/**
|
|
6
|
+
* Root directory (of the project).
|
|
7
|
+
*/
|
|
8
|
+
rootDir: string
|
|
9
9
|
}
|
|
10
10
|
|
|
11
11
|
export interface TestResults {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
12
|
+
startTime: number
|
|
13
|
+
duration: number
|
|
14
|
+
numFailedTests: number
|
|
15
|
+
numFailedTestSuites: number
|
|
16
|
+
numPassedTests: number
|
|
17
|
+
numPassedTestSuites: number
|
|
18
|
+
numTotalTests: number
|
|
19
|
+
numTotalTestSuites: number
|
|
20
|
+
filtered?: boolean
|
|
21
|
+
coverage?: CoverageSummary
|
|
22
22
|
}
|
|
23
23
|
|
|
24
24
|
export interface FileCoverageTotal {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
25
|
+
total: number
|
|
26
|
+
covered: number
|
|
27
|
+
skipped: number
|
|
28
|
+
pct?: number
|
|
29
29
|
}
|
|
30
30
|
|
|
31
31
|
export interface CoverageSummary {
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
32
|
+
lines: FileCoverageTotal
|
|
33
|
+
statements: FileCoverageTotal
|
|
34
|
+
branches: FileCoverageTotal
|
|
35
|
+
functions: FileCoverageTotal
|
|
36
36
|
}
|
package/ts/load.ts
CHANGED
|
@@ -1,38 +1,37 @@
|
|
|
1
|
-
import fs from 'fs'
|
|
2
|
-
import path from 'path'
|
|
3
|
-
import { unpartial } from 'unpartial'
|
|
4
|
-
import { promisify } from 'util'
|
|
5
|
-
import { decompress } from './compress'
|
|
6
|
-
import { PROGRESS_FOLDER, TEST_RESULT_FILENAME } from './constants'
|
|
7
|
-
import { FSContext, TestResults } from './interface'
|
|
8
|
-
import { unminify } from './minify'
|
|
9
|
-
import { store } from './store'
|
|
1
|
+
import fs from 'node:fs'
|
|
2
|
+
import path from 'node:path'
|
|
3
|
+
import { unpartial } from 'unpartial'
|
|
4
|
+
import { promisify } from 'node:util'
|
|
5
|
+
import { decompress } from './compress'
|
|
6
|
+
import { PROGRESS_FOLDER, TEST_RESULT_FILENAME } from './constants'
|
|
7
|
+
import type { FSContext, TestResults } from './interface'
|
|
8
|
+
import { unminify } from './minify'
|
|
9
|
+
import { store } from './store'
|
|
10
10
|
|
|
11
11
|
let readFile = fs.readFile
|
|
12
12
|
let promisifiedReadFile = promisify(fs.readFile)
|
|
13
13
|
|
|
14
14
|
export async function load(context?: Partial<FSContext<'readFile'>>) {
|
|
15
|
-
|
|
15
|
+
const c = unpartial<FSContext<'readFile'>>({ fs, rootDir: store.value.rootDir }, context)
|
|
16
16
|
|
|
17
|
-
|
|
17
|
+
const filepath = path.join(c.rootDir, PROGRESS_FOLDER, TEST_RESULT_FILENAME)
|
|
18
18
|
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
19
|
+
// istanbul ignore next
|
|
20
|
+
if (c.fs.readFile !== readFile) {
|
|
21
|
+
readFile = c.fs.readFile
|
|
22
|
+
promisifiedReadFile = promisify(readFile)
|
|
23
|
+
}
|
|
24
24
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
}
|
|
25
|
+
try {
|
|
26
|
+
const content = await promisifiedReadFile(filepath, 'utf-8')
|
|
27
|
+
const entries = content.split('\n')
|
|
28
|
+
return entries.reduce<TestResults[]>((r, e) => {
|
|
29
|
+
if (!e) return r
|
|
30
|
+
const minified = decompress(e)
|
|
31
|
+
r.push(unminify(minified))
|
|
32
|
+
return r
|
|
33
|
+
}, [])
|
|
34
|
+
} catch {
|
|
35
|
+
return []
|
|
36
|
+
}
|
|
38
37
|
}
|
package/ts/minify.ts
CHANGED
|
@@ -1,94 +1,105 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { CoverageSummary, TestResults } from './interface'
|
|
2
2
|
|
|
3
3
|
export interface MinifiedTestResult {
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
4
|
+
d: number
|
|
5
|
+
fl?: boolean
|
|
6
|
+
f: number
|
|
7
|
+
fs: number
|
|
8
|
+
p: number
|
|
9
|
+
ps: number
|
|
10
|
+
t: number
|
|
11
|
+
ts: number
|
|
12
|
+
s: number
|
|
13
|
+
c?: MinifiedCoverageSummary
|
|
14
14
|
}
|
|
15
15
|
export interface MinifiedCoverageSummary {
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
16
|
+
b: { c: number; s: number; t: number; p?: number }
|
|
17
|
+
f: { c: number; s: number; t: number; p?: number }
|
|
18
|
+
l: { c: number; s: number; t: number; p?: number }
|
|
19
|
+
s: { c: number; s: number; t: number; p?: number }
|
|
20
20
|
}
|
|
21
21
|
|
|
22
22
|
export function minify(testResults: TestResults) {
|
|
23
|
-
|
|
23
|
+
const {
|
|
24
|
+
duration,
|
|
25
|
+
filtered,
|
|
26
|
+
numFailedTests,
|
|
27
|
+
numFailedTestSuites,
|
|
28
|
+
numPassedTests,
|
|
29
|
+
numPassedTestSuites,
|
|
30
|
+
numTotalTests,
|
|
31
|
+
numTotalTestSuites,
|
|
32
|
+
startTime,
|
|
33
|
+
coverage
|
|
34
|
+
} = testResults
|
|
24
35
|
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
36
|
+
const result: MinifiedTestResult = {
|
|
37
|
+
d: duration,
|
|
38
|
+
f: numFailedTests,
|
|
39
|
+
fs: numFailedTestSuites,
|
|
40
|
+
p: numPassedTests,
|
|
41
|
+
ps: numPassedTestSuites,
|
|
42
|
+
t: numTotalTests,
|
|
43
|
+
ts: numTotalTestSuites,
|
|
44
|
+
s: startTime
|
|
45
|
+
}
|
|
46
|
+
if (filtered) {
|
|
47
|
+
result.fl = filtered
|
|
48
|
+
}
|
|
49
|
+
if (coverage) {
|
|
50
|
+
result.c = minifyCoverage(coverage)
|
|
51
|
+
}
|
|
52
|
+
return result
|
|
42
53
|
}
|
|
43
54
|
|
|
44
55
|
function minifyCoverage(coverage: CoverageSummary) {
|
|
45
|
-
|
|
56
|
+
const { branches, functions, lines, statements } = coverage
|
|
46
57
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
58
|
+
const result: MinifiedCoverageSummary = {
|
|
59
|
+
b: { c: branches.covered, s: branches.skipped, t: branches.total },
|
|
60
|
+
f: { c: functions.covered, s: functions.skipped, t: functions.total },
|
|
61
|
+
l: { c: lines.covered, s: lines.skipped, t: lines.total },
|
|
62
|
+
s: { c: statements.covered, s: statements.skipped, t: statements.total }
|
|
63
|
+
}
|
|
53
64
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
65
|
+
if (branches.pct) result.b.p = branches.pct
|
|
66
|
+
if (functions.pct) result.f.p = functions.pct
|
|
67
|
+
if (lines.pct) result.l.p = lines.pct
|
|
68
|
+
if (statements.pct) result.s.p = statements.pct
|
|
69
|
+
return result
|
|
59
70
|
}
|
|
60
71
|
|
|
61
72
|
export function unminify(minified: MinifiedTestResult) {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
73
|
+
const result: TestResults = {
|
|
74
|
+
duration: minified.d,
|
|
75
|
+
numFailedTests: minified.f,
|
|
76
|
+
numFailedTestSuites: minified.fs,
|
|
77
|
+
numPassedTests: minified.p,
|
|
78
|
+
numPassedTestSuites: minified.ps,
|
|
79
|
+
numTotalTests: minified.t,
|
|
80
|
+
numTotalTestSuites: minified.ts,
|
|
81
|
+
startTime: minified.s
|
|
82
|
+
}
|
|
83
|
+
if (minified.fl) {
|
|
84
|
+
result.filtered = minified.fl
|
|
85
|
+
}
|
|
86
|
+
if (minified.c) {
|
|
87
|
+
result.coverage = unminifyCoverage(minified.c)
|
|
88
|
+
}
|
|
89
|
+
return result
|
|
79
90
|
}
|
|
80
91
|
|
|
81
92
|
function unminifyCoverage(c: MinifiedCoverageSummary) {
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
93
|
+
const result: CoverageSummary = {
|
|
94
|
+
branches: { covered: c.b.c, skipped: c.b.s, total: c.b.t },
|
|
95
|
+
functions: { covered: c.f.c, skipped: c.f.s, total: c.f.t },
|
|
96
|
+
lines: { covered: c.l.c, skipped: c.l.s, total: c.l.t },
|
|
97
|
+
statements: { covered: c.s.c, skipped: c.s.s, total: c.s.t }
|
|
98
|
+
}
|
|
88
99
|
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
100
|
+
if (c.b.p !== undefined) result.branches.pct = c.b.p
|
|
101
|
+
if (c.f.p !== undefined) result.functions.pct = c.f.p
|
|
102
|
+
if (c.l.p !== undefined) result.lines.pct = c.l.p
|
|
103
|
+
if (c.s.p !== undefined) result.statements.pct = c.s.p
|
|
104
|
+
return result
|
|
94
105
|
}
|
package/ts/monitor.ts
CHANGED
|
@@ -1,73 +1,85 @@
|
|
|
1
1
|
import chokidar from 'chokidar'
|
|
2
|
-
import fs from 'fs'
|
|
3
|
-
import path from 'path'
|
|
4
|
-
import readline from 'readline'
|
|
2
|
+
import fs from 'node:fs'
|
|
3
|
+
import path from 'node:path'
|
|
4
|
+
import readline from 'node:readline'
|
|
5
5
|
import { unpartial } from 'unpartial'
|
|
6
6
|
import { decompress } from './compress'
|
|
7
7
|
import { PROGRESS_FOLDER, TEST_RESULT_FILENAME } from './constants'
|
|
8
|
-
import { TestResults } from './interface'
|
|
8
|
+
import type { TestResults } from './interface'
|
|
9
9
|
import { unminify } from './minify'
|
|
10
10
|
import { store } from './store'
|
|
11
11
|
|
|
12
12
|
export interface MonitorContext {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
fs: Pick<typeof fs, 'watch'>
|
|
14
|
+
rootDir: string
|
|
15
|
+
awaitWriteFinish: AwaitWriteFinishOptions | boolean
|
|
16
16
|
}
|
|
17
17
|
|
|
18
18
|
export interface AwaitWriteFinishOptions {
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
19
|
+
/**
|
|
20
|
+
* Amount of time in milliseconds for a file size to remain constant before emitting its event.
|
|
21
|
+
*/
|
|
22
|
+
stabilityThreshold?: number
|
|
23
23
|
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
24
|
+
/**
|
|
25
|
+
* File size polling interval.
|
|
26
|
+
*/
|
|
27
|
+
pollInterval?: number
|
|
28
28
|
}
|
|
29
29
|
|
|
30
30
|
export interface MonitorSubscription {
|
|
31
|
-
|
|
31
|
+
close(): Promise<void>
|
|
32
32
|
}
|
|
33
33
|
|
|
34
|
-
export function monitor(
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
34
|
+
export function monitor(
|
|
35
|
+
context: Partial<MonitorContext & GetLastLineContext> | undefined,
|
|
36
|
+
callback: (err: any, testResults?: TestResults) => void
|
|
37
|
+
): MonitorSubscription {
|
|
38
|
+
const c = unpartial<MonitorContext & GetLastLineContext>(
|
|
39
|
+
{
|
|
40
|
+
fs,
|
|
41
|
+
readline,
|
|
42
|
+
rootDir: store.value.rootDir,
|
|
43
|
+
awaitWriteFinish: true
|
|
44
|
+
},
|
|
45
|
+
context
|
|
46
|
+
)
|
|
47
|
+
const filepath = path.join(c.rootDir, PROGRESS_FOLDER, TEST_RESULT_FILENAME)
|
|
42
48
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
49
|
+
const w = chokidar.watch(filepath, { awaitWriteFinish: c.awaitWriteFinish })
|
|
50
|
+
w.on('add', (path) => invokeCallback(c, path, callback))
|
|
51
|
+
w.on('change', (path) => invokeCallback(c, path, callback))
|
|
52
|
+
return { close: () => w.close() }
|
|
47
53
|
}
|
|
48
54
|
|
|
49
|
-
function invokeCallback(
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
55
|
+
function invokeCallback(
|
|
56
|
+
context: GetLastLineContext,
|
|
57
|
+
filename: string,
|
|
58
|
+
callback: (err: any, testResults?: TestResults) => void
|
|
59
|
+
) {
|
|
60
|
+
getLastLine(context, filename)
|
|
61
|
+
.then((line) => {
|
|
62
|
+
callback(undefined, unminify(decompress(line)))
|
|
63
|
+
})
|
|
64
|
+
.catch((e) => callback(e))
|
|
53
65
|
}
|
|
54
66
|
|
|
55
67
|
export interface GetLastLineContext {
|
|
56
|
-
|
|
57
|
-
|
|
68
|
+
fs: Pick<typeof fs, 'createReadStream' | 'WriteStream'>
|
|
69
|
+
readline: Pick<typeof readline, 'createInterface'>
|
|
58
70
|
}
|
|
59
71
|
|
|
60
72
|
function getLastLine({ fs, readline }: GetLastLineContext, filename: string) {
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
+
const inStream = fs.createReadStream(filename)
|
|
74
|
+
return new Promise<string>((a, r) => {
|
|
75
|
+
const rl = readline.createInterface(inStream)
|
|
76
|
+
let lastline = ''
|
|
77
|
+
rl.on('line', (line: string) => {
|
|
78
|
+
if (line.length) {
|
|
79
|
+
lastline = line
|
|
80
|
+
}
|
|
81
|
+
})
|
|
82
|
+
rl.on('error', r)
|
|
83
|
+
rl.on('close', () => a(lastline))
|
|
84
|
+
})
|
|
73
85
|
}
|
package/ts/store.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { createStore } from 'global-store'
|
|
2
2
|
|
|
3
3
|
export const store = createStore<{ rootDir: string }>({
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
4
|
+
moduleName: 'test-progress-tracker',
|
|
5
|
+
version: '1.0.0',
|
|
6
|
+
key: 'eb969cee-8646-5b9c-9084-9093804d4121',
|
|
7
|
+
initializer: (current) => ({
|
|
8
|
+
rootDir: '.',
|
|
9
|
+
...current
|
|
10
|
+
})
|
|
11
11
|
})
|
|
@@ -1,108 +1,108 @@
|
|
|
1
1
|
export const noCoverage = {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
2
|
+
duration: 1,
|
|
3
|
+
numFailedTests: 2,
|
|
4
|
+
numFailedTestSuites: 3,
|
|
5
|
+
numPassedTests: 4,
|
|
6
|
+
numPassedTestSuites: 5,
|
|
7
|
+
numTotalTests: 6,
|
|
8
|
+
numTotalTestSuites: 7,
|
|
9
|
+
startTime: 8
|
|
10
10
|
}
|
|
11
11
|
|
|
12
12
|
export const noCoverageMinified = {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
13
|
+
d: 1,
|
|
14
|
+
f: 2,
|
|
15
|
+
fs: 3,
|
|
16
|
+
p: 4,
|
|
17
|
+
ps: 5,
|
|
18
|
+
t: 6,
|
|
19
|
+
ts: 7,
|
|
20
|
+
s: 8
|
|
21
21
|
}
|
|
22
22
|
export const filtered = {
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
23
|
+
duration: 1,
|
|
24
|
+
filtered: true,
|
|
25
|
+
numFailedTests: 2,
|
|
26
|
+
numFailedTestSuites: 3,
|
|
27
|
+
numPassedTests: 4,
|
|
28
|
+
numPassedTestSuites: 5,
|
|
29
|
+
numTotalTests: 6,
|
|
30
|
+
numTotalTestSuites: 7,
|
|
31
|
+
startTime: 8
|
|
32
32
|
}
|
|
33
33
|
|
|
34
34
|
export const filteredMinified = {
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
35
|
+
d: 1,
|
|
36
|
+
fl: true,
|
|
37
|
+
f: 2,
|
|
38
|
+
fs: 3,
|
|
39
|
+
p: 4,
|
|
40
|
+
ps: 5,
|
|
41
|
+
t: 6,
|
|
42
|
+
ts: 7,
|
|
43
|
+
s: 8
|
|
44
44
|
}
|
|
45
45
|
export const coverageNoPercentage = {
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
46
|
+
duration: 1,
|
|
47
|
+
numFailedTests: 2,
|
|
48
|
+
numFailedTestSuites: 3,
|
|
49
|
+
numPassedTests: 4,
|
|
50
|
+
numPassedTestSuites: 5,
|
|
51
|
+
numTotalTests: 6,
|
|
52
|
+
numTotalTestSuites: 7,
|
|
53
|
+
startTime: 8,
|
|
54
|
+
coverage: {
|
|
55
|
+
branches: { covered: 0, skipped: 1, total: 2 },
|
|
56
|
+
functions: { covered: 3, skipped: 4, total: 5 },
|
|
57
|
+
lines: { covered: 6, skipped: 7, total: 8 },
|
|
58
|
+
statements: { covered: 9, skipped: 10, total: 11 }
|
|
59
|
+
}
|
|
60
60
|
}
|
|
61
61
|
export const coverageNoPercentageMinified = {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
62
|
+
d: 1,
|
|
63
|
+
f: 2,
|
|
64
|
+
fs: 3,
|
|
65
|
+
p: 4,
|
|
66
|
+
ps: 5,
|
|
67
|
+
t: 6,
|
|
68
|
+
ts: 7,
|
|
69
|
+
s: 8,
|
|
70
|
+
c: {
|
|
71
|
+
b: { c: 0, s: 1, t: 2 },
|
|
72
|
+
f: { c: 3, s: 4, t: 5 },
|
|
73
|
+
l: { c: 6, s: 7, t: 8 },
|
|
74
|
+
s: { c: 9, s: 10, t: 11 }
|
|
75
|
+
}
|
|
76
76
|
}
|
|
77
77
|
export const coverageWithPercentage = {
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
78
|
+
duration: 1,
|
|
79
|
+
numFailedTests: 2,
|
|
80
|
+
numFailedTestSuites: 3,
|
|
81
|
+
numPassedTests: 4,
|
|
82
|
+
numPassedTestSuites: 5,
|
|
83
|
+
numTotalTests: 6,
|
|
84
|
+
numTotalTestSuites: 7,
|
|
85
|
+
startTime: 8,
|
|
86
|
+
coverage: {
|
|
87
|
+
branches: { covered: 0, skipped: 1, total: 2, pct: 0.1 },
|
|
88
|
+
functions: { covered: 3, skipped: 4, total: 5, pct: 0.2 },
|
|
89
|
+
lines: { covered: 6, skipped: 7, total: 8, pct: 0.3 },
|
|
90
|
+
statements: { covered: 9, skipped: 10, total: 11, pct: 0.4 }
|
|
91
|
+
}
|
|
92
92
|
}
|
|
93
93
|
export const coverageWithPercentageMinified = {
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
94
|
+
d: 1,
|
|
95
|
+
f: 2,
|
|
96
|
+
fs: 3,
|
|
97
|
+
p: 4,
|
|
98
|
+
ps: 5,
|
|
99
|
+
t: 6,
|
|
100
|
+
ts: 7,
|
|
101
|
+
s: 8,
|
|
102
|
+
c: {
|
|
103
|
+
b: { c: 0, s: 1, t: 2, p: 0.1 },
|
|
104
|
+
f: { c: 3, s: 4, t: 5, p: 0.2 },
|
|
105
|
+
l: { c: 6, s: 7, t: 8, p: 0.3 },
|
|
106
|
+
s: { c: 9, s: 10, t: 11, p: 0.4 }
|
|
107
|
+
}
|
|
108
108
|
}
|
package/cjs/compress.d.ts
DELETED
package/cjs/constants.d.ts
DELETED