test(agent-core): align turn telemetry expectations with provider_type (#1194)

Update the turn_started/turn_ended and api_error telemetry assertions to
expect provider_type, matching the telemetry property rename in #1184.
This commit is contained in:
Haozhe 2026-06-29 14:44:26 +08:00 committed by GitHub
parent 821847cb4b
commit c8d1d76de5
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -84,7 +84,7 @@ describe('Agent turn flow', () => {
const started = records.find((candidate) => candidate.event === 'turn_started');
expect(started).toEqual({
event: 'turn_started',
properties: expect.objectContaining({ mode: 'agent', type: 'kimi', protocol: 'kimi' }),
properties: expect.objectContaining({ mode: 'agent', provider_type: 'kimi', protocol: 'kimi' }),
});
const ended = records.find((candidate) => candidate.event === 'turn_ended');
@ -93,7 +93,7 @@ describe('Agent turn flow', () => {
properties: expect.objectContaining({
mode: 'agent',
reason: 'completed',
type: 'kimi',
provider_type: 'kimi',
protocol: 'kimi',
duration_ms: expect.any(Number),
}),
@ -1455,7 +1455,7 @@ describe('Agent turn flow', () => {
error_type: errorType,
model: 'mock-model',
alias: 'mock-model',
type: 'kimi',
provider_type: 'kimi',
protocol: 'kimi',
retryable: expect.any(Boolean),
duration_ms: expect.any(Number),