Attempt to mockito mock any class generates ExceptionInInitializerError

前端 未结 7 1497
無奈伤痛
無奈伤痛 2020-12-16 09:26

When I run the following code:

public class ActivityTest extends ActivityInstrumentationTestCase2 {
    ....
    public void testCanCreat         


        
7条回答
  •  伪装坚强ぢ
    2020-12-16 10:10

    For me this eventually worked:

    androidTestCompile "org.mockito:mockito-core:1.10.19"
    androidTestCompile "com.crittercism.dexmaker:dexmaker:1.4"
    androidTestCompile "com.crittercism.dexmaker:dexmaker-mockito:1.4"
    androidTestCompile "com.crittercism.dexmaker:dexmaker-dx:1.4"
    

提交回复
热议问题