java.lang.IllegalStateException: no last call on a mock available

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via jayway.com by Unknown author, 1 year ago
via jayway.com by Unknown author, 1 year ago
via Stack Overflow by learningUser
, 3 months ago
no last call on a mock available at expect(classUnderTest.getfruits()).andReturn(orange);
via Stack Overflow by maverick
, 2 years ago
java.lang.IllegalStateException: no last call on a mock available
at org.easymock.EasyMock.getControlForLastCall(EasyMock.java:521)
at org.powermock.api.easymock.PowerMock.doExpectPrivate(PowerMock.java:2247)

Users with the same issue

Once, 9 months ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
2 times, 2 years ago
Samebug visitor profile picture
Unknown user
Once, 2 years ago

Write tip

Know the solutions? Share your knowledge to help other developers to debug faster.