Cherry picking bugs from trunk into release branch: 1032801, 1035801, 1031801
git-svn-id: https://google-web-toolkit.googlecode.com/svn/releases/2.1@9125 8db76d5a-ed1c-0410-87a9-c151d255dfc7
diff --git a/samples/expenses/README-MAVEN.txt b/samples/expenses/README-MAVEN.txt
index 40e8546..cbb08be 100644
--- a/samples/expenses/README-MAVEN.txt
+++ b/samples/expenses/README-MAVEN.txt
@@ -4,9 +4,12 @@
Eclipse. We've tested against Eclipse 3.5. Later versions will likely
also work, earlier versions may not.
-Eclipse users will need to have the m2eclipse, or equivalent, pluigin
-installed. Instructions for how to install the m2eclipse plugin can
-be found here: http://m2eclipse.sonatype.org/installing-m2eclipse.html
+Eclipse users will need to install the following plugin components:
+- Google Plugin for Eclipse (instructions at http://code.google.com/eclipse/)
+- m2eclipse Core
+- Maven Integration for WTP (in m2eclipse extras)
+ Instructions for installing the maven plugins can be found here:
+ http://m2eclipse.sonatype.org/installing-m2eclipse.html
Ensure Eclipse is configured to use Java 1.6 as this sample uses
AppEngine.
diff --git a/samples/expenses/pom.xml b/samples/expenses/pom.xml
index 5b1b174..e22bf9a 100644
--- a/samples/expenses/pom.xml
+++ b/samples/expenses/pom.xml
@@ -25,11 +25,6 @@
<enabled>true</enabled>
</snapshots>
</repository>
- <repository>
- <id>maven-gae-plugin-repo</id>
- <url>http://maven-gae-plugin.googlecode.com/svn/repository</url>
- <name>maven-gae-plugin repository</name>
- </repository>
<repository>
<id>spring-maven-release</id>
<name>Spring Maven Release Repository</name>
@@ -155,7 +150,7 @@
<dependency>
<groupId>com.google.appengine.orm</groupId>
<artifactId>datanucleus-appengine</artifactId>
- <version>1.0.7.final</version>
+ <version>1.0.7</version>
</dependency>
<!-- must be in main dependencies as well as plugin dependencies below -->
<dependency>
@@ -416,6 +411,9 @@
<artifactId>json</artifactId>
<version>20090211</version>
</dependency>
+ <!-- Uncomment appengine-local-runtime and appengine-tools-api to be able to run App Engine unit tests -->
+ <!-- With these uncommented, you must run mvn gae:unpack before importing the project into Eclipse -->
+ <!--
<dependency>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-local-runtime</artifactId>
@@ -430,6 +428,7 @@
<scope>system</scope>
<systemPath>${gae.home}/lib/appengine-tools-api.jar</systemPath>
</dependency>
+ -->
<dependency>
<groupId>net.sf.jsr107cache</groupId>
<artifactId>jsr107cache</artifactId>
diff --git a/user/src/com/google/gwt/junit/RunStyleHtmlUnit.java b/user/src/com/google/gwt/junit/RunStyleHtmlUnit.java
index 22c1354..ad072b1 100644
--- a/user/src/com/google/gwt/junit/RunStyleHtmlUnit.java
+++ b/user/src/com/google/gwt/junit/RunStyleHtmlUnit.java
@@ -32,6 +32,9 @@
import net.sourceforge.htmlunit.corejs.javascript.ScriptableObject;
+import org.w3c.css.sac.CSSParseException;
+import org.w3c.css.sac.ErrorHandler;
+
import java.io.IOException;
import java.net.MalformedURLException;
import java.util.ArrayList;
@@ -91,6 +94,25 @@
public void run() {
WebClient webClient = new WebClient(browser);
webClient.setAlertHandler(this);
+ // Adding a handler that ignores errors to work-around
+ // https://sourceforge.net/tracker/?func=detail&aid=3090806&group_id=47038&atid=448266
+ webClient.setCssErrorHandler(new ErrorHandler() {
+
+ public void error(CSSParseException exception) {
+ // ignore
+ }
+
+ public void fatalError(CSSParseException exception) {
+ treeLogger.log(TreeLogger.WARN,
+ "CSS fatal error: " + exception.getURI() + " ["
+ + exception.getLineNumber() + ":"
+ + exception.getColumnNumber() + "] " + exception.getMessage());
+ }
+
+ public void warning(CSSParseException exception) {
+ // ignore
+ }
+ });
webClient.setIncorrectnessListener(this);
webClient.setThrowExceptionOnFailingStatusCode(false);
webClient.setThrowExceptionOnScriptError(true);