Skip to content

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

Merged
sailist merged 1 commit into
MoonshotAI:mainfrom
sailist:fix/tele
Jun 29, 2026
Merged

test(agent-core): align turn telemetry expectations with provider_type#1194
sailist merged 1 commit into
MoonshotAI:mainfrom
sailist:fix/tele

Conversation

@sailist

@sailist sailist commented Jun 29, 2026

Copy link
Copy Markdown
Collaborator

Related Issue

No linked issue. This fixes a CI regression introduced by #1184 ("refactor: standardize telemetry property names").

Problem

#1184 renamed the telemetry property typeprovider_type in the agent-core turn/tool telemetry (alongside successoutcome and duration_s/latency_msduration_ms) and updated most affected tests, but missed packages/agent-core/test/agent/turn.test.ts.

As a result, 12 test cases failed on CI:

  • tracks turn_ended telemetry with protocol props
  • tracks api_error telemetry for '429 status''generic step error' (11 cases)

All failed with the same diff:

- "type": "kimi"
+ "provider_type": "kimi"

The implementation is the intended source of truth; the test expectations were simply stale.

What changed

Updated the three stale type: 'kimi' expectations in turn.test.ts to provider_type: 'kimi', covering the turn_started/turn_ended assertion and the shared api_error expected-properties object. No runtime behavior change — test-only fix.

Verified locally: all 53 tests in packages/agent-core/test/agent/turn.test.ts pass.

Checklist

  • I have read the CONTRIBUTING document.
  • I have linked a related issue, or explained the problem above.
  • I have added tests that prove my feature works. (This PR is itself a test fix; the corrected assertions now pass.)
  • Ran gen-changesets skill, or this PR needs no changeset. (Test-only change; the underlying behavior already shipped in refactor: standardize telemetry property names #1184.)
  • Ran gen-docs skill, or this PR needs no doc update. (No user-facing behavior change.)

Update the turn_started/turn_ended and api_error telemetry assertions to
expect provider_type, matching the telemetry property rename in MoonshotAI#1184.
@changeset-bot

changeset-bot Bot commented Jun 29, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 1e49b8c

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jun 29, 2026

Copy link
Copy Markdown
pnpm dlx https://pkg.pr.new/@moonshot-ai/kimi-code@1e49b8c
npx https://pkg.pr.new/@moonshot-ai/kimi-code@1e49b8c

commit: 1e49b8c

@sailist sailist merged commit c8d1d76 into MoonshotAI:main Jun 29, 2026
10 checks passed
Moixia pushed a commit to Moixia/idea that referenced this pull request Jun 29, 2026
MoonshotAI#1194)

Update the turn_started/turn_ended and api_error telemetry assertions to
expect provider_type, matching the telemetry property rename in MoonshotAI#1184.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant