fix(config): align default.yaml with server schema

This commit is contained in:
William Valentin
2026-02-15 18:11:29 -08:00
parent 83b8bea5eb
commit 81385745e6
5 changed files with 86 additions and 4 deletions
+22
View File
@@ -72,6 +72,28 @@ telegram:
expect(configValidates?.status).toBe('fail');
});
it('warns when deprecated server.tailscale_only key is present', async () => {
mkdirSync(testDir, { recursive: true });
const configPath = join(testDir, 'config.yaml');
writeFileSync(configPath, `
telegram:
bot_token: "test-token"
allowed_chat_ids: [123]
server:
tailscale_only: true
models:
default:
provider: anthropic
model: claude-sonnet
`);
const ctx: DoctorContext = { configPath, dataDir: testDir };
const results = await runChecks(ctx);
const deprecated = results.find(r => r.label.includes('deprecated keys'));
expect(deprecated?.status).toBe('warn');
});
it('reports PASS for writable data directory', async () => {
mkdirSync(testDir, { recursive: true });
const configPath = join(testDir, 'config.yaml');