Files
oh-my-pi/packages/coding-agent/test/core/settings-manager-python.test.ts
T
can1357 92ec2550d2 refactor(coding-agent): reorganized test files to proper test directory structure
- Moved test files from src/core to test/core directory.
- Moved test files from src/core/tools to test/tools directory.
- Moved test files from src/discovery to test/discovery directory.
- Updated import paths to reflect new test file locations.
2026-01-19 00:07:23 +01:00

24 lines
846 B
TypeScript

import { describe, expect, it } from "bun:test";
import { SettingsManager } from "../../src/core/settings-manager";
describe("SettingsManager python settings", () => {
it("defaults to both and session", () => {
const settings = SettingsManager.inMemory();
expect(settings.getPythonToolMode()).toBe("both");
expect(settings.getPythonKernelMode()).toBe("session");
});
it("persists python tool and kernel modes", async () => {
const settings = SettingsManager.inMemory();
await settings.setPythonToolMode("bash-only");
await settings.setPythonKernelMode("per-call");
expect(settings.getPythonToolMode()).toBe("bash-only");
expect(settings.getPythonKernelMode()).toBe("per-call");
expect(settings.serialize().python?.toolMode).toBe("bash-only");
expect(settings.serialize().python?.kernelMode).toBe("per-call");
});
});