Using PowerMock and Mockito in an Android Instrumentation test - Error - Duplicate files - org.mockito.plugins.MockMaker

后端 未结 3 2238
不知归路
不知归路 2021-02-20 11:29

I”m trying to use PowerMock to mock a class with a static method, but specifically I wish to do this within an Android Instrumentation test. To be clear I wish to run the test o

3条回答
  •  无人及你
    2021-02-20 12:03

    The only correct answer is PowerMockito does not support the Davik VM Android uses, it is meant for a standard JVM. So you can't use it with instrumented tests, only unit tests.

提交回复
热议问题