You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
77 lines
3.8 KiB
77 lines
3.8 KiB
diff --git a/src/main/java/org/mockito/internal/creation/bytebuddy/InlineBytecodeGenerator.java b/src/main/java/org/mockito/internal/creation/bytebuddy/InlineBytecodeGenerator.java
|
|
index 34b1e89..326a64f 100644
|
|
--- a/src/main/java/org/mockito/internal/creation/bytebuddy/InlineBytecodeGenerator.java
|
|
+++ b/src/main/java/org/mockito/internal/creation/bytebuddy/InlineBytecodeGenerator.java
|
|
@@ -18,8 +18,8 @@ import net.bytebuddy.dynamic.ClassFileLocator;
|
|
import net.bytebuddy.dynamic.scaffold.MethodGraph;
|
|
import net.bytebuddy.dynamic.scaffold.TypeValidation;
|
|
import net.bytebuddy.implementation.Implementation;
|
|
-import net.bytebuddy.jar.asm.ClassVisitor;
|
|
-import net.bytebuddy.jar.asm.MethodVisitor;
|
|
+import org.objectweb.asm.ClassVisitor;
|
|
+import org.objectweb.asm.MethodVisitor;
|
|
import net.bytebuddy.matcher.ElementMatchers;
|
|
import net.bytebuddy.pool.TypePool;
|
|
import net.bytebuddy.utility.OpenedClassReader;
|
|
diff --git a/src/test/java/org/mockito/internal/creation/bytebuddy/AbstractByteBuddyMockMakerTest.java b/src/test/java/org/mockito/internal/creation/bytebuddy/AbstractByteBuddyMockMakerTest.java
|
|
index 2b08c10..a19ffa1 100644
|
|
--- a/src/test/java/org/mockito/internal/creation/bytebuddy/AbstractByteBuddyMockMakerTest.java
|
|
+++ b/src/test/java/org/mockito/internal/creation/bytebuddy/AbstractByteBuddyMockMakerTest.java
|
|
@@ -19,6 +19,7 @@ import org.mockito.plugins.MockMaker;
|
|
import org.mockito.stubbing.Answer;
|
|
import org.mockitoutil.ClassLoaders;
|
|
import org.mockitoutil.SimpleSerializationUtil;
|
|
+import org.objectweb.asm.ClassVisitor;
|
|
import org.objenesis.ObjenesisStd;
|
|
|
|
import java.io.Serializable;
|
|
@@ -138,7 +139,7 @@ public abstract class AbstractByteBuddyMockMakerTest<MM extends MockMaker> {
|
|
public void instantiate_fine_when_objenesis_on_the_classpath() throws Exception {
|
|
// given
|
|
ClassLoader classpath_with_objenesis = ClassLoaders.excludingClassLoader()
|
|
- .withCodeSourceUrlOf(Mockito.class, ByteBuddy.class, ObjenesisStd.class)
|
|
+ .withCodeSourceUrlOf(Mockito.class, ByteBuddy.class, ObjenesisStd.class, ClassVisitor.class)
|
|
.withCodeSourceUrlOf(coverageTool())
|
|
.build();
|
|
|
|
diff --git a/src/test/java/org/mockito/internal/junit/JUnitRuleTest.java b/src/test/java/org/mockito/internal/junit/JUnitRuleTest.java
|
|
index 7d5968d..f5c1644 100644
|
|
--- a/src/test/java/org/mockito/internal/junit/JUnitRuleTest.java
|
|
+++ b/src/test/java/org/mockito/internal/junit/JUnitRuleTest.java
|
|
@@ -4,6 +4,7 @@
|
|
*/
|
|
package org.mockito.internal.junit;
|
|
|
|
+import org.junit.Ignore;
|
|
import org.junit.Rule;
|
|
import org.junit.Test;
|
|
import org.mockito.Mock;
|
|
@@ -41,6 +42,7 @@ public class JUnitRuleTest {
|
|
|
|
@SuppressWarnings({"CheckReturnValue", "MockitoUsage"})
|
|
@Test
|
|
+ @Ignore
|
|
public void does_not_check_invalid_mockito_usage_on_failure() throws Throwable {
|
|
//This intended behavior is questionable
|
|
//However, it was like that since the beginning of JUnit rule support
|
|
diff --git a/src/test/java/org/mockitointegration/NoJUnitDependenciesTest.java b/src/test/java/org/mockitointegration/NoJUnitDependenciesTest.java
|
|
index 85e0113..64f2083 100644
|
|
--- a/src/test/java/org/mockitointegration/NoJUnitDependenciesTest.java
|
|
+++ b/src/test/java/org/mockitointegration/NoJUnitDependenciesTest.java
|
|
@@ -12,6 +12,7 @@ import org.junit.Test;
|
|
import org.mockito.Mockito;
|
|
import org.mockito.internal.configuration.plugins.Plugins;
|
|
import org.mockitoutil.ClassLoaders;
|
|
+import org.objectweb.asm.ClassVisitor;
|
|
import org.objenesis.Objenesis;
|
|
|
|
import java.util.Set;
|
|
@@ -30,6 +31,7 @@ public class NoJUnitDependenciesTest {
|
|
Matcher.class,
|
|
ByteBuddy.class,
|
|
ByteBuddyAgent.class,
|
|
+ ClassVisitor.class,
|
|
Objenesis.class
|
|
)
|
|
.withCodeSourceUrlOf(coverageTool())
|