This repository contains source code of OpenClover Core as well as its integrations: Clover-for-Ant, Clover-for-Eclipse and Clover-for-IDEA plugins. Sources are licensed under Apache 2.0 license.
Other
57
stars
14
forks
source link
Migrate tests from jMock to Mockito and fix Java 17 test compatiblity in clover-maven-plugin #224
Currently tests of clover-maven-plugin are failing because of an old jMock version used:
Error: com.atlassian.maven.plugin.clover.CloverSnapshotMojoTest.testExecuteCloverSnapshotWhenSnapshotDirDoesNotExist -- Time elapsed: 0.004 s <<< ERROR!
java.lang.NoClassDefFoundError: Could not initialize class org.jmock.lib.legacy.ClassImposteriser$3
at org.jmock.lib.legacy.ClassImposteriser.proxyClass(ClassImposteriser.java:97)
at org.jmock.lib.legacy.ClassImposteriser.imposterise(ClassImposteriser.java:66)
at org.jmock.Mockery.mock(Mockery.java:148)
at org.jmock.Mockery.mock(Mockery.java:124)
at org.jmock.integration.junit3.MockObjectTestCase.mock(MockObjectTestCase.java:118)
at com.atlassian.maven.plugin.clover.CloverSnapshotMojoTest.testExecuteCloverSnapshotWhenSnapshotDirDoesNotExist(CloverSnapshotMojoTest.java:33)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:77)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:568)
at junit.framework.TestCase.runTest(TestCase.java:177)
Currently tests of clover-maven-plugin are failing because of an old jMock version used: