Skip to content

test: run the OVERRIDE spec test vectors against the full client stack#411

Draft
kinyoklion wants to merge 2 commits into
rlamb/sdk-2655/client-override-wiringfrom
rlamb/sdk-2655/override-spec-vectors
Draft

test: run the OVERRIDE spec test vectors against the full client stack#411
kinyoklion wants to merge 2 commits into
rlamb/sdk-2655/client-override-wiringfrom
rlamb/sdk-2655/override-spec-vectors

Conversation

@kinyoklion

Copy link
Copy Markdown
Member

Adds a runner for the eight test vectors published with the OVERRIDE spec, vendored verbatim under testdata/override-vectors/ with a schema-version assertion so drift in the source vectors fails loudly rather than silently changing coverage.

Each vector exercises the full production stack — client gate, overlay store, evaluator, and events input — rather than a reimplementation: LaunchDarkly data is supplied by a test initializer as a full-transfer basis with a defined selector; the initialized: false vectors use a synchronizer that never delivers data (with no sources configured at all, the client would consider cached data available instead of applying its not-initialized handling, so an idle synchronizer is load-bearing); overrides come from the programmatic test source. Assertions follow the vectors' comparison rules: values by JSON equality, a null variation index as undefined, reasons compared only on the fields each vector specifies with the tri-state isOverride collapse, and the per-evaluation summary contribution checked against the captured event input.

All eight vectors (precedence, uninitialized, passthrough ×2, full-evaluation, merged-view, marking, error-handling) pass.

Based on #410.

SDK-2655

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