feat(channels): add google chat adapter and webhook route
This commit is contained in:
@@ -375,6 +375,30 @@ describe('configSchema — teams', () => {
|
||||
});
|
||||
});
|
||||
|
||||
describe('configSchema — google_chat', () => {
|
||||
const minimalConfig = {
|
||||
telegram: { bot_token: 'test', allowed_chat_ids: [1] },
|
||||
models: { default: { provider: 'anthropic', model: 'claude-3' } },
|
||||
};
|
||||
|
||||
it('accepts google_chat config and defaults filters', () => {
|
||||
const result = configSchema.parse({
|
||||
...minimalConfig,
|
||||
google_chat: {
|
||||
service_account_key_file: '/tmp/gchat-service-account.json',
|
||||
},
|
||||
});
|
||||
|
||||
expect(result.google_chat).toBeDefined();
|
||||
if (!result.google_chat) {
|
||||
throw new Error('Expected google_chat config');
|
||||
}
|
||||
expect(result.google_chat.service_account_key_file).toBe('/tmp/gchat-service-account.json');
|
||||
expect(result.google_chat.allowed_space_names).toEqual([]);
|
||||
expect(result.google_chat.require_mention).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('configSchema — whatsapp', () => {
|
||||
const minimalConfig = {
|
||||
telegram: { bot_token: 'test', allowed_chat_ids: [1] },
|
||||
|
||||
Reference in New Issue
Block a user