In order for mocking to even work on emulators, we need to incorporate the
[Dexmaker](https://github.com/crittercism/dexmaker), a bytecode manipulation
library for the Dalvik VM.
However, the compiler is complaining that
Error:Gradle: Execution failed for task ':app:packageDebugTest'.
Looking into the jar structure, I noticed that both Dexmaker and Powermock
declare a MockMaker in mockito-extensions
What is a MockMaker? How do they differ?
And the most important question: Is it possible to get Powermock to work nicely
with Dexmaker?
Thanks in advance. Any help would be greatly appreciated.
Original issue reported on code.google.com by `littledo...@gmail.com` on 14 Jan 2015 at 9:48
Attachments:
* [Screen Shot 2015-01-14 at 1.36.27 PM.png](https://storage.googleapis.com/google-code-attachments/powermock/issue-536/comment-0/Screen Shot 2015-01-14 at 1.36.27 PM.png)
dependencies{ compile 'com.android.support:appcompat-v7:21.0.+' androidTestCompile('org.mockito:mockito-core:1.9.5') androidTestCompile('com.google.dexmaker:dexmaker:1.2') androidTestCompile('com.google.dexmaker:dexmaker-mockito:1.2') androidTestCompile('org.powermock:powermock-module-junit4:1.5.5') { exclude module: 'junit' } androidTestCompile('org.powermock:powermock-api-mockito:1.5.5') { exclude module: 'mockito-all' } }
Error:Gradle: Execution failed for task ':app:packageDebugTest'.
Looking into the jar structure, I noticed that both Dexmaker and Powermock declare a
MockMaker
inmockito-extensions
What is a MockMaker? How do they differ? And the most important question: Is it possible to get Powermock to work nicely with Dexmaker?
Thanks in advance. Any help would be greatly appreciated.