aspose file tools
The moose likes Testing and the fly likes Question on Powermockito Partial Mocking Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Barcodes with iOS this week in the iOS forum
or Core Java for the Impatient in the Java 8 forum!

JavaRanch » Java Forums » Engineering » Testing
Bookmark "Question on Powermockito Partial Mocking" Watch "Question on Powermockito Partial Mocking" New topic

Question on Powermockito Partial Mocking

Ronwaldo Cruz
Ranch Hand

Joined: Oct 17, 2006
Posts: 69

I'm trying to do partial mocking in PowerMockito v 1.2.5 with the following code:

I get the following error:

It seems to me like PowerMockito mocked the whole object and not just the method. When running methodA, nothing inside it gets executed hence the exception because methodB was never called.

Anybody has an idea? Thanks

I agree. Here's the link:
subject: Question on Powermockito Partial Mocking