Skip to content

Conversation

@GreyTeardrop
Copy link

SplitClientForTest can be useful for unit-testing code that depends on SplitClient, especially in dynamic scenarios where a static config per test class won't work. As of now, SplitClientForTest doesn't support customization of split keys or configs - it always returns the same treatment for all keys of a feature flag and always returns null as a split config.

This change extends SplitClientForTest, so it's possible to set treatments for each feature flag and key, and also possible to set split config in addition to the treatment name.

SplitClientForTest can be useful for unit-testing code that depends on
SplitClient, especially in dynamic scenarios where a static config per
test class won't work. As of now, SplitClientForTest doesn't support
customization of split keys or configs - it always returns the same
treatment for all keys of a feature flag and always returns null as a
split config.

This change extends SplitClientForTest, so it's possible to set
treatments for each feature flag and key, and also possible to set split
config in addition to the treatment name.
@GreyTeardrop GreyTeardrop requested a review from a team as a code owner August 29, 2025 12:03
@GreyTeardrop
Copy link
Author

@chillaq is this a change you might be interested in reviewing?

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