mirror of
https://github.com/QwenLM/qwen-code.git
synced 2025-12-20 08:47:44 +00:00
fix: test ci
This commit is contained in:
@@ -394,7 +394,17 @@ export async function loadCliConfig(
|
||||
? settings.enableOpenAILogging
|
||||
: argv.openaiLogging) ?? false,
|
||||
sampling_params: settings.sampling_params,
|
||||
systemPromptMappings: settings.systemPromptMappings,
|
||||
systemPromptMappings: settings.systemPromptMappings ?? [
|
||||
{
|
||||
baseUrls: [
|
||||
'https://dashscope.aliyuncs.com/compatible-mode/v1/',
|
||||
'https://dashscope-intl.aliyuncs.com/compatible-mode/v1/',
|
||||
],
|
||||
modelNames: ['qwen3-coder-plus'],
|
||||
template:
|
||||
'SYSTEM_TEMPLATE:{"name":"qwen3_coder","params":{"is_git_repository":{RUNTIME_VARS_IS_GIT_REPO},"sandbox":"{RUNTIME_VARS_SANDBOX}"}}',
|
||||
},
|
||||
],
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -33,6 +33,9 @@ describe('OpenAIContentGenerator Timeout Handling', () => {
|
||||
// Reset mocks
|
||||
vi.clearAllMocks();
|
||||
|
||||
// Mock environment variables
|
||||
vi.stubEnv('OPENAI_BASE_URL', '');
|
||||
|
||||
// Mock config
|
||||
mockConfig = {
|
||||
getContentGeneratorConfig: vi.fn().mockReturnValue({
|
||||
@@ -55,7 +58,7 @@ describe('OpenAIContentGenerator Timeout Handling', () => {
|
||||
vi.mocked(OpenAI).mockImplementation(() => mockOpenAIClient);
|
||||
|
||||
// Create generator instance
|
||||
generator = new OpenAIContentGenerator('test-api-key', 'gpt-4', mockConfig);
|
||||
generator = new OpenAIContentGenerator('test-key', 'gpt-4', mockConfig);
|
||||
});
|
||||
|
||||
afterEach(() => {
|
||||
|
||||
@@ -198,6 +198,7 @@ describe('Gemini Client (client.ts)', () => {
|
||||
getQuotaErrorOccurred: vi.fn().mockReturnValue(false),
|
||||
setQuotaErrorOccurred: vi.fn(),
|
||||
getNoBrowser: vi.fn().mockReturnValue(false),
|
||||
getSystemPromptMappings: vi.fn().mockReturnValue(undefined),
|
||||
};
|
||||
return mock as unknown as Config;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user