Could not initialize plugin: interface org.mockito.plugins.MockMaker

后端 未结 25 2206
走了就别回头了
走了就别回头了 2020-12-29 01:01

I\'m getting following exception once tests is started:

    Testcase: treeCtorArgumentTest(com.xythos.client.drive.cachedtree.CachedTreeTest):  Caused an ERR         


        
25条回答
  •  轮回少年
    2020-12-29 01:32

    I solved this problem by removing jmockit in POM XML for Maven. After that my Junit 5 tests work perfectly.

        
            org.jmockit
            jmockit
            1.41
            test
        
    

    With this dependency I always get an error like:

    java.lang.IllegalStateException: Could not initialize plugin: interface org.mockito.plugins.MockMaker (alternate: null)
    ...
    
    Could not initialize inline Byte Buddy mock maker. (This mock maker is not supported on Android.)
    ...
    
    Caused by: com.sun.tools.attach.AttachNotSupportedException: no providers installed
    ...
    

提交回复
热议问题