Skip to content

Commit 84bcee9

Browse files
committed
fix(memory-core): rename __testing to testing in CJK regression tests (#80613)
Upstream lint sweep #83542 (chore(lint): remove underscore-dangle allow list) removed the `__testing` alias from the lint allow list, exposing that the 4 new CJK regression tests added in c497966 referenced `__testing.dedupeEntries` while the import statement only brought in `testing`. After upstream's rebase merge into this branch, tsgo reported TS2552 on dreaming-phases.test.ts:3028,3042,3054,3063 and a TS7006 implicit any on the inferred entry param (cascade from the missing identifier). Fix: use the imported `testing.dedupeEntries` directly. The `testing as __testing` alias still exists in dreaming-phases.ts for any other consumers; this only adjusts the local test references. Verification: pnpm tsgo:extensions:test reports 0 errors in dreaming-phases.test.ts (the 6 remaining errors are pre-existing infra issues unrelated to this branch: @openclaw/proxyline resolution, src/plugin-sdk/file-lock.ts type narrowing).
1 parent 0ab1157 commit 84bcee9

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

extensions/memory-core/src/dreaming-phases.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3025,7 +3025,7 @@ describe("dedupeEntries — CJK-aware snippet similarity (#80613)", () => {
30253025
const a = makeRecall("cjk-a", "教训:配置中实验开关字段是叫做规则");
30263026
const b = makeRecall("cjk-b", "教训:配置里实验开关的字段叫做规则");
30273027

3028-
const deduped = __testing.dedupeEntries([a, b], 0.5);
3028+
const deduped = testing.dedupeEntries([a, b], 0.5);
30293029
expect(deduped).toHaveLength(1);
30303030
// First entry survives; recall counts merge in.
30313031
expect(deduped[0]?.key).toBe("cjk-a");
@@ -3039,7 +3039,7 @@ describe("dedupeEntries — CJK-aware snippet similarity (#80613)", () => {
30393039
const a = makeRecall("mixed-a", "Plan 实验开关字段叫做 exRule");
30403040
const b = makeRecall("mixed-b", "Plan 整个产品体系彻底重构 exRule");
30413041

3042-
const deduped = __testing.dedupeEntries([a, b], 0.7);
3042+
const deduped = testing.dedupeEntries([a, b], 0.7);
30433043
expect(deduped).toHaveLength(2);
30443044
expect(deduped.map((entry) => entry.key).toSorted()).toStrictEqual(["mixed-a", "mixed-b"]);
30453045
});
@@ -3051,7 +3051,7 @@ describe("dedupeEntries — CJK-aware snippet similarity (#80613)", () => {
30513051
const a = makeRecall("en-a", "Plan config experiment toggle field is named exRule");
30523052
const b = makeRecall("en-b", "Plan configuration uses experiment toggle field named exRule");
30533053

3054-
const deduped = __testing.dedupeEntries([a, b], 0.4);
3054+
const deduped = testing.dedupeEntries([a, b], 0.4);
30553055
expect(deduped).toHaveLength(1);
30563056
expect(deduped[0]?.key).toBe("en-a");
30573057
});
@@ -3060,7 +3060,7 @@ describe("dedupeEntries — CJK-aware snippet similarity (#80613)", () => {
30603060
const a = makeRecall("short-a", "weather: sunny");
30613061
const b = makeRecall("short-b", "deploy: blocked");
30623062

3063-
const deduped = __testing.dedupeEntries([a, b], 0.5);
3063+
const deduped = testing.dedupeEntries([a, b], 0.5);
30643064
expect(deduped).toHaveLength(2);
30653065
});
30663066
});

0 commit comments

Comments
 (0)