mirror of
https://github.com/anomalyco/opencode.git
synced 2026-05-17 18:12:42 +00:00
effect: move tool flags into RuntimeFlags (#27198)
This commit is contained in:
@@ -16,12 +16,24 @@ describe("RuntimeFlags", () => {
|
||||
fromConfig({
|
||||
OPENCODE_PURE: "true",
|
||||
OPENCODE_DISABLE_DEFAULT_PLUGINS: "true",
|
||||
OPENCODE_EXPERIMENTAL: "true",
|
||||
OPENCODE_ENABLE_EXA: "true",
|
||||
OPENCODE_ENABLE_PARALLEL: "true",
|
||||
OPENCODE_ENABLE_QUESTION_TOOL: "true",
|
||||
OPENCODE_CLIENT: "desktop",
|
||||
}),
|
||||
),
|
||||
)
|
||||
|
||||
expect(flags.pure).toBe(true)
|
||||
expect(flags.disableDefaultPlugins).toBe(true)
|
||||
expect(flags.enableExa).toBe(true)
|
||||
expect(flags.enableParallel).toBe(true)
|
||||
expect(flags.enableQuestionTool).toBe(true)
|
||||
expect(flags.experimentalScout).toBe(true)
|
||||
expect(flags.experimentalLspTool).toBe(true)
|
||||
expect(flags.experimentalPlanMode).toBe(true)
|
||||
expect(flags.client).toBe("desktop")
|
||||
}),
|
||||
)
|
||||
|
||||
@@ -31,6 +43,8 @@ describe("RuntimeFlags", () => {
|
||||
|
||||
expect(flags.pure).toBe(false)
|
||||
expect(flags.disableDefaultPlugins).toBe(true)
|
||||
expect(flags.enableExa).toBe(false)
|
||||
expect(flags.client).toBe("cli")
|
||||
}),
|
||||
)
|
||||
|
||||
@@ -43,6 +57,9 @@ describe("RuntimeFlags", () => {
|
||||
ConfigProvider.fromUnknown({
|
||||
OPENCODE_PURE: "true",
|
||||
OPENCODE_DISABLE_DEFAULT_PLUGINS: "true",
|
||||
OPENCODE_EXPERIMENTAL: "true",
|
||||
OPENCODE_ENABLE_EXA: "true",
|
||||
OPENCODE_CLIENT: "desktop",
|
||||
}),
|
||||
),
|
||||
),
|
||||
@@ -50,6 +67,8 @@ describe("RuntimeFlags", () => {
|
||||
|
||||
expect(flags.pure).toBe(false)
|
||||
expect(flags.disableDefaultPlugins).toBe(false)
|
||||
expect(flags.enableExa).toBe(false)
|
||||
expect(flags.client).toBe("cli")
|
||||
}),
|
||||
)
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user