mirror of
https://github.com/oxen-io/session-android.git
synced 2024-11-27 12:05:22 +00:00
Fix the connectedCheck build target
1) Create a new build type for testing. 2) Only obfuscate the package android.support.v7.internal.view.menu to prevent LGE ROM bug 3) '-keepattributes Exceptions' to allow for throwing from mocks 4) -dontskipnonpubliclibraryclassmembers and -dontwarn for everything else Fixes #2871 Closes #2986 // FREEBIE
This commit is contained in:
parent
f42d100f15
commit
a413346610
@ -127,6 +127,7 @@ dependencyVerification {
|
|||||||
android {
|
android {
|
||||||
compileSdkVersion 22
|
compileSdkVersion 22
|
||||||
buildToolsVersion '22.0.1'
|
buildToolsVersion '22.0.1'
|
||||||
|
testBuildType "testing"
|
||||||
|
|
||||||
dexOptions {
|
dexOptions {
|
||||||
javaMaxHeapSize "4g"
|
javaMaxHeapSize "4g"
|
||||||
@ -188,6 +189,10 @@ android {
|
|||||||
'proguard.cfg'
|
'proguard.cfg'
|
||||||
signingConfig signingConfigs.release
|
signingConfig signingConfigs.release
|
||||||
}
|
}
|
||||||
|
testing.initWith(buildTypes.debug)
|
||||||
|
testing {
|
||||||
|
proguardFile 'proguard-testing.pro'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sourceSets {
|
sourceSets {
|
||||||
|
@ -1,8 +1,9 @@
|
|||||||
|
# https://code.google.com/p/android/issues/detail?id=78377
|
||||||
|
-keepnames class !android.support.v7.internal.view.menu.**, ** { *; }
|
||||||
|
|
||||||
-keep public class android.support.v7.widget.** { *; }
|
-keep public class android.support.v7.widget.** { *; }
|
||||||
-keep public class android.support.v7.internal.widget.** { *; }
|
-keep public class android.support.v7.internal.widget.** { *; }
|
||||||
# below line disabled due to LGE ROM bug.
|
|
||||||
# -keep public class android.support.v7.internal.view.menu.** { *; }
|
|
||||||
|
|
||||||
-keep public class * extends android.support.v4.view.ActionProvider {
|
-keep public class * extends android.support.v4.view.ActionProvider {
|
||||||
public <init>(android.content.Context);
|
public <init>(android.content.Context);
|
||||||
}
|
}
|
||||||
|
10
proguard-testing.pro
Normal file
10
proguard-testing.pro
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
-keepattributes Exceptions
|
||||||
|
-dontskipnonpubliclibraryclassmembers
|
||||||
|
|
||||||
|
-dontwarn android.test.**
|
||||||
|
-dontwarn com.android.support.test.**
|
||||||
|
-dontwarn sun.reflect.**
|
||||||
|
-dontwarn org.assertj.**
|
||||||
|
-dontwarn org.hamcrest.**
|
||||||
|
-dontwarn org.mockito.**
|
||||||
|
-dontwarn com.squareup.**
|
Loading…
Reference in New Issue
Block a user