New: Added QA build type.

This allows the app to run alongside the play store version for internal testing within the wallet team. This proved to be super useful so we formalized it into its own build with a separate icon and app name.
This commit is contained in:
Kevin Gorham 2020-10-07 20:19:19 -04:00
parent a693caf499
commit 7e193812e3
No known key found for this signature in database
GPG Key ID: CCA55602DF49FC38
20 changed files with 74 additions and 19 deletions

View File

@ -9,7 +9,7 @@ apply plugin: 'com.google.gms.google-services'
archivesBaseName = 'zcash-android-wallet'
group = 'cash.z.ecc.android'
version = '1.0.0-alpha34'
version = Deps.versionName
android {
ndkVersion "21.1.6352462"
@ -17,16 +17,16 @@ android {
buildToolsVersion Deps.buildToolsVersion
viewBinding.enabled = true
defaultConfig {
applicationId 'cash.z.ecc.android'
applicationId Deps.packageName
minSdkVersion Deps.minSdkVersion
targetSdkVersion Deps.targetSdkVersion
versionCode = 1_00_00_034
// last digits are alpha(0XX) beta(2XX) rc(4XX) release(8XX) dev(9XX). Ex: 1_08_04_401 is an release candidate build of version 1.8.4 and 1_08_04_800 would be the final release.
versionName = "$version"
versionCode = Deps.versionCode
versionName = Deps.versionName
testInstrumentationRunner 'androidx.test.runner.AndroidJUnitRunner'
testInstrumentationRunnerArguments clearPackageData: 'true'
multiDexEnabled true
resValue 'string', 'bugsnag_api_key', "${(project.findProperty('BUGSNAG_API_KEY') ?: System.getenv('BUGSNAG_API_KEY')) ?: ''}"
resValue 'string', 'file_authority', "${Deps.packageName}.fileprovider"
// this setting allows using color resources in vector drawables, rather than hardcoded values (note: only works when minApi is 21)
// per https://google.github.io/android-gradle-dsl/current/com.android.build.gradle.internal.dsl.VectorDrawablesOptions.html: If set to an empty collection, all special handling of vector drawables will be disabled.
@ -68,10 +68,15 @@ android {
useProguard false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
// mock {
// initWith debug
// matchingFallbacks = ['debug', 'release', 'zcashtestnet']
// }
// builds for testing only in the wallet team, typically unfinished features
// this flavor can be installed alongside the others
qa {
initWith debug
debuggable false
applicationIdSuffix ".internal"
resValue 'string', 'file_authority', "${Deps.packageName}.internal.fileprovider"
matchingFallbacks = ['debug']
}
}
compileOptions {
@ -80,6 +85,9 @@ android {
}
kotlinOptions {
jvmTarget = "1.8"
freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.ExperimentalCoroutinesApi"
// freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.ObsoleteCoroutinesApi"
// freeCompilerArgs += "-Xopt-in=kotlinx.coroutines.FlowPreview"
}
kapt {
arguments {
@ -94,7 +102,10 @@ android {
}
applicationVariants.all { variant ->
variant.outputs.all {
outputFileName = "$archivesBaseName-v${defaultConfig.versionName}-${variant.buildType.name}.apk"
if (variant.buildType.name == "qa") {
it.versionNameOverride = "${Deps.versionName}-QA"
}
outputFileName = "$archivesBaseName-v${Deps.versionName}-${variant.buildType.name}.apk"
}
}
}
@ -165,8 +176,12 @@ dependencies {
testImplementation Deps.Test.COROUTINES_TEST
testImplementation Deps.Test.JUNIT
testImplementation Deps.Test.MOKITO
testImplementation Deps.Test.MOKITO_KOTLIN
testImplementation Deps.Test.COROUTINES_TEST
testImplementation Deps.Zcash.Sdk.TESTNET
androidTestImplementation Deps.Test.Android.JUNIT
androidTestImplementation Deps.Test.Android.ESPRESSO
}
defaultTasks 'clean', 'installZcashmainnetRelease'
defaultTasks 'clean', 'assembleZcashmainnetRelease'

View File

@ -63,6 +63,35 @@
]
}
}
},
{
"client_info": {
"mobilesdk_app_id": "1:000000000000:android:8888888888888888888888",
"android_client_info": {
"package_name": "cash.z.ecc.android.internal"
}
},
"oauth_client": [
{
"client_id": "dummy.apps.googleusercontent.com",
"client_type": 3
}
],
"api_key": [
{
"current_key": "dummy"
}
],
"services": {
"appinvite_service": {
"other_platform_oauth_client": [
{
"client_id": "dummy.apps.googleusercontent.com",
"client_type": 3
}
]
}
}
}
],
"configuration_version": "1"

View File

