fix(whatsapp): sandbox chromium by default
This commit is contained in:
@@ -288,6 +288,29 @@ describe('configSchema — matrix', () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe('configSchema — whatsapp', () => {
|
||||
const minimalConfig = {
|
||||
telegram: { bot_token: 'test', allowed_chat_ids: [1] },
|
||||
models: { default: { provider: 'anthropic', model: 'claude-3' } },
|
||||
};
|
||||
|
||||
it('defaults whatsapp no_sandbox to false', () => {
|
||||
const result = configSchema.parse({
|
||||
...minimalConfig,
|
||||
whatsapp: {},
|
||||
});
|
||||
expect(result.whatsapp?.no_sandbox).toBe(false);
|
||||
});
|
||||
|
||||
it('accepts whatsapp no_sandbox override', () => {
|
||||
const result = configSchema.parse({
|
||||
...minimalConfig,
|
||||
whatsapp: { no_sandbox: true },
|
||||
});
|
||||
expect(result.whatsapp?.no_sandbox).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('configSchema — skills watcher', () => {
|
||||
const minimalConfig = {
|
||||
telegram: { bot_token: 'test', allowed_chat_ids: [1] },
|
||||
|
||||
@@ -373,6 +373,7 @@ const whatsappSchema = z.object({
|
||||
allowed_group_ids: z.array(z.string()).default([]),
|
||||
require_mention: z.boolean().default(true),
|
||||
data_dir: z.string().optional(),
|
||||
no_sandbox: z.boolean().default(false),
|
||||
}).optional();
|
||||
|
||||
const matrixSchema = z.object({
|
||||
|
||||
Reference in New Issue
Block a user