fix(test): resolve Feishu hoisted mock export syntax error#32128
fix(test): resolve Feishu hoisted mock export syntax error#32128steipete merged 1 commit intoopenclaw:mainfrom
Conversation
Greptile SummaryFixes
Confidence Score: 5/5
Last reviewed commit: 07f2593 |
3d83040 to
53c0d10
Compare
|
@vincentkoc Would appreciate a review when you get a chance — this fixes 2 Feishu test suites that crash on import ( |
|
CI failure in |
713f607 to
2521af4
Compare
2521af4 to
8899ce0
Compare
958241d to
221ef35
Compare
CI failures: upstream fixes included + remaining
|
36ad611 to
bc3c869
Compare
|
Looks like Peter already fixed it. Commit 0e16749 landed on main — fixes both the pairing-store.ts lint errors, the agents-utils.ts lint error, AND bumps the googlechat/memory-core deps (npm audit fix). Both issues are already resolved on main. Please take a look at this @Takhoffman at your leisure. |
- Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-Authored-By: Claude Opus 4.6 <[email protected]>
bc3c869 to
d58210d
Compare
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
…32128) - Remove vi.hoisted() wrapper from exported mock in shared module (Vitest cannot export hoisted variables) - Inline vi.hoisted + vi.mock in startup test so Vitest's per-file hoisting registers mocks before production imports Co-authored-by: Claude Opus 4.6 <[email protected]>
Summary
SyntaxError: Cannot export hoisted variablevi.hoisted()result cannot be exported from a shared mock module (Vitest limitation)vi.hoisted(() => vi.fn())with plainvi.fn()in shared mock; inlinevi.hoisted()+vi.mock()in startup testTest plan
pnpm vitest run extensions/feishu/— 29/29 suites pass, 230 tests passpnpm tsgo— zero errorspnpm format— passes🤖 Generated with Claude Code