Commit a1c339ba authored by travis79's avatar travis79
Browse files

Remove duplicate WorkManager init from service-glean tests

parent 3d90f734
......@@ -9,7 +9,6 @@ import androidx.lifecycle.Lifecycle
import androidx.lifecycle.LifecycleOwner
import androidx.lifecycle.LifecycleRegistry
import androidx.test.core.app.ApplicationProvider
import androidx.work.testing.WorkManagerTestInitHelper
import kotlinx.coroutines.ExperimentalCoroutinesApi
import kotlinx.coroutines.ObsoleteCoroutinesApi
import kotlinx.coroutines.runBlocking
......@@ -62,9 +61,6 @@ class GleanTest {
@Before
fun setup() {
WorkManagerTestInitHelper.initializeTestWorkManager(
ApplicationProvider.getApplicationContext())
resetGlean()
}
......
......@@ -16,7 +16,6 @@ import org.junit.Before
import org.robolectric.Robolectric
import android.content.pm.ActivityInfo
import android.content.pm.ResolveInfo
import androidx.work.testing.WorkManagerTestInitHelper
import mozilla.components.service.glean.private.BooleanMetricType
import mozilla.components.service.glean.private.Lifetime
import mozilla.components.service.glean.resetGlean
......@@ -35,9 +34,6 @@ class GleanDebugActivityTest {
fun setup() {
resetGlean()
WorkManagerTestInitHelper.initializeTestWorkManager(
ApplicationProvider.getApplicationContext())
// This makes sure we have a "launch" intent in our package, otherwise
// it will fail looking for it in `GleanDebugActivityTest`.
val pm = ApplicationProvider.getApplicationContext<Context>().packageManager
......
......@@ -4,8 +4,6 @@
package mozilla.components.service.glean.storages
import android.os.SystemClock
import androidx.test.core.app.ApplicationProvider
import androidx.work.testing.WorkManagerTestInitHelper
import mozilla.components.service.glean.Glean
import mozilla.components.service.glean.checkPingSchema
import mozilla.components.service.glean.error.ErrorRecording.ErrorType
......@@ -55,9 +53,6 @@ class EventsStorageEngineTest {
resetGlean()
assert(Glean.initialized)
EventsStorageEngine.clearAllStores()
// Initialize WorkManager using the WorkManagerTestInitHelper.
WorkManagerTestInitHelper.initializeTestWorkManager(ApplicationProvider.getApplicationContext())
}
@Test
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment