mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-05-02 21:50:52 +00:00
fix(review): address Copilot comments and fix CI build failure
- Copilot-instructions.md precedence: prefer .github/ path, do not load both when both exist - Simplify getModel() call: remove unnecessary typeof guard since Config already defines getModel() - Fix TS2352 type error in test: use proper mock cast pattern - Add getModel to base mockConfig for test consistency Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
fab4dc5949
commit
3ac54581a8
3 changed files with 7 additions and 9 deletions
|
|
@ -34,6 +34,7 @@ describe('BundledSkillLoader', () => {
|
|||
mockConfig = {
|
||||
getSkillManager: vi.fn().mockReturnValue(mockSkillManager),
|
||||
isCronEnabled: vi.fn().mockReturnValue(false),
|
||||
getModel: vi.fn().mockReturnValue(undefined),
|
||||
} as unknown as Config;
|
||||
});
|
||||
|
||||
|
|
@ -132,9 +133,9 @@ describe('BundledSkillLoader', () => {
|
|||
body: 'Review by {{model}} via Qwen Code',
|
||||
});
|
||||
mockSkillManager.listSkills.mockResolvedValue([skill]);
|
||||
(mockConfig as Record<string, unknown>).getModel = vi
|
||||
.fn()
|
||||
.mockReturnValue('qwen3-coder');
|
||||
(mockConfig.getModel as ReturnType<typeof vi.fn>).mockReturnValue(
|
||||
'qwen3-coder',
|
||||
);
|
||||
|
||||
const loader = new BundledSkillLoader(mockConfig);
|
||||
const commands = await loader.loadCommands(signal);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue