小编ind*_*ars的帖子

Roboelectric 3.0测试片段

我是Roboelectric测试的新手.我试图按照这篇 文章来测试片段.我使用以下作为依赖

dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
testCompile "org.robolectric:robolectric:3.0"
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:22.2.0'
compile 'com.google.code.gson:gson:2.3'
compile 'com.android.support:support-v4:22.1.0'
compile 'com.google.android.gms:play-services:7.5.0'
Run Code Online (Sandbox Code Playgroud)

}

但是这个导入给了我编译问题,我无法解决符号SupportFragmentTestUtil的问题.请指导我,我错过了什么?

org.robolectric.shadows.support.v4.SupportFragmentTestUtil
Run Code Online (Sandbox Code Playgroud)

android robolectric android-testing

6
推荐指数
1
解决办法
3717
查看次数

标签 统计

android ×1

android-testing ×1

robolectric ×1