Skip to content

Instantly share code, notes, and snippets.

@NinoDLC
Created August 7, 2020 16:44
Show Gist options
  • Save NinoDLC/cf5513f147fac4c376a71731df9d5aba to your computer and use it in GitHub Desktop.
Save NinoDLC/cf5513f147fac4c376a71731df9d5aba to your computer and use it in GitHub Desktop.
apply plugin: 'com.android.application'
android {
compileSdkVersion 29
buildToolsVersion "29.0.2"
defaultConfig {
applicationId "fr.delcey.mareu"
minSdkVersion 21
targetSdkVersion 29
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
// The following argument makes the Android Test Orchestrator run its
// "pm clear" command after each test invocation. This command ensures
// that the app's state is completely cleared between tests.
testInstrumentationRunnerArguments clearPackageData: 'true'
}
testOptions {
// New android orchestrator allows us to clear data between each instrumentation test
execution 'ANDROIDX_TEST_ORCHESTRATOR'
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0'
implementation 'com.google.android.material:material:1.1.0-beta02'
// Room
def room_version = "2.2.3"
implementation "androidx.room:room-runtime:$room_version"
annotationProcessor "androidx.room:room-compiler:$room_version"
// Date
implementation 'com.jakewharton.threetenabp:threetenabp:1.2.1'
testImplementation 'junit:junit:4.12'
// Helps testing livedata : InstantTaskExecutorRule, for example
testImplementation "android.arch.core:core-testing:1.1.1"
// Helps mocking objects (Mockito.mock() or Mockito.spy())
testImplementation "org.mockito:mockito-core:2.28.2"
// Helps asserting (lists for example)
testImplementation 'org.hamcrest:hamcrest-library:1.3'
// Allow use of "PickerAction" for example : https://developer.android.com/reference/androidx/test/espresso/contrib/package-summary
androidTestImplementation 'androidx.test.espresso:espresso-contrib:3.2.0'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test:rules:1.2.0'
androidTestImplementation 'androidx.test:runner:1.2.0'
// Allow the line "testOptions { execution 'ANDROIDX_TEST_ORCHESTRATOR' }" to be considered
androidTestUtil 'androidx.test:orchestrator:1.2.0'
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment