@ -31,6 +31,7 @@ import mozilla.components.support.rusthttp.RustHttpConfig
import mozilla.components.support.rustlog.RustLog
import org.mozilla.fenix.components.Components
import org.mozilla.fenix.utils.Settings
import org.mozilla.fenix.GleanMetrics.ExperimentsMetrics
import java.io.File
@SuppressLint ( " Registered " )
@ -80,6 +81,16 @@ open class FenixApplication : Application() {
)
)
// When the `fenix-test-2019-08-05` experiment is active, record its branch in Glean
// telemetry. This will be used to validate that the experiment system correctly enrolls
// clients and segments them into branches. Note that this will not take effect the first
// time the application has launched, since there won't be enough time for the experiments
// library to get a list of experiments. It will take effect the second time the
// application is launched.
Experiments . withExperiment ( " fenix-test-2019-08-05 " ) { branchName ->
ExperimentsMetrics . activeExperiment . set ( branchName )
}
setupLeakCanary ( )
if ( Settings . getInstance ( this ) . isTelemetryEnabled ) {
components . analytics . metrics . start ( )