Add unit tests on AndroidBatteryOptimization
This commit is contained in:
parent
3d60bb81ee
commit
3a91c00a8c
3 changed files with 116 additions and 1 deletions
|
|
@ -14,4 +14,5 @@ android {
|
|||
|
||||
dependencies {
|
||||
api(projects.services.toolbox.api)
|
||||
implementation(projects.tests.testutils)
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,9 +9,10 @@ package io.element.android.services.toolbox.test.intent
|
|||
|
||||
import android.content.Intent
|
||||
import io.element.android.services.toolbox.api.intent.ExternalIntentLauncher
|
||||
import io.element.android.tests.testutils.lambda.lambdaError
|
||||
|
||||
class FakeExternalIntentLauncher(
|
||||
var launchLambda: (Intent) -> Unit = {},
|
||||
var launchLambda: (Intent) -> Unit = { lambdaError() },
|
||||
) : ExternalIntentLauncher {
|
||||
override fun launch(intent: Intent) {
|
||||
launchLambda(intent)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue