5
當我添加搖籃testCompile有沒有的Mockito找不到包
dependencies {
testCompile 'org.mockito:mockito-all:1.9.5'
}
我build.gradle
,JAR文件被下載,但編譯失敗與
error: package org.mockito does not exist
和一堆後續的錯誤。當我用compile
代替testCompile
時,它可以工作。我仍然是關於Gradle的初學者,但testCompile
聽起來恰到好處。此外,
testCompile 'junit:junit:4.+'
testCompile 'com.google.guava:guava-testlib:18.+'
工作得很好。有人可以解釋這裏發生了什麼嗎?
我笨!我的所有測試都在那裏,除了這個(我忘了移動)。 – maaartinus 2014-08-29 20:31:51
Omg。我一直在努力解決這個問題。創造了我的一天。謝謝 – 2018-01-30 22:12:13