@ -22,7 +22,7 @@
<provider
android:name="androidx.core.content.FileProvider"
android:authorities="cash.z.ecc.android.fileprovider"
android:authorities="@string/file_authority"
android:exported="false"
android:grantUriPermissions="true"
android:writePermission="true">

View File

@ -15,8 +15,8 @@
android:centerX="54"
android:centerY="36.01165"
android:type="radial">
<item android:offset="0" android:color="#FF3F3F4F"/>
<item android:offset="1" android:color="#FF000000"/>
<item android:offset="0" android:color="@color/app_icon_background_0"/>
<item android:offset="1" android:color="@color/app_icon_background_1"/>
</gradient>
</aapt:attr>
</path>

View File

@ -45,7 +45,7 @@
<path
android:pathData="M77.8,53.601C77.8,53.79 77.799,53.963 77.799,53.963L46.564,53.967C46.755,57.942 50.012,61.117 53.999,61.117C56.367,61.117 58.475,59.995 59.842,58.255L60.739,58.255C59.264,60.419 56.794,61.843 53.999,61.843C49.752,61.843 46.262,58.557 45.872,54.375L45.862,54.261C45.855,54.164 45.855,54.065 45.851,53.966L39.9,53.967C39.769,54.519 39.351,54.953 38.814,55.109C39.569,62.892 46.087,68.996 54,68.996C60.81,68.996 66.592,64.475 68.553,58.254L69.305,58.254C67.32,64.881 61.211,69.721 54,69.721C45.704,69.721 38.873,63.313 38.097,55.149C37.49,55.035 37.009,54.569 36.866,53.967L32.082,53.968C31.949,54.527 31.522,54.965 30.974,55.116C31.752,67.246 41.779,76.875 54,76.875C65.147,76.875 74.471,68.865 76.615,58.254L77.346,58.254C75.19,69.267 65.545,77.6 54,77.6C41.392,77.6 31.048,67.661 30.254,55.146C29.538,55.001 29,54.364 29,53.6C29,52.836 29.539,52.199 30.254,52.054C31.048,39.539 41.391,29.6 54,29.6C67.003,29.601 77.597,40.172 77.791,53.239C77.793,53.36 77.8,53.48 77.8,53.601ZM77.072,53.239C76.878,40.572 66.606,30.327 53.999,30.327C41.778,30.327 31.75,39.957 30.973,52.085C31.522,52.236 31.95,52.677 32.082,53.239L36.863,53.239C37.005,52.635 37.487,52.167 38.095,52.053C38.871,43.888 45.702,37.48 53.999,37.48C61.069,37.48 67.078,42.134 69.182,48.561L68.422,48.561C66.347,42.541 60.667,38.206 53.999,38.206C46.086,38.206 39.568,44.31 38.813,52.092C39.351,52.25 39.77,52.685 39.9,53.239L45.845,53.239C45.852,53.091 45.86,52.961 45.86,52.961C46.186,48.716 49.706,45.36 53.999,45.36C56.623,45.36 58.955,46.617 60.451,48.561L59.513,48.561C58.148,47.045 56.185,46.085 53.999,46.085C50.01,46.085 46.752,49.263 46.562,53.239L46.562,53.239L77.072,53.239Z"
android:strokeWidth="1"
android:fillColor="#FFB900"
android:fillColor="@color/app_icon_foreground"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
<path
@ -90,13 +90,13 @@
<path
android:pathData="M77.8,53.601C77.8,53.79 77.799,53.963 77.799,53.963L46.564,53.967C46.755,57.942 50.012,61.117 53.999,61.117C56.367,61.117 58.475,59.995 59.842,58.255L60.739,58.255C59.264,60.419 56.794,61.843 53.999,61.843C49.752,61.843 46.262,58.557 45.872,54.375L45.862,54.261C45.855,54.164 45.855,54.065 45.851,53.966L39.9,53.967C39.769,54.519 39.351,54.953 38.814,55.109C39.569,62.892 46.087,68.996 54,68.996C60.81,68.996 66.592,64.475 68.553,58.254L69.305,58.254C67.32,64.881 61.211,69.721 54,69.721C45.704,69.721 38.873,63.313 38.097,55.149C37.49,55.035 37.009,54.569 36.866,53.967L32.082,53.968C31.949,54.527 31.522,54.965 30.974,55.116C31.752,67.246 41.779,76.875 54,76.875C65.147,76.875 74.471,68.865 76.615,58.254L77.346,58.254C75.19,69.267 65.545,77.6 54,77.6C41.392,77.6 31.048,67.661 30.254,55.146C29.538,55.001 29,54.364 29,53.6C29,52.836 29.539,52.199 30.254,52.054C31.048,39.539 41.391,29.6 54,29.6C67.003,29.601 77.597,40.172 77.791,53.239C77.793,53.36 77.8,53.48 77.8,53.601ZM77.072,53.239C76.878,40.572 66.606,30.327 53.999,30.327C41.778,30.327 31.75,39.957 30.973,52.085C31.522,52.236 31.95,52.677 32.082,53.239L36.863,53.239C37.005,52.635 37.487,52.167 38.095,52.053C38.871,43.888 45.702,37.48 53.999,37.48C61.069,37.48 67.078,42.134 69.182,48.561L68.422,48.561C66.347,42.541 60.667,38.206 53.999,38.206C46.086,38.206 39.568,44.31 38.813,52.092C39.351,52.25 39.77,52.685 39.9,53.239L45.845,53.239C45.852,53.091 45.86,52.961 45.86,52.961C46.186,48.716 49.706,45.36 53.999,45.36C56.623,45.36 58.955,46.617 60.451,48.561L59.513,48.561C58.148,47.045 56.185,46.085 53.999,46.085C50.01,46.085 46.752,49.263 46.562,53.239L46.562,53.239L77.072,53.239Z"
android:strokeWidth="1"
android:fillColor="#FFB900"
android:fillColor="@color/app_icon_foreground"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
<path
android:pathData="M77.8,53.601C77.8,53.79 77.799,53.963 77.799,53.963L46.564,53.967C46.755,57.942 50.012,61.117 53.999,61.117C56.367,61.117 58.475,59.995 59.842,58.255L60.739,58.255C59.264,60.419 56.794,61.843 53.999,61.843C49.752,61.843 46.262,58.557 45.872,54.375L45.862,54.261C45.855,54.164 45.855,54.065 45.851,53.966L39.9,53.967C39.769,54.519 39.351,54.953 38.814,55.109C39.569,62.892 46.087,68.996 54,68.996C60.81,68.996 66.592,64.475 68.553,58.254L69.305,58.254C67.32,64.881 61.211,69.721 54,69.721C45.704,69.721 38.873,63.313 38.097,55.149C37.49,55.035 37.009,54.569 36.866,53.967L32.082,53.968C31.949,54.527 31.522,54.965 30.974,55.116C31.752,67.246 41.779,76.875 54,76.875C65.147,76.875 74.471,68.865 76.615,58.254L77.346,58.254C75.19,69.267 65.545,77.6 54,77.6C41.392,77.6 31.048,67.661 30.254,55.146C29.538,55.001 29,54.364 29,53.6C29,52.836 29.539,52.199 30.254,52.054C31.048,39.539 41.391,29.6 54,29.6C67.003,29.601 77.597,40.172 77.791,53.239C77.793,53.36 77.8,53.48 77.8,53.601ZM77.072,53.239C76.878,40.572 66.606,30.327 53.999,30.327C41.778,30.327 31.75,39.957 30.973,52.085C31.522,52.236 31.95,52.677 32.082,53.239L36.863,53.239C37.005,52.635 37.487,52.167 38.095,52.053C38.871,43.888 45.702,37.48 53.999,37.48C61.069,37.48 67.078,42.134 69.182,48.561L68.422,48.561C66.347,42.541 60.667,38.206 53.999,38.206C46.086,38.206 39.568,44.31 38.813,52.092C39.351,52.25 39.77,52.685 39.9,53.239L45.845,53.239C45.852,53.091 45.86,52.961 45.86,52.961C46.186,48.716 49.706,45.36 53.999,45.36C56.623,45.36 58.955,46.617 60.451,48.561L59.513,48.561C58.148,47.045 56.185,46.085 53.999,46.085C50.01,46.085 46.752,49.263 46.562,53.239L46.562,53.239L77.072,53.239Z"
android:strokeWidth="1"
android:fillColor="#FFB900"
android:fillColor="@color/app_icon_foreground"
android:fillType="nonZero"
android:strokeColor="#00000000"/>
</vector>

View File

@ -57,6 +57,9 @@
<!-- every color here should be a reference to a palette color
but have a more useful name for use in code -->
<color name="app_icon_background_0">#FF3F3F4F</color>
<color name="app_icon_background_1">#FF000000</color>
<color name="app_icon_foreground">#FFB900</color>
<color name="background_banner">@color/zcashBlack_dark</color>
<color name="background_banner_stroke">#282828</color>
<color name="scan_overlay_background">@color/zcashBlack_87</color>

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

View File

@ -0,0 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<color name="app_icon_background_0">#FFB900</color>
<color name="app_icon_background_1">#664B00</color>
<color name="app_icon_foreground">#FF000000</color>
</resources>

View File

@ -0,0 +1,3 @@
<resources xmlns:tools="http://schemas.android.com/tools">
<string name="app_name" tools:ignore="MissingTranslation">ECC (QA)</string>
</resources>

View File

@ -19,7 +19,7 @@ buildscript {
allprojects {
repositories {
mavenLocal()
// mavenLocal()
google()
jcenter()
maven { url 'https://jitpack.io' }

View File

@ -1,3 +1,2 @@
<resources>
<string name="app_name">QRecycler</string>
</resources>