Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add test provider #971

Merged
merged 6 commits into from
Jul 29, 2024
Merged

feat: add test provider #971

merged 6 commits into from
Jul 29, 2024

Conversation

toddbaert
Copy link
Member

@toddbaert toddbaert commented Jul 26, 2024

Adds some testing utilities, specifically an <OpenFeatureTestProvider/> react context provider.

See README for details.

Signed-off-by: Todd Baert <[email protected]>
@toddbaert toddbaert requested a review from a team as a code owner July 26, 2024 16:55
Signed-off-by: Todd Baert <[email protected]>
Signed-off-by: Todd Baert <[email protected]>
@toddbaert
Copy link
Member Author

I recommend we merge #972 first.

Copy link
Member

@aepfli aepfli left a comment

Choose a reason for hiding this comment

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

lgtm...

... but as i am not so familiar with the react sdk, do we have a concept of domains also here? and if we do, how could i set it up with the testing provider? More out of curiosity, rather than we should tackle this wihtin this pr. i do think that this adds a lot of benefits to the users of the lib

@toddbaert
Copy link
Member Author

lgtm...

... but as i am not so familiar with the react sdk, do we have a concept of domains also here? and if we do, how could i set it up with the testing provider? More out of curiosity, rather than we should tackle this wihtin this pr. i do think that this adds a lot of benefits to the users of the lib

@aepfli

The test provider supports domains (it inherits all options from the normal provider, including domain and will use it if provided): https://github.com/open-feature/js-sdk/pull/971/files#diff-c52968f50e19cd6e828b0524065e8e707e81638dffb926ee051da87d0639502dR85

Signed-off-by: Todd Baert <[email protected]>
Signed-off-by: Todd Baert <[email protected]>
@toddbaert toddbaert added this pull request to the merge queue Jul 29, 2024
Merged via the queue into main with commit 1c12d4d Jul 29, 2024
8 checks passed
@toddbaert toddbaert deleted the feat/react-testing branch July 29, 2024 17:55
toddbaert pushed a commit that referenced this pull request Jul 29, 2024
🤖 I have created a release *beep* *boop*
---


##
[0.4.2](react-sdk-v0.4.1...react-sdk-v0.4.2)
(2024-07-29)


### ✨ New Features

* add test provider
([#971](#971))
([1c12d4d](1c12d4d))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Signed-off-by: OpenFeature Bot <[email protected]>
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.

3 participants