-
Notifications
You must be signed in to change notification settings - Fork 56
TestData/ FlagData not working as documented #235
Comments
TestData and FileData are completely different things, so this is really two issues. In the case of the TestData issue, the problem is that you're not using it as documented: calling td.flag("my-boolean-flag-key").booleanFlag().variationForAllUsers(true); —you need to do this (as shown in the code samples in the documentation): td.update(testData.flag("my-boolean-flag-key").booleanFlag().variationForAllUsers(true)); |
Yes My bad! You are right and this Any idea on why FlagData is not working or how to check if it is correctly setup? Since ideally I would like to use FlagData for testing |
Yes, hold on, I'm working on that (assuming you mean FileData) |
As for FileData, I believe the problem there is a counter-intuitive thing about the configuration, which the documentation does not describe correctly. The name Unfortunately, the documentation for FileData gets this wrong and says that you can use |
So I've made a note to fix that part of the docs— sorry about that. |
ok that worked Thank you! |
Is this a support request?
No
Describe the bug
Using server-side SDK for JAVA, for Integration testing, I am trying to create LDClient such that it doesnt communicate with LaunchDarkly and access from file. As suggested here
/test/resources/FileData.json
LDConfig using FlagData
LDConfig using TestData
In both cases LDClient is Initialized however the flag provided in file is not found
Following should pass -
How do I check if file provided is correctly setup for data source? Any help in this setup is highly appreciated as its blocking Integration testing.
Expected behavior
Data source should get setup correctly
SDK version
5.3.0
Language version, developer tools
Java
The text was updated successfully, but these errors were encountered: