mockit.internal.MissingInvocation: Missing invocation of: com.egoo.dao.repository.freelink.AgentInfoRepository#getAllAgents() on mock instance: com.egoo.dao.repository.freelink.$Impl_AgentInfoRepository@50a7bc6e at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:117)

Stack Overflow | BigSam | 10 months ago
tip
Click on the to mark the solution that helps you, Samebug will learn from it.
As a community member, you’ll be rewarded for you help.
  1. 0

    Use JMockit test the RESTful API,RestTemplate,error missing invocation

    Stack Overflow | 10 months ago | BigSam
    mockit.internal.MissingInvocation: Missing invocation of: com.egoo.dao.repository.freelink.AgentInfoRepository#getAllAgents() on mock instance: com.egoo.dao.repository.freelink.$Impl_AgentInfoRepository@50a7bc6e at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:117)

    Root Cause Analysis

    1. mockit.internal.MissingInvocation

      Missing invocation of: com.egoo.dao.repository.freelink.AgentInfoRepository#getAllAgents() on mock instance: com.egoo.dao.repository.freelink.$Impl_AgentInfoRepository@50a7bc6e at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:117)

      at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs()
    2. IntelliJ junit4 module
      JUnit4IdeaTestRunner.startRunnerWithArgs
      1. com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:42)
      1 frame
    3. IDEA
      JUnitStarter.main
      1. com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:253)
      2. com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:84)
      2 frames
    4. Java RT
      Method.invoke
      1. sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      2. java.lang.reflect.Method.invoke(Method.java:498)
      2 frames
    5. IDEA
      AppMain.main
      1. com.intellij.rt.execution.application.AppMain.main(AppMain.java:147)
      1 frame