fix: resolve unit test failures

- Add chalk to jest transformIgnorePatterns so ESM chalk import works
- Fix wrong mock path in gemini.test.ts (../src -> ../../src)

Signed-off-by: majiayu000 <1835304752@qq.com>
This commit is contained in:
majiayu000
2026-03-28 00:13:14 +08:00
parent 6982e76cf5
commit 53414438d1
2 changed files with 2 additions and 2 deletions

View File

@@ -33,7 +33,7 @@ describe('Gemini', () => {
process.env = { ...oldEnv };
jest.mock('@google/generative-ai');
jest.mock('../src/commands/config');
jest.mock('../../src/commands/config');
jest.mock('@clack/prompts', () => ({
intro: jest.fn(),