-
Notifications
You must be signed in to change notification settings - Fork 930
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
Enforce declaredMethods order when evaluating FFs #4193
Enforce declaredMethods order when evaluating FFs #4193
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
@aitorvs I'm stuck at verify the hash is different this time, and take note of it, I changed the hash for the jsonblob, but the hash on sharedPrefs wasn't updated. It was only after forcing config to be reloaded in developer settings that the hash was finally updated |
I had missed a test step, just added it and also expanded the verifications to double check something else. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good and works as expected!
Task/Issue URL: https://app.asana.com/0/488551667048375/1206628523510268/f ### Description See [task](https://app.asana.com/0/488551667048375/1206628523510268/f) for full context explanation ### Steps to test this PR _Test_ - [x] install from this branch and launch the app - [x] go to app settings -> developer settings -> override privacy remote config URL - [x] toggle "use custom URL" on and enter `https://jsonblob.com/api/jsonBlob/1126094951384629248` - [x] tap on force reloading - [x] Use AS (or Flipper) to see the contents of the share prefs `com.duckduckgo.feature.toggle.androidBrowserConfig` - [x] take note of the `hash` -- repeat 3 times -- - [x] force close the app and re-launch - [x] Use AS (or Flipper) to see the contents of the share prefs `com.duckduckgo.feature.toggle.androidBrowserConfig` - [x] verify the `hash` is the same -- END repeat 3 times -- - [x] take note of the sate (enabled/disabled) of the `androidBrowserConfig` sub-features - [x] Go to https://www.jsonblob.com/1126094951384629248 and modify the `hash` of `androidBrowserConfig` - [x] force close the app and re-launch - [x] verify the `hash` is the same - [x] Go to https://www.jsonblob.com/1126094951384629248 and increase the version - [x] force close the app and re-launch - [x] verify the `hash` is different this time, and take note of it - [x] verify the state of the sub-features has not change - [x] Apply the following patch and rebuild / re-install / re-launch the app ```kotlin Index: app/src/main/java/com/duckduckgo/app/pixels/remoteconfig/AndroidBrowserConfigFeature.kt IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== diff --git a/app/src/main/java/com/duckduckgo/app/pixels/remoteconfig/AndroidBrowserConfigFeature.kt b/app/src/main/java/com/duckduckgo/app/pixels/remoteconfig/AndroidBrowserConfigFeature.kt --- a/app/src/main/java/com/duckduckgo/app/pixels/remoteconfig/AndroidBrowserConfigFeature.kt (revision 5fe8bd5) +++ b/app/src/main/java/com/duckduckgo/app/pixels/remoteconfig/AndroidBrowserConfigFeature.kt (date 1707729280159) @@ -59,4 +59,7 @@ */ @Toggle.DefaultValue(false) fun optimizeTrackerEvaluation(): Toggle + + @Toggle.DefaultValue(false) + fun testFlag(): Toggle } ``` - [x] verify the `androidBrowserConfig_testFlag` is now present in the `com.duckduckgo.feature.toggle.androidBrowserConfig` and its `enable` value is most likely `true` (`rolloutThreshold` < `98`) - [x] verify the `hash` has changed
Task/Issue URL: https://app.asana.com/0/488551667048375/1206628523510268/f
Description
See task for full context explanation
Steps to test this PR
Test
https://jsonblob.com/api/jsonBlob/1126094951384629248
com.duckduckgo.feature.toggle.androidBrowserConfig
hash
-- repeat 3 times --
com.duckduckgo.feature.toggle.androidBrowserConfig
hash
is the same-- END repeat 3 times --
androidBrowserConfig
sub-featureshash
ofandroidBrowserConfig
hash
is the samehash
is different this time, and take note of itandroidBrowserConfig_testFlag
is now present in thecom.duckduckgo.feature.toggle.androidBrowserConfig
and itsenable
value is most likelytrue
(rolloutThreshold
<98
)hash
has changed