0
0
mirror of https://github.com/ankidroid/Anki-Android.git synced 2024-09-20 12:02:16 +02:00
Anki-Android/AnkiDroid/build.gradle
Mike Hardy 2434d3e346 Upgrade test dependencies and migrate tests to new APIs
- Junit 4 -> Junit 5 using Vintage Engine
    - Mockito -> 1.10.x -> 2.18.x
    - Powermock 1.6.x -> Powermock 2.0.x
2018-06-14 08:15:42 +09:00

75 lines
2.7 KiB
Groovy

apply plugin: 'com.android.application'
apply plugin: 'com.github.triplet.play'
def homePath = System.properties['user.home']
android {
compileSdkVersion 26
defaultConfig {
applicationId "com.ichi2.anki"
minSdkVersion 15
targetSdkVersion 25
testApplicationId "com.ichi2.anki.tests"
vectorDrawables.useSupportLibrary = true
}
lintOptions {
abortOnError false
disable 'TypographyEllipsis'
}
signingConfigs {
release {
storeFile file("${homePath}/src/android-keystore")
keyAlias "nrkeystorealias"
storePassword System.getenv("KSTOREPWD")
keyPassword System.getenv("KEYPWD")
}
}
buildTypes {
release {
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
signingConfig signingConfigs.release
}
}
useLibrary 'org.apache.http.legacy'
dexOptions {
// Skip pre-dexing when running on Travis CI or when disabled via -Dpre-dex=false.
preDexLibraries = preDexEnabled && !travisBuild
}
}
play {
serviceAccountEmail = '294046724212-r3bef6kl46pb9gk0h1pl5rcjmpfrdpjl@developer.gserviceaccount.com'
pk12File = file("${homePath}/src/583631bdd16d.p12")
track = 'alpha'
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:26.1.0'
// Note: the design support library can be quite buggy, so test everything thoroughly before updating it
implementation 'com.android.support:design:26.1.0'
implementation 'com.android.support:customtabs:26.1.0'
implementation 'com.android.support:recyclerview-v7:26.1.0'
implementation 'io.requery:sqlite-android:3.16.0'
implementation('com.afollestad.material-dialogs:core:0.8.6.2@aar') {
//exclude group: 'com.android.support' // uncomment to force our local support lib version
transitive = true
}
implementation 'com.getbase:floatingactionbutton:1.10.1'
implementation 'ch.acra:acra:4.6.2'
implementation 'com.jakewharton.timber:timber:2.7.1'
implementation 'com.google.code.gson:gson:2.8.2'
implementation 'org.jsoup:jsoup:1.10.3'
api project(":api")
testImplementation 'org.junit.vintage:junit-vintage-engine:5.2.0'
testImplementation 'org.mockito:mockito-core:2.18.3'
testImplementation 'org.powermock:powermock-core:2.0.0-beta.5'
testImplementation 'org.powermock:powermock-module-junit4:2.0.0-beta.5'
testImplementation 'org.powermock:powermock-api-mockito2:2.0.0-beta.5'
testImplementation 'org.hamcrest:hamcrest-all:1.3'
}