Skip to content

Commit ea35506

Browse files
chore: update sdk readmes (#578)
Signed-off-by: OpenFeature Bot <[email protected]>
1 parent 7a1a0d6 commit ea35506

File tree

12 files changed

+42
-15
lines changed

12 files changed

+42
-15
lines changed

docs/reference/technologies/client/kotlin.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from kotlin-sdk.
1010
Edits should be made here: https://github.com/open-feature/kotlin-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/client/swift.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from swift-sdk.
1010
Edits should be made here: https://github.com/open-feature/swift-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/client/web/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from js-sdk.
1010
Edits should be made here: https://github.com/open-feature/js-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/client/web/react.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from js-sdk.
1010
Edits should be made here: https://github.com/open-feature/js-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/server/dotnet.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from dotnet-sdk.
1010
Edits should be made here: https://github.com/open-feature/dotnet-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
[![Specification](https://img.shields.io/static/v1?label=specification&message=v0.7.0&color=yellow&style=for-the-badge)](https://github.com/open-feature/spec/releases/tag/v0.7.0)

docs/reference/technologies/server/go.mdx

Lines changed: 30 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,16 @@ This content has been automatically generated from go-sdk.
99
Edits should be made here: https://github.com/open-feature/go-sdk
1010
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1111

12-
Last updated at Wed May 29 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
12+
Last updated at Thu May 30 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
1313
-->
1414

1515
<p align="center" class="github-badges">
1616
<a href="https://github.com/open-feature/spec/releases/tag/v0.7.0">
1717
<img alt="Specification" src="https://img.shields.io/static/v1?label=specification&message=v0.7.0&color=yellow&style=for-the-badge" />
1818
</a>
1919

20-
<a href="https://github.com/open-feature/go-sdk/releases/tag/v1.11.0">
21-
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.11.0&color=blue&style=for-the-badge" />
20+
<a href="https://github.com/open-feature/go-sdk/releases/tag/v1.12.0">
21+
<img alt="Release" src="https://img.shields.io/static/v1?label=release&message=v1.12.0&color=blue&style=for-the-badge" />
2222
</a>
2323

2424
<br/>
@@ -359,3 +359,30 @@ func (h MyHook) Error(context context.Context, hookContext openfeature.HookConte
359359

360360
> Built a new hook? [Let us know](https://github.com/open-feature/openfeature.dev/issues/new?assignees=&labels=hook&projects=&template=document-hook.yaml&title=%5BHook%5D%3A+) so we can add it to the docs!
361361
362+
## Testing
363+
364+
To test interactions with OpenFeature API and Client, you can rely on `openfeature.IEvaluation` & `openfeature.IClient` interfaces.
365+
366+
While you may use global methods to interact with the API, it is recommended to obtain the singleton API instance so that you can use appropriate mocks for your testing needs,
367+
368+
```go
369+
// global helper
370+
openfeature.SetProvider(myProvider)
371+
372+
// singleton instance - preferred
373+
apiInstance := openfeature.GetApiInstance()
374+
apiInstance.SetProvider(myProvider)
375+
```
376+
377+
Similarly, while you have option (due to historical reasons) to create a client with `openfeature.NewClient()` helper, it is recommended to use API to generate the client which returns an `IClient` instance.
378+
379+
```go
380+
// global helper
381+
openfeature.NewClient("myClient")
382+
383+
// using API instance - preferred
384+
apiInstance := openfeature.GetApiInstance()
385+
apiInstance.GetClient()
386+
apiInstance.GetNamedClient("myClient")
387+
```
388+

docs/reference/technologies/server/java.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This content has been automatically generated from java-sdk.
99
Edits should be made here: https://github.com/open-feature/java-sdk
1010
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1111

12-
Last updated at Wed May 29 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
12+
Last updated at Thu May 30 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
1313
-->
1414

1515
<p align="center" class="github-badges">

docs/reference/technologies/server/javascript/index.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from js-sdk.
1010
Edits should be made here: https://github.com/open-feature/js-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/server/javascript/nestjs.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ This content has been automatically generated from js-sdk.
1010
Edits should be made here: https://github.com/open-feature/js-sdk
1111
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1212

13-
Last updated at Wed May 29 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
13+
Last updated at Thu May 30 2024 08:08:25 GMT+0000 (Coordinated Universal Time)
1414
-->
1515

1616
<p align="center" class="github-badges">

docs/reference/technologies/server/php.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This content has been automatically generated from php-sdk.
99
Edits should be made here: https://github.com/open-feature/php-sdk
1010
Once a repo has been updated, docs can be generated by running: yarn update:sdk-docs
1111

12-
Last updated at Wed May 29 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
12+
Last updated at Thu May 30 2024 08:08:26 GMT+0000 (Coordinated Universal Time)
1313
-->
1414

1515
<p align="center" class="github-badges">

0 commit comments

Comments
 (0)