Skip to content
Snippets Groups Projects
Unverified Commit 0166b3bb authored by Ralf Gehrer's avatar Ralf Gehrer Committed by GitHub
Browse files

Change default environment to WRU (EXPOSUREAPP-7213) (#3146)


* Change default environment to WRU (EXPOSUREAPP-7213)

* fix test

* Improve default server env test.

Co-authored-by: default avatarMatthias Urhahn <matthias.urhahn@sap.com>
Co-authored-by: default avatarMohamed <mohamed.metwalli@sap.com>
parent 1348fec5
No related branches found
No related tags found
No related merge requests found
......@@ -127,7 +127,7 @@ android {
applicationIdSuffix '.test'
ext {
envTypeDefault = [debug: "INT", release: "WRU-XD"]
envTypeDefault = [debug: "INT", release: "WRU"]
}
if (signingPropFile.canRead()) {
......
package de.rki.coronawarnapp.environment
import io.kotest.matchers.collections.shouldBeIn
import de.rki.coronawarnapp.BuildConfig
import io.kotest.matchers.shouldBe
import org.junit.jupiter.api.Test
import testhelpers.BaseTest
class BuildConfigWrapTest : BaseTest() {
@Test
fun `default environment type should be DEV`() {
BuildConfigWrap.ENVIRONMENT_TYPE_DEFAULT shouldBeIn listOf("DEV", "INT", "WRU-XD", "PROD")
fun `default environment type `() {
if (BuildConfig.FLAVOR == "deviceForTesters" && BuildConfig.BUILD_TYPE == "debug") {
BuildConfigWrap.ENVIRONMENT_TYPE_DEFAULT shouldBe "INT"
} else if (BuildConfig.FLAVOR == "deviceForTesters" && BuildConfig.BUILD_TYPE == "release") {
BuildConfigWrap.ENVIRONMENT_TYPE_DEFAULT shouldBe "WRU"
} else if (BuildConfig.FLAVOR == "device" && BuildConfig.BUILD_TYPE == "debug") {
BuildConfigWrap.ENVIRONMENT_TYPE_DEFAULT shouldBe "INT"
} else if (BuildConfig.FLAVOR == "device" && BuildConfig.BUILD_TYPE == "release") {
BuildConfigWrap.ENVIRONMENT_TYPE_DEFAULT shouldBe "PROD"
} else {
throw IllegalStateException("Unknown flavor/build combination.")
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment