1+ import { providerIdentifiers } from "@roo-code/types"
12import fs from "fs/promises"
23import path from "path"
34
@@ -58,7 +59,7 @@ describe("Settings Storage", () => {
5859 const settingsData = {
5960 onboardingProviderChoice : OnboardingProviderChoice . Byok ,
6061 mode : "architect" ,
61- provider : " anthropic" as const ,
62+ provider : providerIdentifiers . anthropic ,
6263 model : "claude-sonnet-4-20250514" ,
6364 reasoningEffort : "high" as const ,
6465 }
@@ -95,7 +96,7 @@ describe("Settings Storage", () => {
9596
9697 it ( "should merge settings with existing ones" , async ( ) => {
9798 await saveSettings ( { mode : "code" } )
98- await saveSettings ( { provider : " openrouter" as const } )
99+ await saveSettings ( { provider : providerIdentifiers . openrouter } )
99100
100101 const savedData = await fs . readFile ( expectedSettingsFile , "utf-8" )
101102 const settings = JSON . parse ( savedData )
@@ -107,7 +108,7 @@ describe("Settings Storage", () => {
107108 it ( "should save all default settings fields" , async ( ) => {
108109 await saveSettings ( {
109110 mode : "architect" ,
110- provider : " anthropic" as const ,
111+ provider : providerIdentifiers . anthropic ,
111112 model : "claude-opus-4.6" ,
112113 reasoningEffort : "medium" as const ,
113114 consecutiveMistakeLimit : 5 ,
@@ -155,7 +156,7 @@ describe("Settings Storage", () => {
155156 await saveSettings ( {
156157 onboardingProviderChoice : OnboardingProviderChoice . Byok ,
157158 mode : "architect" ,
158- provider : " gemini" as const ,
159+ provider : providerIdentifiers . gemini ,
159160 } )
160161
161162 await resetOnboarding ( )
@@ -172,7 +173,7 @@ describe("Settings Storage", () => {
172173 // Test that all the settings that can be used as defaults are properly saved and loaded
173174 const defaultSettings = {
174175 mode : "debug" ,
175- provider : "openai-native" as const ,
176+ provider : providerIdentifiers . openaiNative ,
176177 model : "gpt-4o" ,
177178 reasoningEffort : "low" as const ,
178179 consecutiveMistakeLimit : 7 ,
@@ -205,7 +206,7 @@ describe("Settings Storage", () => {
205206 it ( "should support all settings together including requireApproval" , async ( ) => {
206207 const allSettings = {
207208 mode : "architect" ,
208- provider : " anthropic" as const ,
209+ provider : providerIdentifiers . anthropic ,
209210 model : "claude-sonnet-4-20250514" ,
210211 reasoningEffort : "high" as const ,
211212 requireApproval : true ,
@@ -231,7 +232,7 @@ describe("Settings Storage", () => {
231232 it ( "should support all settings together including oneshot" , async ( ) => {
232233 const allSettings = {
233234 mode : "architect" ,
234- provider : " anthropic" as const ,
235+ provider : providerIdentifiers . anthropic ,
235236 model : "claude-sonnet-4-20250514" ,
236237 reasoningEffort : "high" as const ,
237238 consecutiveMistakeLimit : 9 ,
0 commit comments