com.googlecode.gwt.test.exceptions.GwtTestPatchException: Error while scanning package 'com.googlecode.gwt.test.internal.patchers'

130 views
Skip to first unread message

rcoe

unread,
Dec 20, 2013, 2:12:13 PM12/20/13
to gwt-test-u...@googlegroups.com
Not sure what's wrong here.  My build log shows my properties file is being scanned and the classpath includes the gwt-test-utils jar, yet the stacktrace shows that the AbstractHasDataPatcher class cannot be loaded, which is clearly part of the gwt-test-utils jar.  This is output from an ant build but I get the same stacktrace when building inside eclipse.

2013-12-20 11:17:08,795 [main] DEBUG com.googlecode.gwt.test.internal.ConfigurationLoader - Load config file file:/F:/ScannerPortal/build/junit/META-INF/gwt-test-utils.properties
2013-12-20 11:17:08,803 [main] DEBUG com.googlecode.gwt.test.internal.ConfigurationLoader - File loaded and processed file:/F:/ScannerPortal/build/junit/META-INF/gwt-test-utils.properties
2013-12-20 11:17:08,803 [main] DEBUG com.googlecode.gwt.test.internal.ConfigurationLoader - Load config file jar:file:/F:/ScannerPortal/libs/java/gwt-test-utils-0.45/gwt-test-utils-0.45.jar!/META-INF/gwt-test-utils.properties
2013-12-20 11:17:08,827 [main] DEBUG com.googlecode.gwt.test.internal.ConfigurationLoader - File loaded and processed jar:file:/F:/ScannerPortal/libs/java/gwt-test-utils-0.45/gwt-test-utils-0.45.jar!/META-INF/gwt-test-utils.properties
2013-12-20 11:17:08,850 [main] DEBUG com.googlecode.gwt.test.internal.ClassesScanner - Scan package com.googlecode.gwt.test.internal.patchers
2013-12-20 11:17:08,858 [main] DEBUG com.googlecode.gwt.test.internal.ClassesScanner - Load classes from jar /F:/ScannerPortal/libs/java/gwt-test-utils-0.45/gwt-test-utils-0.45.jar

com.googlecode.gwt.test.exceptions.GwtTestPatchException: Error while scanning package 'com.googlecode.gwt.test.internal.patchers'
    at com.googlecode.gwt.test.internal.ClassesScanner.scanPackages(ClassesScanner.java:68)
    at com.googlecode.gwt.test.internal.ConfigurationLoader.visitPatchClasses(ConfigurationLoader.java:287)
    at com.googlecode.gwt.test.internal.ConfigurationLoader.<init>(ConfigurationLoader.java:64)
    at com.googlecode.gwt.test.internal.GwtFactory.<init>(GwtFactory.java:87)
    at com.googlecode.gwt.test.internal.GwtFactory.initializeIfNeeded(GwtFactory.java:45)
    at com.googlecode.gwt.test.internal.junit.AbstractGwtRunner.<init>(AbstractGwtRunner.java:30)
    at com.googlecode.gwt.test.GwtRunner.<init>(GwtRunner.java:19)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:526)
Caused by: com.googlecode.gwt.test.exceptions.GwtTestPatchException: Cannot find class in the classpath : 'com.googlecode.gwt.test.internal.patchers.AbstractHasDataPatcher'
    at com.googlecode.gwt.test.internal.GwtClassPool.getClass(GwtClassPool.java:27)
    at com.googlecode.gwt.test.internal.ClassesScanner.visitClass(ClassesScanner.java:107)
    at com.googlecode.gwt.test.internal.ClassesScanner.scanClassesFromJarFile(ClassesScanner.java:99)
    at com.googlecode.gwt.test.internal.ClassesScanner.scanPackages(ClassesScanner.java:62)

rcoe

unread,
Dec 23, 2013, 12:35:56 PM12/23/13
to gwt-test-u...@googlegroups.com
I have solved my problem, which was to fork the junit task of my build.

<junit fork="yes"                                     <-- changed "no" to "yes" and my build started working
               dir="${junit.output.dir}"
               printsummary="withOutAndErr"
               haltonerror="true"
               haltonfailure="true"
               includeantruntime="true"
               showoutput="true">
Reply all
Reply to author
Forward
0 new messages