Give ability to configure the Firebase push gateway.
This commit is contained in:
parent
3ca624648b
commit
cf60f943a8
10 changed files with 70 additions and 11 deletions
|
|
@ -17,4 +17,6 @@ interface EnterpriseService {
|
|||
|
||||
fun semanticColorsLight(): SemanticColors
|
||||
fun semanticColorsDark(): SemanticColors
|
||||
|
||||
fun firebasePushGateway(): String?
|
||||
}
|
||||
|
|
|
|||
|
|
@ -27,4 +27,6 @@ class DefaultEnterpriseService @Inject constructor() : EnterpriseService {
|
|||
override fun semanticColorsLight(): SemanticColors = compoundColorsLight
|
||||
|
||||
override fun semanticColorsDark(): SemanticColors = compoundColorsDark
|
||||
|
||||
override fun firebasePushGateway(): String? = null
|
||||
}
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ class FakeEnterpriseService(
|
|||
private val defaultHomeserverResult: () -> String? = { A_FAKE_HOMESERVER },
|
||||
private val semanticColorsLightResult: () -> SemanticColors = { lambdaError() },
|
||||
private val semanticColorsDarkResult: () -> SemanticColors = { lambdaError() },
|
||||
private val firebasePushGatewayResult: () -> String? = { lambdaError() },
|
||||
) : EnterpriseService {
|
||||
override suspend fun isEnterpriseUser(sessionId: SessionId): Boolean = simulateLongTask {
|
||||
isEnterpriseUserResult(sessionId)
|
||||
|
|
@ -36,6 +37,10 @@ class FakeEnterpriseService(
|
|||
return semanticColorsDarkResult()
|
||||
}
|
||||
|
||||
override fun firebasePushGateway(): String? {
|
||||
return firebasePushGatewayResult()
|
||||
}
|
||||
|
||||
companion object {
|
||||
const val A_FAKE_HOMESERVER = "a_fake_homeserver"
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue