Convert tests to consistent structure
Use JUnit4 runner (from Espresso core jar), @Before annotation
for initial setup, @Test for all test methods. Move away from
the deprecated ActivityInstrumentationTestCase2 base class.
Bug: 27155526
Change-Id: I537fd4322c494597e80ecf8c9bd73b7f82fe8271
diff --git a/v7/gridlayout/build.gradle b/v7/gridlayout/build.gradle
index 6e363dd..7cae6c3 100644
--- a/v7/gridlayout/build.gradle
+++ b/v7/gridlayout/build.gradle
@@ -4,11 +4,23 @@
dependencies {
compile project(':support-v4')
+
+ androidTestCompile ('com.android.support.test:runner:0.4.1') {
+ exclude module: 'support-annotations'
+ }
+ androidTestCompile ('com.android.support.test.espresso:espresso-core:2.2.1') {
+ exclude module: 'support-annotations'
+ }
+ testCompile 'junit:junit:4.12'
}
android {
compileSdkVersion project.ext.currentSdk
+ defaultConfig {
+ testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
+ }
+
sourceSets {
main.manifest.srcFile 'AndroidManifest.xml'
main.java.srcDir 'src'