fix unit test
This commit is contained in:
@@ -12,6 +12,8 @@ describe('parseSmartCopilotSettings', () => {
|
||||
infioApiKey: '',
|
||||
openAIApiKey: '',
|
||||
anthropicApiKey: '',
|
||||
filesSearchMethod: 'auto',
|
||||
fuzzyMatchThreshold: 0.85,
|
||||
geminiApiKey: '',
|
||||
groqApiKey: '',
|
||||
deepseekApiKey: '',
|
||||
@@ -21,6 +23,7 @@ describe('parseSmartCopilotSettings', () => {
|
||||
applyModelProvider: 'OpenRouter',
|
||||
embeddingModelId: '',
|
||||
embeddingModelProvider: 'Google',
|
||||
experimentalDiffStrategy: false,
|
||||
defaultProvider: 'OpenRouter',
|
||||
alibabaQwenProvider: {
|
||||
name: 'AlibabaQwen',
|
||||
@@ -70,6 +73,7 @@ describe('parseSmartCopilotSettings', () => {
|
||||
apiProvider: 'openai',
|
||||
azureOAIApiSettings: '',
|
||||
openAIApiSettings: '',
|
||||
multiSearchReplaceDiffStrategy: true,
|
||||
ollamaApiSettings: '',
|
||||
triggers: DEFAULT_SETTINGS.triggers,
|
||||
delay: 500,
|
||||
@@ -85,10 +89,15 @@ describe('parseSmartCopilotSettings', () => {
|
||||
userMessageTemplate: '{{prefix}}<mask/>{{suffix}}',
|
||||
chainOfThoughRemovalRegex: '(.|\\n)*ANSWER:',
|
||||
dontIncludeDataviews: true,
|
||||
jinaApiKey: '',
|
||||
maxPrefixCharLimit: 4000,
|
||||
maxSuffixCharLimit: 4000,
|
||||
mode: 'ask',
|
||||
removeDuplicateMathBlockIndicator: true,
|
||||
removeDuplicateCodeBlockIndicator: true,
|
||||
ripgrepPath: '',
|
||||
serperApiKey: '',
|
||||
serperSearchEngine: 'google',
|
||||
ignoredFilePatterns: '**/secret/**\n',
|
||||
ignoredTags: '',
|
||||
cacheSuggestions: true,
|
||||
@@ -118,10 +127,10 @@ describe('parseSmartCopilotSettings', () => {
|
||||
useCustomUrl: false,
|
||||
},
|
||||
ollamaProvider: {
|
||||
name: 'Ollama',
|
||||
apiKey: '',
|
||||
apiKey: 'ollama',
|
||||
baseUrl: '',
|
||||
useCustomUrl: false,
|
||||
name: 'Ollama',
|
||||
useCustomUrl: true,
|
||||
},
|
||||
openaiProvider: {
|
||||
name: 'OpenAI',
|
||||
@@ -177,6 +186,8 @@ describe('settings migration', () => {
|
||||
infioApiKey: '',
|
||||
openAIApiKey: '',
|
||||
anthropicApiKey: '',
|
||||
filesSearchMethod: 'auto',
|
||||
fuzzyMatchThreshold: 0.85,
|
||||
geminiApiKey: '',
|
||||
groqApiKey: '',
|
||||
deepseekApiKey: '',
|
||||
@@ -186,6 +197,7 @@ describe('settings migration', () => {
|
||||
applyModelProvider: 'OpenRouter',
|
||||
embeddingModelId: '',
|
||||
embeddingModelProvider: 'Google',
|
||||
experimentalDiffStrategy: false,
|
||||
defaultProvider: 'OpenRouter',
|
||||
alibabaQwenProvider: {
|
||||
name: 'AlibabaQwen',
|
||||
@@ -235,6 +247,7 @@ describe('settings migration', () => {
|
||||
apiProvider: 'openai',
|
||||
azureOAIApiSettings: '',
|
||||
openAIApiSettings: '',
|
||||
multiSearchReplaceDiffStrategy: true,
|
||||
ollamaApiSettings: '',
|
||||
triggers: DEFAULT_SETTINGS.triggers,
|
||||
delay: 500,
|
||||
@@ -250,10 +263,15 @@ describe('settings migration', () => {
|
||||
userMessageTemplate: '{{prefix}}<mask/>{{suffix}}',
|
||||
chainOfThoughRemovalRegex: '(.|\\n)*ANSWER:',
|
||||
dontIncludeDataviews: true,
|
||||
jinaApiKey: '',
|
||||
maxPrefixCharLimit: 4000,
|
||||
maxSuffixCharLimit: 4000,
|
||||
mode: 'ask',
|
||||
removeDuplicateMathBlockIndicator: true,
|
||||
removeDuplicateCodeBlockIndicator: true,
|
||||
ripgrepPath: '',
|
||||
serperApiKey: '',
|
||||
serperSearchEngine: 'google',
|
||||
ignoredFilePatterns: '**/secret/**\n',
|
||||
ignoredTags: '',
|
||||
cacheSuggestions: true,
|
||||
@@ -283,10 +301,10 @@ describe('settings migration', () => {
|
||||
useCustomUrl: false,
|
||||
},
|
||||
ollamaProvider: {
|
||||
name: 'Ollama',
|
||||
apiKey: '',
|
||||
apiKey: 'ollama',
|
||||
baseUrl: '',
|
||||
useCustomUrl: false,
|
||||
name: 'Ollama',
|
||||
useCustomUrl: true,
|
||||
},
|
||||
openaiProvider: {
|
||||
name: 'OpenAI',
|
||||
|
||||
Reference in New Issue
Block a user