3

当我尝试添加对 AndroidX Test JUnit 1.0.0-beta01: 的依赖项时androidTestImplementation androidx.test.ext:junit:1.0.0-beta01,Gradle Sync 失败并出现以下错误:

无法解决:org.junit:junit:4.12

手动添加 org.junit 依赖项的所有操作也无济于事。

4

2 回答 2

3

上述问题已在1.0.0-beta02中修复

'androidTestImplementation“androidx.test.ext:junit:1.0.0-beta02'

于 2018-10-12T00:59:57.757 回答
2

您可以手动排除“org.junit”组。

androidTestImplementation("androidx.test.ext:junit:1.0.0-beta01") {
    exclude group: "org.junit"
}
于 2018-10-10T03:38:47.257 回答