Skip to content

chore: Advertise user-type capability in contract tests - #446

Merged
keelerm84 merged 1 commit into
mainfrom
mk/SDK-3747/contract-tests-user-type
Nov 25, 2026
Merged

keelerm84 merged 1 commit into
mainfrom
mk/SDK-3747/contract-tests-user-type

Conversation

@keelerm84

@keelerm84 keelerm84 commented Nov 24, 2026 •

Copy link
Copy Markdown
Member

Related issues

SDK-3747. Related harness PRs: launchdarkly/sdk-test-harness#699 and launchdarkly/sdk-test-harness#700.

Describe the solution you've provided

The contract-test service now advertises user-type. It accepts old-style users in clientSide.initialUser and identifyEvent.user, and parses them with LDContext's Gson adapter. Without user-type, the harness skips all of its old-user tests on Android.

This is a draft to find out which of those tests pass. I expect failures where a legacy user's custom.kind becomes the context kind (SDK-3747). Any failures will either go into the suppression files or be fixed in java-core.


Note

Overview
Enables the Android contract-test service to participate in harness legacy user scenarios by advertising the user-type capability and wiring alternate JSON fields alongside existing context fields.

SdkConfigClientSideParams gains initialUser, and IdentifyEventParams gains user. Client creation and identify commands now prefer initialContext / context, falling back to the new user fields when absent—legacy user JSON (no kind) is expected to deserialize through LDContext’s Gson adapters.

Without user-type in capabilities, the harness skips old-user tests on Android; this change unblocks those runs (known edge cases around legacy custom.kind may still fail per SDK-3747).

Reviewed by Cursor Bugbot for commit 647842e. Bugbot is set up for automated code reviews on this repo. Configure here.

Accept old-style users in the client-side initialUser and identify event
params, so the harness runs its old user tests against Android. LDContext's
Gson adapter already converts old user JSON.

SDK-3747
@keelerm84
keelerm84 marked this pull request as ready for review November 25, 2026 13:45
@keelerm84
keelerm84 requested a review from a team as a code owner November 25, 2026 13:45

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Risk: low. Approved. Cursor Bugbot completed with no findings, and SDK approval rules 1–3 are satisfied (not a release PR, allowed author keelerm84, no workflow file changes).

Open in Web View Automation 

Sent by Cursor Approval Agent: SDK - Pull Request Router and Approver

@keelerm84
keelerm84 merged commit 8666a51 into main Nov 25, 2026
9 checks passed
@keelerm84
keelerm84 deleted the mk/SDK-3747/contract-tests-user-type branch November 25, 2026 13:49
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