Skip to content

Commit 2c25547

Browse files
TimvdLippeekuefler
authored andcommitted
Upgrade javassist to 3.25.0-GA and fix test failures (#82)
1 parent 62c6c1c commit 2c25547

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

gwtmockito/src/main/java/com/google/gwtmockito/GwtMockitoTestRunner.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -261,10 +261,12 @@ protected Collection<String> getPackagesToLoadViaStandardClassloader() {
261261
packages.add("com.vladium"); // To support EMMA code coverage tools
262262
packages.add("jdk.internal.reflect"); // Java9 loading mechanism
263263
packages.add("net.bytebuddy"); // To support Mockito 2
264+
packages.add("net.sf.cglib"); // To support Mockito 1
264265
packages.add("net.sourceforge.cobertura"); // To support Cobertura code coverage tools
265266
packages.add("org.jacoco"); // To support JaCoCo code coverage tools
266267
packages.add("org.hamcrest"); // Since this package is referenced directly from org.junit
267268
packages.add("org.junit"); // Make sure the ParentRunner can recognize annotations like @Test
269+
packages.add("org.mockito.cglib"); // To support Mockito 1
268270

269271
WithPackagesToLoadViaStandardClassLoader annotation = unitTestClass.getAnnotation(WithPackagesToLoadViaStandardClassLoader.class);
270272
if (annotation != null) {
@@ -402,6 +404,7 @@ private final class GwtMockitoClassLoader extends Loader implements Translator {
402404
super(classLoader == null ? GwtMockitoTestRunner.class.getClassLoader() : classLoader, classPool);
403405
try {
404406
addTranslator(classPool, this);
407+
setDomain(getClass().getProtectionDomain());
405408
} catch (NotFoundException e) {
406409
throw new AssertionError("Impossible since this.start does not throw");
407410
} catch (CannotCompileException e) {

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
<dependency>
7373
<groupId>org.javassist</groupId>
7474
<artifactId>javassist</artifactId>
75-
<version>3.22.0-GA</version>
75+
<version>3.25.0-GA</version>
7676
</dependency>
7777

7878
<dependency>

0 commit comments

Comments
 (0)