Revision: 10161
Author:   rchan...@google.com
Date:     Fri May  6 13:29:14 2011
Log: Disabling test for null on getBrowserById for DOM elements without DTD when running on Chrome 11

Review at http://gwt-code-reviews.appspot.com/1440801

http://code.google.com/p/google-web-toolkit/source/detail?r=10161

Modified:
 /trunk/user/test/com/google/gwt/xml/client/XMLTest.java

=======================================
--- /trunk/user/test/com/google/gwt/xml/client/XMLTest.java Thu Jan 6 06:39:51 2011 +++ /trunk/user/test/com/google/gwt/xml/client/XMLTest.java Fri May 6 13:29:14 2011
@@ -18,6 +18,7 @@
 import com.google.gwt.junit.DoNotRunWith;
 import com.google.gwt.junit.Platform;
 import com.google.gwt.junit.client.GWTTestCase;
+import com.google.gwt.user.client.Window;
 import com.google.gwt.xml.client.impl.DOMParseException;
 import com.google.gwt.xml.client.impl.XMLParserImplSafari;

@@ -129,7 +130,7 @@
     top.appendChild(d.createCDATASection("klmnopqrst"));
     return d;
   }
-
+
   /**
    * Returns the module name for GWT unit test running.
    */
@@ -216,7 +217,10 @@

     // we didn't define a dtd, so no id for us
     Element e1NodeDirect = d.getElementById("e1Id");
-    assertNull(e1NodeDirect);
+    // Chrome 11 fails to implement this behavior
+    if (!Window.Navigator.getUserAgent().contains("Chrome/11.")) {
+      assertNull(e1NodeDirect);
+    }

     Document alienDoc = XMLParser.createDocument();
     Node alienNode11 = alienDoc.importNode(e1Node, true);

--
http://groups.google.com/group/Google-Web-Toolkit-Contributors

Reply via email to