# 🚀 Sync Gemini CLI v0.2.1 - Major Feature Update (#483)

This commit is contained in:
tanzhenxin
2025-09-01 14:48:55 +08:00
committed by GitHub
parent 1610c1586e
commit 2572faf726
292 changed files with 19401 additions and 5941 deletions

View File

@@ -563,5 +563,30 @@ describe('Server Config (config.ts)', () => {
const config = new Config(paramsWithoutTelemetry);
expect(config.getTelemetryOtlpEndpoint()).toBe(DEFAULT_OTLP_ENDPOINT);
});
it('should return provided OTLP protocol', () => {
const params: ConfigParameters = {
...baseParams,
telemetry: { enabled: true, otlpProtocol: 'http' },
};
const config = new Config(params);
expect(config.getTelemetryOtlpProtocol()).toBe('http');
});
it('should return default OTLP protocol if not provided', () => {
const params: ConfigParameters = {
...baseParams,
telemetry: { enabled: true },
};
const config = new Config(params);
expect(config.getTelemetryOtlpProtocol()).toBe('grpc');
});
it('should return default OTLP protocol if telemetry object is not provided', () => {
const paramsWithoutTelemetry: ConfigParameters = { ...baseParams };
delete paramsWithoutTelemetry.telemetry;
const config = new Config(paramsWithoutTelemetry);
expect(config.getTelemetryOtlpProtocol()).toBe('grpc');
});
});
});