@seanhogg/builderforce-memory 2026.10.66 → 2026.10.68
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/dist/knowledge/comparability.d.ts +100 -0
- package/dist/knowledge/comparability.d.ts.map +1 -0
- package/dist/knowledge/comparability.js +149 -0
- package/dist/knowledge/comparability.js.map +1 -0
- package/dist/knowledge/contentHash.d.ts +28 -0
- package/dist/knowledge/contentHash.d.ts.map +1 -0
- package/dist/knowledge/contentHash.js +54 -0
- package/dist/knowledge/contentHash.js.map +1 -0
- package/dist/knowledge/extractFile.d.ts +2 -0
- package/dist/knowledge/extractFile.d.ts.map +1 -1
- package/dist/knowledge/extractFile.js +1 -1
- package/dist/knowledge/extractFile.js.map +1 -1
- package/dist/knowledge/extractJob.d.ts +5 -2
- package/dist/knowledge/extractJob.d.ts.map +1 -1
- package/dist/knowledge/extractJob.js +1 -1
- package/dist/knowledge/extractJob.js.map +1 -1
- package/dist/knowledge/findingBuilder.d.ts +12 -2
- package/dist/knowledge/findingBuilder.d.ts.map +1 -1
- package/dist/knowledge/findingBuilder.js +9 -2
- package/dist/knowledge/findingBuilder.js.map +1 -1
- package/dist/knowledge/findingIdentity.d.ts +52 -0
- package/dist/knowledge/findingIdentity.d.ts.map +1 -0
- package/dist/knowledge/findingIdentity.js +70 -0
- package/dist/knowledge/findingIdentity.js.map +1 -0
- package/dist/knowledge/findingModel.d.ts +30 -0
- package/dist/knowledge/findingModel.d.ts.map +1 -0
- package/dist/knowledge/findingModel.js +6 -0
- package/dist/knowledge/findingModel.js.map +1 -0
- package/dist/knowledge/findings.d.ts.map +1 -1
- package/dist/knowledge/findings.js +17 -9
- package/dist/knowledge/findings.js.map +1 -1
- package/dist/knowledge/godModule.js +2 -2
- package/dist/knowledge/godModule.js.map +1 -1
- package/dist/knowledge/index.d.ts +12 -1
- package/dist/knowledge/index.d.ts.map +1 -1
- package/dist/knowledge/index.js +8 -1
- package/dist/knowledge/index.js.map +1 -1
- package/dist/knowledge/lineage.d.ts +35 -0
- package/dist/knowledge/lineage.d.ts.map +1 -0
- package/dist/knowledge/lineage.js +114 -0
- package/dist/knowledge/lineage.js.map +1 -0
- package/dist/knowledge/merkle.d.ts +65 -0
- package/dist/knowledge/merkle.d.ts.map +1 -0
- package/dist/knowledge/merkle.js +158 -0
- package/dist/knowledge/merkle.js.map +1 -0
- package/dist/knowledge/model.d.ts +3 -16
- package/dist/knowledge/model.d.ts.map +1 -1
- package/dist/knowledge/owedFiles.d.ts +5 -2
- package/dist/knowledge/owedFiles.d.ts.map +1 -1
- package/dist/knowledge/owedFiles.js +20 -5
- package/dist/knowledge/owedFiles.js.map +1 -1
- package/dist/knowledge/plan.d.ts +8 -0
- package/dist/knowledge/plan.d.ts.map +1 -1
- package/dist/knowledge/plan.js +20 -6
- package/dist/knowledge/plan.js.map +1 -1
- package/dist/knowledge/refs.d.ts +18 -2
- package/dist/knowledge/refs.d.ts.map +1 -1
- package/dist/knowledge/refs.js +38 -8
- package/dist/knowledge/refs.js.map +1 -1
- package/dist/knowledge/resolve.d.ts.map +1 -1
- package/dist/knowledge/resolve.js +2 -0
- package/dist/knowledge/resolve.js.map +1 -1
- package/dist/knowledge/reviewModel.d.ts +8 -1
- package/dist/knowledge/reviewModel.d.ts.map +1 -1
- package/dist/knowledge/reviewPrefetch.d.ts +2 -1
- package/dist/knowledge/reviewPrefetch.d.ts.map +1 -1
- package/dist/knowledge/reviewPrefetch.js +8 -4
- package/dist/knowledge/reviewPrefetch.js.map +1 -1
- package/dist/knowledge/sources.d.ts +10 -1
- package/dist/knowledge/sources.d.ts.map +1 -1
- package/dist/knowledge/sources.js +17 -2
- package/dist/knowledge/sources.js.map +1 -1
- package/package.json +1 -1
- package/src/contract/exports.snapshot.json +29 -0
- package/src/contract/regression.contentHash.test.ts +30 -0
- package/src/contract/regression.lineage.test.ts +27 -0
- package/src/contract/regression.listing.test.ts +85 -0
- package/src/contract/regression.refs.test.ts +49 -0
- package/src/contract/types.contract.test.ts +57 -0
- package/src/knowledge/comparability.analysis.test.ts +73 -0
- package/src/knowledge/comparability.test.ts +44 -0
- package/src/knowledge/comparability.ts +182 -0
- package/src/knowledge/contentHash.test.ts +81 -0
- package/src/knowledge/contentHash.ts +55 -0
- package/src/knowledge/extractFile.ts +4 -2
- package/src/knowledge/extractJob.ts +5 -3
- package/src/knowledge/findingBuilder.ts +17 -2
- package/src/knowledge/findingIdentity.test.ts +102 -0
- package/src/knowledge/findingIdentity.ts +92 -0
- package/src/knowledge/findingModel.ts +32 -0
- package/src/knowledge/findings.ts +17 -9
- package/src/knowledge/godModule.ts +2 -2
- package/src/knowledge/index.ts +18 -1
- package/src/knowledge/lineage.test.ts +106 -0
- package/src/knowledge/lineage.ts +123 -0
- package/src/knowledge/merkle.test.ts +137 -0
- package/src/knowledge/merkle.ts +164 -0
- package/src/knowledge/model.ts +4 -18
- package/src/knowledge/owedFiles.contentHash.test.ts +58 -0
- package/src/knowledge/owedFiles.ts +23 -5
- package/src/knowledge/plan.ts +28 -6
- package/src/knowledge/refs.ts +36 -8
- package/src/knowledge/resolve.ts +2 -0
- package/src/knowledge/reviewModel.ts +8 -1
- package/src/knowledge/reviewPrefetch.ts +10 -6
- package/src/knowledge/sources.ts +20 -2
|
@@ -265,18 +265,23 @@
|
|
|
265
265
|
"serializeRow"
|
|
266
266
|
],
|
|
267
267
|
"./knowledge": [
|
|
268
|
+
"ANALYSIS_ANCHOR_VERSION",
|
|
269
|
+
"ANALYSIS_TOOL_COUNT",
|
|
268
270
|
"AVG_SECTION_BYTES",
|
|
271
|
+
"BASELINE_CONTENT_HASH_RULE",
|
|
269
272
|
"CLONE_GROUP_BADGE",
|
|
270
273
|
"COMMUNITY_EDGE_KINDS",
|
|
271
274
|
"COMMUNITY_LOUVAIN_MAX_NODES",
|
|
272
275
|
"COMMUNITY_LP_ITERATIONS",
|
|
273
276
|
"COMMUNITY_MAX_ITERATIONS",
|
|
274
277
|
"COMMUNITY_MAX_PASSES",
|
|
278
|
+
"CONTENT_HASH_RULE",
|
|
275
279
|
"DEFAULT_INDEX_PARAMS",
|
|
276
280
|
"DEFAULT_MAX_FILE_BYTES",
|
|
277
281
|
"DEFAULT_MAX_NODES",
|
|
278
282
|
"DEFAULT_REVIEW_JUDGE_CONCURRENCY",
|
|
279
283
|
"DEFAULT_REVIEW_MODEL_CALLS",
|
|
284
|
+
"DEFAULT_RULE_VERSION",
|
|
280
285
|
"DEFAULT_TRACE_DEPTH",
|
|
281
286
|
"DEFAULT_TRACE_EDGE_KINDS",
|
|
282
287
|
"DEFAULT_TRACE_STEPS",
|
|
@@ -290,6 +295,8 @@
|
|
|
290
295
|
"FALLBACK_PACK_ID",
|
|
291
296
|
"GOD_MODULE_KIND",
|
|
292
297
|
"GOD_MODULE_LIMITS",
|
|
298
|
+
"LINEAGE_MIN_JACCARD",
|
|
299
|
+
"LINEAGE_MIN_MEMBERS",
|
|
293
300
|
"LocalSnapshotStore",
|
|
294
301
|
"MAX_CLAIM_TEXT_CHARS",
|
|
295
302
|
"MAX_FINDING_NODES",
|
|
@@ -313,6 +320,9 @@
|
|
|
313
320
|
"UNANCHORED_AREA",
|
|
314
321
|
"UNPARTITIONED_LANE",
|
|
315
322
|
"aboutTargets",
|
|
323
|
+
"analysisMeta",
|
|
324
|
+
"anchorKindOfRef",
|
|
325
|
+
"anchorWithSnippet",
|
|
316
326
|
"applyCommunities",
|
|
317
327
|
"applyRunEvent",
|
|
318
328
|
"areaImportance",
|
|
@@ -323,19 +333,27 @@
|
|
|
323
333
|
"byImportance",
|
|
324
334
|
"canonicalDump",
|
|
325
335
|
"canonicalJson",
|
|
336
|
+
"canonicalListing",
|
|
337
|
+
"changedPaths",
|
|
326
338
|
"clampClaim",
|
|
327
339
|
"clampQuote",
|
|
328
340
|
"codeTokenize",
|
|
329
341
|
"communityTable",
|
|
342
|
+
"comparable",
|
|
343
|
+
"compareAnalysis",
|
|
330
344
|
"compareManifestKey",
|
|
331
345
|
"compareStr",
|
|
332
346
|
"components",
|
|
347
|
+
"composeAnchor",
|
|
333
348
|
"composePacks",
|
|
334
349
|
"computeFindings",
|
|
350
|
+
"contentHash",
|
|
351
|
+
"contentHashRuleOf",
|
|
335
352
|
"contradictionRule",
|
|
336
353
|
"createKnowledgeIndex",
|
|
337
354
|
"createModelLimiter",
|
|
338
355
|
"crossesSystems",
|
|
356
|
+
"defaultAnchorOf",
|
|
339
357
|
"detectCommunities",
|
|
340
358
|
"entityKey",
|
|
341
359
|
"entityName",
|
|
@@ -357,6 +375,8 @@
|
|
|
357
375
|
"godModuleFindings",
|
|
358
376
|
"graphDigest",
|
|
359
377
|
"hashDocText",
|
|
378
|
+
"identityOf",
|
|
379
|
+
"identityOfIssue",
|
|
360
380
|
"ignoreMatcher",
|
|
361
381
|
"ignoreSourcesOf",
|
|
362
382
|
"isAssetPath",
|
|
@@ -364,17 +384,24 @@
|
|
|
364
384
|
"isBinaryText",
|
|
365
385
|
"isDocumentPath",
|
|
366
386
|
"isRateLimit",
|
|
387
|
+
"isRootFilePath",
|
|
367
388
|
"jobOf",
|
|
368
389
|
"judgedManifestKey",
|
|
390
|
+
"kindOfAnchor",
|
|
369
391
|
"knownKeysOf",
|
|
370
392
|
"knownKeysOfEntities",
|
|
371
393
|
"loadKnowledgeIndex",
|
|
372
394
|
"loadPartitions",
|
|
373
395
|
"localSnapshotStore",
|
|
374
396
|
"matchGlob",
|
|
397
|
+
"matchLineage",
|
|
375
398
|
"mediaTypeOfPath",
|
|
399
|
+
"merkleTree",
|
|
376
400
|
"nameResolver",
|
|
401
|
+
"normalizeAnalysis",
|
|
377
402
|
"normalizeKey",
|
|
403
|
+
"normalizePath",
|
|
404
|
+
"normalizeSnippet",
|
|
378
405
|
"oneLineLabel",
|
|
379
406
|
"orderForJudging",
|
|
380
407
|
"orphanDocumentRule",
|
|
@@ -393,6 +420,7 @@
|
|
|
393
420
|
"putExtract",
|
|
394
421
|
"putNoExtract",
|
|
395
422
|
"reasonOf",
|
|
423
|
+
"refAnchor",
|
|
396
424
|
"refreshPlan",
|
|
397
425
|
"requestKeyFor",
|
|
398
426
|
"resolveDocument",
|
|
@@ -405,6 +433,7 @@
|
|
|
405
433
|
"sha256Hex",
|
|
406
434
|
"slowestSteps",
|
|
407
435
|
"slugOf",
|
|
436
|
+
"splitSourceRef",
|
|
408
437
|
"srcRef",
|
|
409
438
|
"startRun",
|
|
410
439
|
"toCards",
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/contract/regression.contentHash.test.ts — the content identity is EOL-normalized (PRD 41 §B2 step 0), so the same
|
|
3
|
+
* commit checked out on Windows with `core.autocrlf` and on Linux names every file, and the root, identically.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
import { contentHash, merkleTree } from '../knowledge/index.js';
|
|
7
|
+
|
|
8
|
+
const utf8 = (s: string) => new TextEncoder().encode(s);
|
|
9
|
+
|
|
10
|
+
/** One commit's text files, as git writes them to a Linux working tree (LF). */
|
|
11
|
+
const COMMIT: Record<string, string> = {
|
|
12
|
+
'README.md': '# Project\n\nSome prose.\n',
|
|
13
|
+
'src/index.ts': 'export const a = 1;\nexport const b = 2;\n',
|
|
14
|
+
'src/lib/util.ts': 'export function f() {\n return 42;\n}\n',
|
|
15
|
+
};
|
|
16
|
+
|
|
17
|
+
/** The same files as a Windows `core.autocrlf=true` checkout writes them: every LF a CRLF. */
|
|
18
|
+
const autocrlf = (text: string) => text.replace(/\n/g, '\r\n');
|
|
19
|
+
|
|
20
|
+
const listing = (files: Record<string, string>, eol: (s: string) => string = (s) => s) =>
|
|
21
|
+
Object.entries(files).map(([path, text]) => ({ path, hash: contentHash(utf8(eol(text))) }));
|
|
22
|
+
|
|
23
|
+
describe('regression: cross-OS content identity', () => {
|
|
24
|
+
it('regression: a Windows autocrlf checkout and a Linux checkout hash differently', () => {
|
|
25
|
+
const linux = listing(COMMIT);
|
|
26
|
+
const windows = listing(COMMIT, autocrlf);
|
|
27
|
+
expect(windows).toEqual(linux);
|
|
28
|
+
expect(merkleTree(windows).root).toBe(merkleTree(linux).root);
|
|
29
|
+
});
|
|
30
|
+
});
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/contract/regression.lineage.test.ts — a finding's id hashes ALL its refs (`findingId`), so a clone group that
|
|
3
|
+
* gained a member read as one resolved finding plus one introduced finding (PRD 41 §C3). Identity v2 anchors the
|
|
4
|
+
* group on its clone-group badge, and `matchLineage` reads the pair as ONE `changed (grew)`.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import { CLONE_GROUP_BADGE, genericFindings, identityOf, matchLineage, type KEdge, type KNode, type KnowledgeGraph } from '../knowledge/index.js';
|
|
8
|
+
|
|
9
|
+
const ref = (p: string) => `src:r::${p}`;
|
|
10
|
+
const node = (p: string): KNode => ({ ref: ref(p), kind: 'file', label: p, pack: 'code', importance: 0, origin: 'extracted', badges: { [CLONE_GROUP_BADGE]: 'jscpd-1' } });
|
|
11
|
+
const dup = (a: string, b: string): KEdge => ({ from: ref(a), to: ref(b), kind: 'duplicate', weight: 1, origin: 'extracted' });
|
|
12
|
+
const clones = (files: string[]) => {
|
|
13
|
+
const g: KnowledgeGraph = {
|
|
14
|
+
scope: { rootId: 'r', packs: ['code'], digest: 'd' }, nodes: files.map(node), edges: files.slice(1).map((f) => dup(files[0]!, f)), findings: [],
|
|
15
|
+
stats: { sources: files.length, nodes: files.length, edges: files.length - 1, stale: 0, truncated: false },
|
|
16
|
+
};
|
|
17
|
+
return genericFindings(g, new Map()).map((f) => identityOf(f));
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
describe('regression: lineage', () => {
|
|
21
|
+
it('regression: a clone group gaining a member is changed (grew), never resolved + introduced', () => {
|
|
22
|
+
const before = clones(['a.ts', 'b.ts']), after = clones(['a.ts', 'b.ts', 'c.ts']);
|
|
23
|
+
const lineage = matchLineage(before, after);
|
|
24
|
+
expect(lineage).toEqual([{ lineage: 'changed', change: 'grew', before: before[0]!.id, after: after[0]!.id }]);
|
|
25
|
+
expect(lineage.some((e) => e.lineage === 'resolved' || e.lineage === 'introduced')).toBe(false);
|
|
26
|
+
});
|
|
27
|
+
});
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/contract/regression.listing.test.ts — the plan never throws over what a host lists (PRD 41 §B2 step 4, §B8.1).
|
|
3
|
+
* Plan paths go through the ONE normalization (POSIX, NFC), so they are the Merkle paths; a listing that collides once
|
|
4
|
+
* normalized, or names `.`/`..`, is skipped with a reason, and a re-spelled file is still read by the source's spelling.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import { hashText } from '../ingest/hash.js';
|
|
8
|
+
import { InMemoryIngestManifest } from '../ingest/IngestionPipeline.js';
|
|
9
|
+
import { extractJob, type ExtractJob, type ExtractPool } from '../knowledge/extractJob.js';
|
|
10
|
+
import { merkleTree } from '../knowledge/merkle.js';
|
|
11
|
+
import { DOCS_PACK } from '../knowledge/packs/docs.js';
|
|
12
|
+
import { planDetail, refreshPlan } from '../knowledge/plan.js';
|
|
13
|
+
import { reviewDirectory } from '../knowledge/review.js';
|
|
14
|
+
import { args, fakeJudge, memSource, memStore } from '../knowledge/testkit.test-util.js';
|
|
15
|
+
|
|
16
|
+
const NFC = 'café.md', NFD = 'café.md';
|
|
17
|
+
|
|
18
|
+
describe('regression: a host listing cannot break the plan', () => {
|
|
19
|
+
it('regression: an NFC/NFD pair of one name with different content plans (one kept, one skipped) instead of throwing', async () => {
|
|
20
|
+
const source = memSource({ [NFC]: '# Café\nnfc\n', [NFD]: '# Café\nnfd\n', 'ok.md': '# OK\n' });
|
|
21
|
+
const detail = await planDetail(source, new InMemoryIngestManifest(), [DOCS_PACK]);
|
|
22
|
+
expect(detail.files.map((f) => f.path)).toEqual([NFC, 'ok.md']);
|
|
23
|
+
expect(detail.files[0]!.listedPath).toBe(NFD); // the first by (normalized, listed) bytewise
|
|
24
|
+
expect(detail.plan.skipped).toContainEqual({ path: NFC, reason: 'duplicate-path' });
|
|
25
|
+
expect(detail.plan.merkleRoot).toBe(merkleTree(detail.files).root);
|
|
26
|
+
});
|
|
27
|
+
|
|
28
|
+
it('regression: a `.`/`..` path or a path listed twice is skipped with a reason, never thrown', async () => {
|
|
29
|
+
const source = memSource({ 'a.md': '# A\n', './a.md': '# A2\n', '../up.md': '# Up\n', 'd/./x.md': '# X\n' });
|
|
30
|
+
const detail = await planDetail(source, new InMemoryIngestManifest(), [DOCS_PACK]);
|
|
31
|
+
expect(detail.files.map((f) => f.path)).toEqual(['a.md']);
|
|
32
|
+
expect(detail.plan.skipped).toEqual(expect.arrayContaining([
|
|
33
|
+
{ path: '../up.md', reason: 'invalid-path' }, { path: 'd/./x.md', reason: 'invalid-path' }, { path: 'a.md', reason: 'duplicate-path' },
|
|
34
|
+
]));
|
|
35
|
+
});
|
|
36
|
+
|
|
37
|
+
it('regression: a file the source lists in NFD is read by that spelling and stored under its NFC path', async () => {
|
|
38
|
+
const source = memSource({ [NFD]: '# Café\nbody\n' });
|
|
39
|
+
const store = memStore();
|
|
40
|
+
const report = await reviewDirectory(args(source, store, new InMemoryIngestManifest(), { judgement: fakeJudge() }));
|
|
41
|
+
expect(report.readErrors).toBe(0);
|
|
42
|
+
expect(source.reads).toContain(NFD);
|
|
43
|
+
expect(source.reads).not.toContain(NFC);
|
|
44
|
+
});
|
|
45
|
+
|
|
46
|
+
it('regression: a pool job for an NFD-named file carries the listed spelling in readByPool.path and the NFC identity in job.path', async () => {
|
|
47
|
+
const source = memSource({ [NFD]: '# Café\nbody\n' });
|
|
48
|
+
const jobs: ExtractJob[] = [];
|
|
49
|
+
const pool: ExtractPool = async (job) => {
|
|
50
|
+
jobs.push(job);
|
|
51
|
+
const doc = await source.read(job.readByPool!.path);
|
|
52
|
+
return extractJob({ ...job, doc } as ExtractJob, [DOCS_PACK]);
|
|
53
|
+
};
|
|
54
|
+
const report = await reviewDirectory(args(source, memStore(), new InMemoryIngestManifest(), { extractPool: pool, deferRead: true }));
|
|
55
|
+
expect(report.failures).toEqual([]);
|
|
56
|
+
expect(report.extracted).toBe(1);
|
|
57
|
+
expect(jobs).toHaveLength(1);
|
|
58
|
+
expect(jobs[0]!.path).toBe(NFC);
|
|
59
|
+
expect(jobs[0]!.readByPool!.path).toBe(NFD);
|
|
60
|
+
expect(jobs[0]!.readByPool!.path).not.toBe(jobs[0]!.path);
|
|
61
|
+
expect(source.reads).toEqual([NFD]);
|
|
62
|
+
});
|
|
63
|
+
|
|
64
|
+
it('regression: the hashOf and readTimeoutMs hooks receive the listed (NFD) spelling, never the NFC identity', async () => {
|
|
65
|
+
const source = memSource({ [NFD]: '# Café\nbody\n' });
|
|
66
|
+
const hashed: string[] = [], timed: string[] = [];
|
|
67
|
+
source.hashOf = (text: string, path: string) => { hashed.push(path); return hashText(text); };
|
|
68
|
+
source.readTimeoutMs = (path: string) => { timed.push(path); return undefined; };
|
|
69
|
+
const report = await reviewDirectory(args(source, memStore(), new InMemoryIngestManifest(), { judgement: fakeJudge() }));
|
|
70
|
+
expect(report.failures).toEqual([]);
|
|
71
|
+
expect(hashed).toEqual([NFD]);
|
|
72
|
+
expect(timed.length).toBeGreaterThan(0);
|
|
73
|
+
expect(new Set(timed)).toEqual(new Set([NFD]));
|
|
74
|
+
});
|
|
75
|
+
|
|
76
|
+
it('regression: refreshPlan (Continue) keeps a re-spelled file\'s listedPath', async () => {
|
|
77
|
+
const source = memSource({ [NFD]: '# Café\nbody\n', 'ok.md': '# OK\n' });
|
|
78
|
+
const manifest = new InMemoryIngestManifest();
|
|
79
|
+
const detail = await planDetail(source, manifest, [DOCS_PACK]);
|
|
80
|
+
expect(detail.files.find((f) => f.path === NFC)!.listedPath).toBe(NFD);
|
|
81
|
+
const refreshed = await refreshPlan(detail, manifest);
|
|
82
|
+
expect(refreshed.files.find((f) => f.path === NFC)!.listedPath).toBe(NFD);
|
|
83
|
+
expect(refreshed.files.find((f) => f.path === 'ok.md')!.listedPath).toBeUndefined();
|
|
84
|
+
});
|
|
85
|
+
});
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/contract/regression.refs.test.ts — `pathOfRef` / `fileRefOf` split `src:<rootId>::<path>` on the FIRST '::', so a root id
|
|
3
|
+
* ending in ':' (the linked repo's `cloud:<id>:`) read `src:cloud:5:::docs/a.md` as path `:docs/a.md`. They now follow
|
|
4
|
+
* `splitSourceRef`, the same grammar as Builderforce.ai's agent-tools `rootId.ts`. Each case pinned by one `regression:` test.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
import { fileRefOf, pathOfRef, splitSourceRef, srcRef, type NodeRef } from '../knowledge/index.js';
|
|
8
|
+
|
|
9
|
+
describe('regression: source ref grammar', () => {
|
|
10
|
+
it('regression: a root id ending in ":" keeps its colon; the path does not start with one', () => {
|
|
11
|
+
const ref = srcRef('cloud:5:', 'docs/a.md');
|
|
12
|
+
expect(ref).toBe('src:cloud:5:::docs/a.md');
|
|
13
|
+
expect(splitSourceRef(ref)).toEqual({ rootId: 'cloud:5:', path: 'docs/a.md' });
|
|
14
|
+
expect(pathOfRef(ref)).toBe('docs/a.md');
|
|
15
|
+
expect(pathOfRef(srcRef('cloud:5::', '.eslintrc'))).toBe('.eslintrc');
|
|
16
|
+
expect(fileRefOf(`${ref}#intro` as NodeRef)).toBe(ref);
|
|
17
|
+
});
|
|
18
|
+
|
|
19
|
+
it('regression: a path containing "::" stays whole (only the first "::" after the root separates)', () => {
|
|
20
|
+
const ref = srcRef('vscode:f-1', 'src/a::b.ts');
|
|
21
|
+
expect(splitSourceRef(ref)).toEqual({ rootId: 'vscode:f-1', path: 'src/a::b.ts' });
|
|
22
|
+
expect(pathOfRef(ref)).toBe('src/a::b.ts');
|
|
23
|
+
expect(fileRefOf(`${ref}#s` as NodeRef)).toBe(ref);
|
|
24
|
+
});
|
|
25
|
+
|
|
26
|
+
it('regression: a known root id splits by its exact prefix, so even a path starting with ":" is exact', () => {
|
|
27
|
+
expect(splitSourceRef('src:cloud:5:::x', ['cloud:5'])).toEqual({ rootId: 'cloud:5', path: ':x' });
|
|
28
|
+
expect(splitSourceRef('src:cloud:5:::x')).toEqual({ rootId: 'cloud:5:', path: 'x' });
|
|
29
|
+
});
|
|
30
|
+
|
|
31
|
+
it('regression: "#section" handling of src refs is unchanged (pathOfRef drops it, splitSourceRef keeps the full path)', () => {
|
|
32
|
+
const ref = srcRef('r', 'docs/a.md');
|
|
33
|
+
expect(pathOfRef(`${ref}#intro`)).toBe('docs/a.md');
|
|
34
|
+
expect(fileRefOf(`${ref}#intro` as NodeRef)).toBe(ref);
|
|
35
|
+
expect(fileRefOf(ref)).toBe(ref);
|
|
36
|
+
expect(splitSourceRef(srcRef('r', 'src/C#/a.cs'))?.path).toBe('src/C#/a.cs');
|
|
37
|
+
expect(pathOfRef(srcRef('r', 'src/C#/a.cs'))).toBe('src/C');
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
it('regression: fact: and ent: refs are not source refs and pass through unchanged', () => {
|
|
41
|
+
for (const ref of ['fact:claim:1', 'ent:x::y', 'fact:a#b'] as NodeRef[]) {
|
|
42
|
+
expect(splitSourceRef(ref)).toBeUndefined();
|
|
43
|
+
expect(pathOfRef(ref)).toBeUndefined();
|
|
44
|
+
expect(fileRefOf(ref)).toBe(ref);
|
|
45
|
+
}
|
|
46
|
+
expect(splitSourceRef('src:no-separator')).toBeUndefined();
|
|
47
|
+
expect(splitSourceRef('src:::x')).toBeUndefined();
|
|
48
|
+
});
|
|
49
|
+
});
|
|
@@ -12,6 +12,8 @@
|
|
|
12
12
|
*/
|
|
13
13
|
|
|
14
14
|
import type { ParsedSection, SourceDocument } from '../ingest/types.js';
|
|
15
|
+
import type { changedPaths, contentHash, CONTENT_HASH_RULE, merkleTree, MerkleEntry, MerkleTree, PlanDetail, ReviewPlan } from '../knowledge/index.js';
|
|
16
|
+
import type { BASELINE_CONTENT_HASH_RULE, canonicalListing, contentHashRuleOf, ListingSkipReason } from '../knowledge/index.js';
|
|
15
17
|
import type {
|
|
16
18
|
DirectorySource, Extracted, ExtractJob, ExtractJobResult, GraphApp, GraphOutline, GraphReadSkip, GraphSystem, KEdge, KNode, KnowledgeGraph, KnowledgeStore,
|
|
17
19
|
OutlineFile, OutlineCommunity, NodePlacement, ReviewFailure, ReviewFailureChunks, ReviewPhase, ReviewReport, ReviewRun, ReviewRunPhase, ReviewStep, ScopeRecord,
|
|
@@ -19,6 +21,10 @@ import type {
|
|
|
19
21
|
RowChange, RowPersistence,
|
|
20
22
|
} from '../knowledge/index.js';
|
|
21
23
|
import type { PlannedFile } from '../knowledge/index.js';
|
|
24
|
+
import type {
|
|
25
|
+
AnalysisIssue, AnchorKind, CodeAnalysisSnapshot, ComparabilityMeta, Finding, FindingIdentity, LineageEntry,
|
|
26
|
+
comparable, compareAnalysis, identityOf, matchLineage,
|
|
27
|
+
} from '../knowledge/index.js';
|
|
22
28
|
import { placementOf } from '../knowledge/index.js';
|
|
23
29
|
import { canonicalDump, ExtractFailed, failuresOf, failureTotal, LocalSnapshotStore, localSnapshotStore, type ExtractorState } from '../knowledge/index.js';
|
|
24
30
|
|
|
@@ -103,6 +109,31 @@ export type ExtractFailed_constructor = Expect<Equal<ConstructorParameters<typeo
|
|
|
103
109
|
export type ExtractorState_failures = Expect<Equal<ExtractorState['failures'], ReadonlyMap<string, { hash: string; count: number }> | undefined>>;
|
|
104
110
|
// ExtractorState.oversized: claimed documents over the size cap, planned as assets; optional so a hand-built state stays valid.
|
|
105
111
|
export type ExtractorState_oversized = Expect<Equal<ExtractorState['oversized'], ReadonlySet<string> | undefined>>;
|
|
112
|
+
// ExtractorState.contentHashRule: the content-hash rule the entry recorded (absent: none recorded, which never owes a file); optional so a hand-built state stays valid.
|
|
113
|
+
export type ExtractorState_contentHashRule = Expect<Equal<ExtractorState['contentHashRule'], string | undefined>>;
|
|
114
|
+
|
|
115
|
+
/* ── Content identity and directory Merkle hashes (PRD 41 §B2 steps 0 and 4) ───────────────────────────────── */
|
|
116
|
+
export type contentHash_signature = Expect<Equal<typeof contentHash, (bytes: Uint8Array) => string>>;
|
|
117
|
+
export type CONTENT_HASH_RULE_type = Expect<Equal<typeof CONTENT_HASH_RULE, 'eol-lf@1'>>;
|
|
118
|
+
export type MerkleEntry_shape = Expect<Equal<MerkleEntry, { name: string; kind: 'file' | 'dir'; hash: string }>>;
|
|
119
|
+
export type MerkleTree_shape = Expect<Equal<MerkleTree, {
|
|
120
|
+
root: string; dirs: ReadonlyMap<string, string>; entries: ReadonlyMap<string, ReadonlyArray<MerkleEntry>>;
|
|
121
|
+
}>>;
|
|
122
|
+
export type merkleTree_signature = Expect<Equal<typeof merkleTree, (files: ReadonlyArray<{ path: string; hash: string }>) => MerkleTree>>;
|
|
123
|
+
export type changedPaths_signature = Expect<Equal<typeof changedPaths, (before: MerkleTree, after: MerkleTree) => string[]>>;
|
|
124
|
+
export type ReviewPlan_merkleRoot = Expect<Equal<ReviewPlan['merkleRoot'], string | undefined>>;
|
|
125
|
+
export type PlanDetail_merkle = Expect<Equal<PlanDetail['merkle'], MerkleTree | undefined>>;
|
|
126
|
+
export type BASELINE_CONTENT_HASH_RULE_type = Expect<Equal<typeof BASELINE_CONTENT_HASH_RULE, 'eol-lf@1'>>;
|
|
127
|
+
export type contentHashRuleOf_signature = Expect<Equal<typeof contentHashRuleOf, (recorded: string | undefined) => string>>;
|
|
128
|
+
// The plan never throws over a listing: invalid and colliding paths are skipped with a reason; a re-spelled path keeps the source's spelling for reads.
|
|
129
|
+
export type ReviewPlan_skipped_reason = Expect<Equal<
|
|
130
|
+
ReviewPlan['skipped'][number]['reason'], 'ignored' | 'too-large' | 'no-pack' | 'invalid-path' | 'duplicate-path'
|
|
131
|
+
>>;
|
|
132
|
+
export type PlannedFile_listedPath = Expect<Equal<PlannedFile['listedPath'], string | undefined>>;
|
|
133
|
+
export type canonicalListing_skipped = Expect<Equal<
|
|
134
|
+
ReturnType<typeof canonicalListing<{ path: string }>>['skipped'], Array<{ path: string; reason: ListingSkipReason }>
|
|
135
|
+
>>;
|
|
136
|
+
export type ListingSkipReason_values = Expect<Equal<ListingSkipReason, 'invalid-path' | 'duplicate-path'>>;
|
|
106
137
|
|
|
107
138
|
/* ── DirectorySource: optional per-path hooks ──────────────────────────────────────────────────────────────── */
|
|
108
139
|
// hashOf takes the path (a host whose read() transforms bytes returns the listing hash for it); a one-argument hashOf still satisfies it.
|
|
@@ -228,6 +259,32 @@ export type NodePlacement_shape = Expect<Equal<NodePlacement, { kind: 'partition
|
|
|
228
259
|
export type placementOf_signature = Expect<Equal<ReturnType<typeof placementOf>, NodePlacement | undefined>>;
|
|
229
260
|
export type KEdge_verdict = Expect<Equal<KEdge['verdict'], 'allowed' | 'same' | 'skips' | 'upward' | undefined>>;
|
|
230
261
|
|
|
262
|
+
/* ── Finding identity v2, lineage, comparability (PRD 41 §C3/§C9) ─────────────────────────────────────────── */
|
|
263
|
+
export type AnchorKind_values = Expect<Equal<AnchorKind, 'symbol' | 'route' | 'package' | 'file' | 'group'>>;
|
|
264
|
+
export type Finding_anchor_is_optional = Expect<Equal<IsOptional<Finding, 'anchor'>, true>>;
|
|
265
|
+
export type Finding_anchorKind = Expect<Equal<Finding['anchorKind'], AnchorKind | undefined>>;
|
|
266
|
+
export type FindingIdentity_shape = Expect<Equal<FindingIdentity, { id: string; anchor: string; anchorKind: AnchorKind; members: string[] }>>;
|
|
267
|
+
export type identityOf_signature = Expect<Equal<typeof identityOf, (f: Finding, ruleVersion?: number) => FindingIdentity>>;
|
|
268
|
+
export type LineageEntry_shape = Expect<Equal<LineageEntry, {
|
|
269
|
+
lineage: 'introduced' | 'resolved' | 'changed' | 'persisting'; change?: 'grew' | 'shrank' | 'moved'; before?: string; after?: string;
|
|
270
|
+
}>>;
|
|
271
|
+
export type matchLineage_signature = Expect<Equal<
|
|
272
|
+
typeof matchLineage, (before: readonly FindingIdentity[], after: readonly FindingIdentity[]) => LineageEntry[]
|
|
273
|
+
>>;
|
|
274
|
+
export type ComparabilityMeta_shape = Expect<Equal<ComparabilityMeta, {
|
|
275
|
+
extractor?: string; extractorVersion?: string | number; contentHashRule?: string; tools?: Record<string, string>;
|
|
276
|
+
scope?: string; repo?: string; branch?: string; truncated?: boolean; failed?: string[];
|
|
277
|
+
}>>;
|
|
278
|
+
export type comparable_signature = Expect<Equal<
|
|
279
|
+
typeof comparable, (before: ComparabilityMeta, after: ComparabilityMeta) => { comparable: boolean; reasons: string[] }
|
|
280
|
+
>>;
|
|
281
|
+
export type AnalysisIssue_anchor_is_optional = Expect<Equal<IsOptional<AnalysisIssue, 'anchor'>, true>>;
|
|
282
|
+
export type compareAnalysis_result = Expect<Equal<
|
|
283
|
+
ReturnType<typeof compareAnalysis>,
|
|
284
|
+
{ comparable: boolean; reasons: string[]; added: AnalysisIssue[]; unchanged: AnalysisIssue[]; resolved: AnalysisIssue[] }
|
|
285
|
+
>>;
|
|
286
|
+
export type CodeAnalysisSnapshot_version = Expect<Equal<CodeAnalysisSnapshot['version'], 1>>;
|
|
287
|
+
|
|
231
288
|
describe('type contract', () => {
|
|
232
289
|
it('is enforced by `npm run check:contract-types` (tsc over tsconfig.contract.json), not at run time', () => {
|
|
233
290
|
// The values above only exist so the `satisfies` / `@ts-expect-error` lines are real code; this proves the file loads.
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/knowledge/comparability.analysis.test.ts — the `normalizeAnalysis` / `compareAnalysis` cases ported
|
|
3
|
+
* from Builderforce.ai agent-tools `codeAnalysis.test.ts`, assertions unchanged (the parity oracle).
|
|
4
|
+
* Only the imports changed: the analyzer list comes from agent-tools' `codeAnalysisTool.ts` there, so its
|
|
5
|
+
* names/versions are restated below; the analyzer-RUNNING cases stay in agent-tools.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
import { compareAnalysis, identityOfIssue, normalizeAnalysis, type CodeAnalysisSnapshot } from './comparability.js';
|
|
9
|
+
|
|
10
|
+
const ANALYZERS = [{ name: 'dependency-cruiser', version: '16.10.4' }, { name: 'jscpd', version: '4.0.5' }, { name: 'knip', version: '5.62.0' }];
|
|
11
|
+
|
|
12
|
+
const dependency = { modules: [{ source: 'src/a.ts', dependencies: [{ resolved: 'src/b.ts', circular: true }, { resolved: 'node:fs', coreModule: true }] }, { source: 'src/b.ts', dependencies: [] }] };
|
|
13
|
+
const duplicates = { duplicates: [{ fragment: 'return input + 1;', firstFile: { name: 'src/a.ts', start: 2, end: 7 }, secondFile: { name: 'src/b.ts', start: 5, end: 10 } }] };
|
|
14
|
+
const unused = { files: ['src/dead.ts'], issues: [{ file: 'src/b.ts', exports: [{ name: 'unused', line: 20 }], dependencies: [{ name: 'abandoned-library' }], unlisted: [{ name: 'missing-library' }] }] };
|
|
15
|
+
const snapshot = (): CodeAnalysisSnapshot => ({ version: 1, id: 'scan', capturedAt: '2026-10-18T12:00:00.000Z', source: { branch: 'main', commit: 'abc', dirty: false }, tools: ANALYZERS.map((a) => ({ name: a.name, version: a.version, status: 'complete' })), ...normalizeAnalysis(dependency, duplicates, unused) });
|
|
16
|
+
|
|
17
|
+
describe('measured code analysis', () => {
|
|
18
|
+
it('normalizes edges, clone locations, unused files, exports and dependencies separately', () => {
|
|
19
|
+
const value = snapshot();
|
|
20
|
+
expect(value.edges).toEqual([{ from: 'src/a.ts', to: 'src/b.ts', circular: true }]);
|
|
21
|
+
expect(value.issues.map((i) => i.kind)).toEqual(['duplicate', 'unused-file', 'unused-export', 'unused-dependency']);
|
|
22
|
+
expect(value.issues[0]?.locations[1]).toEqual({ path: 'src/b.ts', startLine: 5, endLine: 10 });
|
|
23
|
+
expect(value.issues[0]?.snippet).toBe('return input + 1;');
|
|
24
|
+
});
|
|
25
|
+
it('retains clone identity when code shifts lines', () => {
|
|
26
|
+
const shifted = structuredClone(duplicates); shifted.duplicates[0]!.firstFile.start = 80;
|
|
27
|
+
expect(normalizeAnalysis(dependency, shifted, unused).issues[0]?.id).toBe(snapshot().issues[0]?.id);
|
|
28
|
+
});
|
|
29
|
+
it('measures resolved and unchanged findings rather than assuming every missing result is fixed', () => {
|
|
30
|
+
const baseline = snapshot(); const current = snapshot(); current.issues = current.issues.slice(1);
|
|
31
|
+
expect(compareAnalysis(current, baseline)).toMatchObject({ comparable: true, resolved: [baseline.issues[0]], unchanged: current.issues });
|
|
32
|
+
current.tools[1]!.status = 'failed';
|
|
33
|
+
expect(compareAnalysis(current, baseline)).toMatchObject({ comparable: false, resolved: [] });
|
|
34
|
+
expect(compareAnalysis(current)).toMatchObject({ comparable: false, resolved: [] });
|
|
35
|
+
});
|
|
36
|
+
});
|
|
37
|
+
|
|
38
|
+
describe('identityOfIssue: an issue saved before anchors existed', () => {
|
|
39
|
+
it('recomposes the anchor normalizeAnalysis writes, snippet hash included — also for a fragment over 4000 characters', () => {
|
|
40
|
+
const long = { duplicates: [{ ...duplicates.duplicates[0]!, fragment: `${'x = x + 1;\n'.repeat(500)}tail` }] };
|
|
41
|
+
for (const dups of [duplicates, long]) {
|
|
42
|
+
for (const issue of normalizeAnalysis(dependency, dups, unused).issues) {
|
|
43
|
+
const { anchor, ...legacy } = issue;
|
|
44
|
+
expect(identityOfIssue(legacy).anchor).toBe(anchor);
|
|
45
|
+
expect(identityOfIssue(issue).anchor).toBe(anchor);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
});
|
|
49
|
+
});
|
|
50
|
+
|
|
51
|
+
describe('compareAnalysis reasons', () => {
|
|
52
|
+
it('are sorted and deduped after tools-incomplete is added', () => {
|
|
53
|
+
const fewer = snapshot(); fewer.tools = fewer.tools.slice(1); // drops dependency-cruiser: sorts before tools-incomplete
|
|
54
|
+
fewer.source.scope = 'z';
|
|
55
|
+
const { reasons } = compareAnalysis(fewer, snapshot());
|
|
56
|
+
expect(reasons).toEqual(['scope-changed', 'tool-missing:dependency-cruiser', 'tools-incomplete']);
|
|
57
|
+
expect([...reasons].sort()).toEqual(reasons);
|
|
58
|
+
});
|
|
59
|
+
});
|
|
60
|
+
|
|
61
|
+
describe('compareAnalysis delegates to comparable()', () => {
|
|
62
|
+
it('names why two snapshots are not comparable', () => {
|
|
63
|
+
const baseline = snapshot(); const current = snapshot();
|
|
64
|
+
expect(compareAnalysis(current, baseline).reasons).toEqual([]);
|
|
65
|
+
current.tools[1]!.status = 'failed';
|
|
66
|
+
expect(compareAnalysis(current, baseline).reasons).toEqual(['analyzer-failed:jscpd']);
|
|
67
|
+
expect(compareAnalysis(current).reasons).toEqual(['no-baseline']);
|
|
68
|
+
const fewer = snapshot(); fewer.tools = fewer.tools.slice(0, 2);
|
|
69
|
+
expect(compareAnalysis(fewer, snapshot()).reasons).toEqual(['tool-missing:knip', 'tools-incomplete']);
|
|
70
|
+
const scoped = snapshot(); scoped.source.scope = 'packages/app';
|
|
71
|
+
expect(compareAnalysis(scoped, snapshot()).reasons).toEqual(['scope-changed']);
|
|
72
|
+
});
|
|
73
|
+
});
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* src/knowledge/comparability.test.ts — `comparable()` (PRD 41 §C9): each stable reason code.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { comparable, type ComparabilityMeta } from './comparability.js';
|
|
6
|
+
|
|
7
|
+
const base: ComparabilityMeta = {
|
|
8
|
+
extractor: 'tree-sitter@0.25', extractorVersion: 3, contentHashRule: 'sha256-lf', tools: { jscpd: '4.0.5', knip: '5.1.0' },
|
|
9
|
+
scope: '.', repo: 'r', branch: 'main', truncated: false, failed: [],
|
|
10
|
+
};
|
|
11
|
+
const reasonsOf = (after: Partial<ComparabilityMeta>, before: Partial<ComparabilityMeta> = {}) =>
|
|
12
|
+
comparable({ ...base, ...before }, { ...base, ...after }).reasons;
|
|
13
|
+
|
|
14
|
+
describe('comparable', () => {
|
|
15
|
+
it('two equal sides are comparable with no reasons', () => {
|
|
16
|
+
expect(comparable(base, { ...base })).toEqual({ comparable: true, reasons: [] });
|
|
17
|
+
expect(comparable({}, {})).toEqual({ comparable: true, reasons: [] });
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
it('names each reason with a stable code', () => {
|
|
21
|
+
expect(reasonsOf({ extractor: 'regex@1' })).toEqual(['extractor-mismatch']);
|
|
22
|
+
expect(reasonsOf({ extractor: 'tree-sitter@0.26' })).toEqual(['extractor-version-changed']);
|
|
23
|
+
expect(reasonsOf({ extractorVersion: 4 })).toEqual(['extractor-version-changed']);
|
|
24
|
+
expect(reasonsOf({ contentHashRule: 'sha256-raw' })).toEqual(['content-hash-rule-changed']);
|
|
25
|
+
expect(reasonsOf({ tools: { jscpd: '4.0.6', knip: '5.1.0' } })).toEqual(['tool-version-changed:jscpd']);
|
|
26
|
+
expect(reasonsOf({ tools: { jscpd: '4.0.5' } })).toEqual(['tool-missing:knip']);
|
|
27
|
+
expect(reasonsOf({ failed: ['knip'] }, { failed: ['jscpd'] })).toEqual(['analyzer-failed:jscpd', 'analyzer-failed:knip']);
|
|
28
|
+
expect(reasonsOf({ scope: 'packages/app' })).toEqual(['scope-changed']);
|
|
29
|
+
expect(reasonsOf({ repo: 'other' })).toEqual(['repo-changed']);
|
|
30
|
+
expect(reasonsOf({ branch: 'dev' })).toEqual(['branch-changed']);
|
|
31
|
+
expect(reasonsOf({}, { truncated: true })).toEqual(['truncated']);
|
|
32
|
+
});
|
|
33
|
+
|
|
34
|
+
it('an absent content-hash rule IS the baseline rule (eol-lf@1), not a change', () => {
|
|
35
|
+
expect(comparable({}, { contentHashRule: 'eol-lf@1' })).toEqual({ comparable: true, reasons: [] });
|
|
36
|
+
expect(comparable({ contentHashRule: 'eol-lf@1' }, {})).toEqual({ comparable: true, reasons: [] });
|
|
37
|
+
expect(comparable({}, { contentHashRule: 'eol-lf@2' }).reasons).toEqual(['content-hash-rule-changed']);
|
|
38
|
+
});
|
|
39
|
+
|
|
40
|
+
it('collects every reason, sorted and deduped, and is not comparable', () => {
|
|
41
|
+
const r = comparable({ ...base, failed: ['knip'] }, { ...base, failed: ['knip'], scope: 'x', truncated: true });
|
|
42
|
+
expect(r).toEqual({ comparable: false, reasons: ['analyzer-failed:knip', 'scope-changed', 'truncated'] });
|
|
43
|
+
});
|
|
44
|
+
});
|