Revision: 9706
Author: ncha...@google.com
Date: Wed Feb  9 08:55:13 2011
Log: Fix TestUtil.PathImpl to correctly test for non matching
RegExp groups.
getGroup returns null or "" depending on the browser.

[JSR 303 TCK Result] 93 of 257 (36.19%) Pass with 33 Failures and 14 Errors.

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

Review by: rchan...@google.com
http://code.google.com/p/google-web-toolkit/source/detail?r=9706

Modified:
/trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/constraintcomposition/ConstraintCompositionGwtTest.java /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/customconstraint/CustomConstraintValidatorGwtTest.java /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/validatorresolution/ValidatorResolutionGwtTest.java /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidateGwtTest.java /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidatePropertyGwtTest.java /trunk/user/test-super/org/hibernate/jsr303/tck/super/org/hibernate/jsr303/tck/util/TestUtil.java

=======================================
--- /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/constraintcomposition/ConstraintCompositionGwtTest.java Mon Feb 7 07:41:58 2011 +++ /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/constraintcomposition/ConstraintCompositionGwtTest.java Wed Feb 9 08:55:13 2011
@@ -1,12 +1,12 @@
 /*
  * Copyright 2010 Google Inc.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License"); you may not * use this file except in compliance with the License. You may obtain a copy of
  * the License at
- *
+ *
  * http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
  * Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
  * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
@@ -23,6 +23,7 @@
  * Wraps {@link ConstraintCompositionTest}.
  */
 public class ConstraintCompositionGwtTest extends GWTTestCase {
+
private final ConstraintCompositionTest delegate = new ConstraintCompositionTest();

   @Override
@@ -40,16 +41,12 @@
     delegate.testAttributesDefinedOnComposingConstraints();
   }

-  @Failing(issue = 5882)
   public void testComposedConstraints() {
     delegate.testComposedConstraints();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

-  @Failing(issue = 5882)
   public void testComposedConstraintsAreRecursive() {
     delegate.testComposedConstraintsAreRecursive();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

   @Failing(issue = 5799)
=======================================
--- /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/customconstraint/CustomConstraintValidatorGwtTest.java Mon Feb 7 07:41:58 2011 +++ /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/customconstraint/CustomConstraintValidatorGwtTest.java Wed Feb 9 08:55:13 2011
@@ -30,10 +30,8 @@
return "org.hibernate.jsr303.tck.tests.constraints.customconstraint.TckTest";
   }

-  @Failing(issue = 5882)
   public void testDefaultPropertyPath() {
     delegate.testDefaultPropertyPath();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

   @Failing(issue = 5800)
=======================================
--- /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/validatorresolution/ValidatorResolutionGwtTest.java Mon Feb 7 07:41:58 2011 +++ /trunk/user/test/org/hibernate/jsr303/tck/tests/constraints/validatorresolution/ValidatorResolutionGwtTest.java Wed Feb 9 08:55:13 2011
@@ -34,10 +34,8 @@
     delegate.testAmbiguousValidatorResolution();
   }

-  @Failing(issue = 5882)
   public void testResolutionOfMinMaxForDifferentTypes() {
     delegate.testResolutionOfMinMaxForDifferentTypes();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

   @Failing(issue = 5806)
=======================================
--- /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidateGwtTest.java Mon Feb 7 10:54:02 2011 +++ /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidateGwtTest.java Wed Feb 9 08:55:13 2011
@@ -30,10 +30,8 @@
     delegate.testConstraintDescriptorWithoutExplicitGroup();
   }

-  @Failing(issue = 5882)
   public void testConstraintViolation() {
     delegate.testConstraintViolation();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

   @Failing(issue = 5982)
=======================================
--- /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidatePropertyGwtTest.java Mon Feb 7 07:41:58 2011 +++ /trunk/user/test/org/hibernate/jsr303/tck/tests/validation/ValidatePropertyGwtTest.java Wed Feb 9 08:55:13 2011
@@ -46,10 +46,8 @@
     }
   }

-  @Failing(issue = 5882)
   public void testValidateProperty() {
     delegate.testValidateProperty();
- fail("This test only fails on IE. Forcing it to fail here to keep the counts even. See issue 5882.");
   }

   public void testValidatePropertyWithEmptyProperty() {
=======================================
--- /trunk/user/test-super/org/hibernate/jsr303/tck/super/org/hibernate/jsr303/tck/util/TestUtil.java Tue Jan 11 14:19:47 2011 +++ /trunk/user/test-super/org/hibernate/jsr303/tck/super/org/hibernate/jsr303/tck/util/TestUtil.java Wed Feb 9 08:55:13 2011
@@ -315,7 +315,8 @@
           String indexed = matcher.getGroup(2);
           String index = matcher.getGroup(3);
           NodeImpl node = new NodeImpl(value);
-          if (indexed != null) {
+
+          if (indexed != null && indexed.length() > 0) {
             node.setInIterable(true);
           }
           if (index != null && index.length() > 0) {
@@ -332,7 +333,7 @@
throw new IllegalArgumentException("Unable to parse property path "
               + property);
         }
-      } while (tmp != null);
+      } while (tmp != null && tmp.length() > 0);
       return path;
     }
   }

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

Reply via email to