ソースを参照

fix robolectric

Daniel Zlotin 8 年 前
コミット
d33f963455
共有1 個のファイルを変更した7 個の追加7 個の削除を含む
  1. 7
    7
      android/prepare-robolectric.gradle

+ 7
- 7
android/prepare-robolectric.gradle ファイルの表示

1
-def robolectricDependenciesFolder = new File(gradle.gradleUserHomeDir, "/robolectric-dependencies-3.2.2")
1
+def robolectricDependenciesFolder = new File(rootProject.buildDir, "robolectric-3.2.2-dependencies")
2
 
2
 
3
 configurations.create('robolectricRuntime')
3
 configurations.create('robolectricRuntime')
4
 
4
 
8
 }
8
 }
9
 
9
 
10
 rootProject.task(type: Copy, overwrite: true, "downloadRobolectricDependencies") {
10
 rootProject.task(type: Copy, overwrite: true, "downloadRobolectricDependencies") {
11
-    println "downloadRobolectricDependencies " + robolectricDependenciesFolder
11
+    println "downloadRobolectricDependencies into " + robolectricDependenciesFolder
12
     from configurations.robolectricRuntime
12
     from configurations.robolectricRuntime
13
     into robolectricDependenciesFolder
13
     into robolectricDependenciesFolder
14
 }
14
 }
15
 
15
 
16
 project.afterEvaluate {
16
 project.afterEvaluate {
17
-  tasks.all {
18
-      if (it.name.startsWith("test")) {
19
-          it.dependsOn(rootProject.tasks.findByName("downloadRobolectricDependencies"))
20
-      }
21
-  }
17
+    tasks.all {
18
+        if (it.name.startsWith("test")) {
19
+            it.dependsOn(rootProject.tasks.findByName("downloadRobolectricDependencies"))
20
+        }
21
+    }
22
 }
22
 }
23
 
23
 
24
 android {
24
 android {