Debian Codegraph @

istanbul-lib-processinfo/tap-snapshots/test/process-db.js.test.cjs

raw
1 /* IMPORTANT
2 * This snapshot file is auto-generated, but designed for humans.
3 * It should be checked into source control and tracked carefully.
4 * Re-generate by setting TAP_SNAPSHOT=1 and running tests.
5 * Make sure to inspect the output below. Do not ignore changes!
6 */
7 'use strict'
8 exports[`test/process-db.js TAP readProcessInfos > must match snapshot 1`] = `
9 Object {
10 "0f4e28ea-5b03-4677-8c0d-263e81b42f7e": ProcessInfo {
11 "argv": Array [
12 "/usr/local/bin/node",
13 "test/fixtures/foo.test.js",
14 ],
15 "coverageFilename": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e.json",
16 "cwd": "test/fixtures",
17 "execArgv": Array [],
18 "externalId": "root process",
19 "files": Array [
20 "test/fixtures/foo.js",
21 ],
22 "parent": null,
23 "pid": 60876,
24 "ppid": 60875,
25 "time": 1555110275928,
26 "uuid": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
27 },
28 "300fc62b-eaf2-4505-981b-39567e807f94": ProcessInfo {
29 "argv": Array [
30 "/usr/local/bin/node",
31 "test/fixtures/bar.js",
32 ],
33 "coverageFilename": "300fc62b-eaf2-4505-981b-39567e807f94.json",
34 "cwd": "test/fixtures",
35 "execArgv": Array [],
36 "externalId": "",
37 "files": Array [
38 "test/fixtures/bar.js",
39 ],
40 "parent": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
41 "pid": 60877,
42 "ppid": 60876,
43 "time": 1555110276283,
44 "uuid": "300fc62b-eaf2-4505-981b-39567e807f94",
45 },
46 "625ef291-93c0-40b2-a869-70587f7e8fac": ProcessInfo {
47 "argv": Array [
48 "/usr/local/bin/node",
49 "test/fixtures/foo.js",
50 ],
51 "coverageFilename": "625ef291-93c0-40b2-a869-70587f7e8fac.json",
52 "cwd": "test/fixtures",
53 "execArgv": Array [],
54 "externalId": "named foo",
55 "files": Array [
56 "test/fixtures/foo.js",
57 ],
58 "parent": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
59 "pid": 60878,
60 "ppid": 60876,
61 "time": 1555110276382,
62 "uuid": "625ef291-93c0-40b2-a869-70587f7e8fac",
63 },
64 "62c33964-203a-4e6a-b1ff-8a046eeb8912": ProcessInfo {
65 "argv": Array [
66 "/usr/local/bin/node",
67 "test/fixtures/bar.js",
68 ],
69 "coverageFilename": "62c33964-203a-4e6a-b1ff-8a046eeb8912.json",
70 "cwd": "test/fixtures",
71 "execArgv": Array [],
72 "externalId": "",
73 "files": Array [
74 "test/fixtures/bar.js",
75 ],
76 "parent": "625ef291-93c0-40b2-a869-70587f7e8fac",
77 "pid": 60879,
78 "ppid": 60878,
79 "time": 1555110276750,
80 "uuid": "62c33964-203a-4e6a-b1ff-8a046eeb8912",
81 },
82 }
83 `
84
85 exports[`test/process-db.js TAP render process tree > coverage map after render 1`] = `
86 CoverageMap {
87 "data": Null Object {
88 "test/fixtures/bar.js": FileCoverage {
89 "data": Object {
90 "_coverageSchema": "43e27e138ebf9cfc5966b082cf9a028302ed4184",
91 "b": Object {
92 "0": Array [
93 2,
94 0,
95 ],
96 },
97 "branchMap": Object {
98 "0": Object {
99 "line": 1,
100 "loc": Object {
101 "end": Object {
102 "column": 1,
103 "line": 5,
104 },
105 "start": Object {
106 "column": 0,
107 "line": 1,
108 },
109 },
110 "locations": Array [
111 Object {
112 "end": Object {
113 "column": 1,
114 "line": 5,
115 },
116 "start": Object {
117 "column": 0,
118 "line": 1,
119 },
120 },
121 Object {
122 "end": Object {
123 "column": 1,
124 "line": 5,
125 },
126 "start": Object {
127 "column": 0,
128 "line": 1,
129 },
130 },
131 ],
132 "type": "if",
133 },
134 },
135 "contentHash": "7951eed4c89fa9c43d3583a66380b2c01bc6484cb7d88c25b32378ee5fd021e0",
136 "f": Object {},
137 "fnMap": Object {},
138 "hash": "08207f2d4d7fc4645a4a76ff07632e061da28a55",
139 "path": "test/fixtures/bar.js",
140 "s": Object {
141 "0": 2,
142 "1": 2,
143 "2": 0,
144 },
145 "statementMap": Object {
146 "0": Object {
147 "end": Object {
148 "column": 1,
149 "line": 5,
150 },
151 "start": Object {
152 "column": 0,
153 "line": 1,
154 },
155 },
156 "1": Object {
157 "end": Object {
158 "column": 32,
159 "line": 2,
160 },
161 "start": Object {
162 "column": 2,
163 "line": 2,
164 },
165 },
166 "2": Object {
167 "end": Object {
168 "column": 38,
169 "line": 4,
170 },
171 "start": Object {
172 "column": 2,
173 "line": 4,
174 },
175 },
176 },
177 },
178 },
179 "test/fixtures/foo.js": FileCoverage {
180 "data": Object {
181 "_coverageSchema": "43e27e138ebf9cfc5966b082cf9a028302ed4184",
182 "b": Object {
183 "0": Array [
184 2,
185 0,
186 ],
187 },
188 "branchMap": Object {
189 "0": Object {
190 "line": 1,
191 "loc": Object {
192 "end": Object {
193 "column": 1,
194 "line": 11,
195 },
196 "start": Object {
197 "column": 0,
198 "line": 1,
199 },
200 },
201 "locations": Array [
202 Object {
203 "end": Object {
204 "column": 1,
205 "line": 11,
206 },
207 "start": Object {
208 "column": 0,
209 "line": 1,
210 },
211 },
212 Object {
213 "end": Object {
214 "column": 1,
215 "line": 11,
216 },
217 "start": Object {
218 "column": 0,
219 "line": 1,
220 },
221 },
222 ],
223 "type": "if",
224 },
225 },
226 "contentHash": "28f728352972e76f26e4de0e59bf96c0134868d6fff542168fe24690b0bb034b",
227 "f": Object {},
228 "fnMap": Object {},
229 "hash": "db8b7aa31bb6299efc0f6dbe709b0adc75d2e0d5",
230 "path": "test/fixtures/foo.js",
231 "s": Object {
232 "0": 2,
233 "1": 2,
234 "2": 2,
235 "3": 0,
236 },
237 "statementMap": Object {
238 "0": Object {
239 "end": Object {
240 "column": 1,
241 "line": 11,
242 },
243 "start": Object {
244 "column": 0,
245 "line": 1,
246 },
247 },
248 "1": Object {
249 "end": Object {
250 "column": 31,
251 "line": 2,
252 },
253 "start": Object {
254 "column": 2,
255 "line": 2,
256 },
257 },
258 "2": Object {
259 "end": Object {
260 "column": 4,
261 "line": 5,
262 },
263 "start": Object {
264 "column": 2,
265 "line": 3,
266 },
267 },
268 "3": Object {
269 "end": Object {
270 "column": 4,
271 "line": 10,
272 },
273 "start": Object {
274 "column": 2,
275 "line": 7,
276 },
277 },
278 },
279 },
280 },
281 },
282 }
283 `
284
285 exports[`test/process-db.js TAP render process tree > label after render 1`] = `
286 nyc
287 71.42 % Lines
288 `
289
290 exports[`test/process-db.js TAP render process tree > render the tree 1`] = `
291 nyc
292 │ 71.42 % Lines
293 └─┬ /usr/local/bin/node test/fixtures/foo.test.js
294 │ 71.42 % Lines
295 ├── /usr/local/bin/node test/fixtures/bar.js
296 │ 66.66 % Lines
297 └─┬ /usr/local/bin/node test/fixtures/foo.js
298 │ 71.42 % Lines
299 └── /usr/local/bin/node test/fixtures/bar.js
300 66.66 % Lines
301
302 `
303
304 exports[`test/process-db.js TAP writing and reading index > must match snapshot 1`] = `
305 Object {
306 "externalIds": Object {
307 "named foo": Object {
308 "children": Array [
309 "62c33964-203a-4e6a-b1ff-8a046eeb8912",
310 ],
311 "root": "625ef291-93c0-40b2-a869-70587f7e8fac",
312 },
313 "root process": Object {
314 "children": Array [
315 "300fc62b-eaf2-4505-981b-39567e807f94",
316 "625ef291-93c0-40b2-a869-70587f7e8fac",
317 "62c33964-203a-4e6a-b1ff-8a046eeb8912",
318 ],
319 "root": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
320 },
321 },
322 "files": Object {
323 "test/fixtures/bar.js": Array [
324 "300fc62b-eaf2-4505-981b-39567e807f94",
325 "62c33964-203a-4e6a-b1ff-8a046eeb8912",
326 ],
327 "test/fixtures/foo.js": Array [
328 "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
329 "625ef291-93c0-40b2-a869-70587f7e8fac",
330 ],
331 },
332 "processes": Object {
333 "0f4e28ea-5b03-4677-8c0d-263e81b42f7e": Object {
334 "children": Array [
335 "300fc62b-eaf2-4505-981b-39567e807f94",
336 "625ef291-93c0-40b2-a869-70587f7e8fac",
337 ],
338 "externalId": "root process",
339 "parent": null,
340 },
341 "300fc62b-eaf2-4505-981b-39567e807f94": Object {
342 "children": Array [],
343 "parent": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
344 },
345 "625ef291-93c0-40b2-a869-70587f7e8fac": Object {
346 "children": Array [
347 "62c33964-203a-4e6a-b1ff-8a046eeb8912",
348 ],
349 "externalId": "named foo",
350 "parent": "0f4e28ea-5b03-4677-8c0d-263e81b42f7e",
351 },
352 "62c33964-203a-4e6a-b1ff-8a046eeb8912": Object {
353 "children": Array [],
354 "parent": "625ef291-93c0-40b2-a869-70587f7e8fac",
355 },
356 },
357 }
358 `