Author: hardy.ferentschik
Date: 2009-06-05 11:41:20 -0400 (Fri, 05 Jun 2009)
New Revision: 16714
Modified:
beanvalidation/trunk/validation-tck/src/main/java/org/hibernate/jsr303/tck/util/TestUtil.java
beanvalidation/trunk/validation-tck/src/main/resources/tck-audit.xml
Log:
Added explicit cast for Java 5
Modified:
beanvalidation/trunk/validation-tck/src/main/java/org/hibernate/jsr303/tck/util/TestUtil.java
===================================================================
---
beanvalidation/trunk/validation-tck/src/main/java/org/hibernate/jsr303/tck/util/TestUtil.java 2009-06-05
15:30:57 UTC (rev 16713)
+++
beanvalidation/trunk/validation-tck/src/main/java/org/hibernate/jsr303/tck/util/TestUtil.java 2009-06-05
15:41:20 UTC (rev 16714)
@@ -20,6 +20,7 @@
import java.util.ArrayList;
import java.util.List;
import java.util.Set;
+import java.lang.annotation.Annotation;
import javax.validation.ConstraintViolation;
import javax.validation.Validation;
import javax.validation.Validator;
@@ -41,7 +42,7 @@
public static <T> void assertCorrectConstraintType(ConstraintViolation<T>
violation, Class<?> expectedConstraintType) {
assertEquals(
- violation.getConstraintDescriptor().getAnnotation().annotationType().getName(),
+ (( Annotation
)violation.getConstraintDescriptor().getAnnotation()).annotationType().getName(),
expectedConstraintType.getName(),
"Wrong constraint type"
);
@@ -54,7 +55,7 @@
public static <T> void
assertCorrectConstraintTypes(Set<ConstraintViolation<T>> violations,
Class<?>[] expectedConsraintTypes) {
List<String> constraintTypes = new ArrayList<String>();
for ( ConstraintViolation<?> violation : violations ) {
- constraintTypes.add(
violation.getConstraintDescriptor().getAnnotation().annotationType().getName() );
+ constraintTypes.add( (( Annotation
)violation.getConstraintDescriptor().getAnnotation()).annotationType().getName() );
}
assertEquals( expectedConsraintTypes.length, constraintTypes.size(), "Wring number
of constraint types." );
Modified: beanvalidation/trunk/validation-tck/src/main/resources/tck-audit.xml
===================================================================
--- beanvalidation/trunk/validation-tck/src/main/resources/tck-audit.xml 2009-06-05
15:30:57 UTC (rev 16713)
+++ beanvalidation/trunk/validation-tck/src/main/resources/tck-audit.xml 2009-06-05
15:41:20 UTC (rev 16714)
@@ -92,7 +92,7 @@
</assertion>
<assertion id="f">
<text>The property type a composed constraint is placed on must be
compatible with all
- constraints (composing and com- posed)</text>
+ constraints (composing and composed)</text>
</assertion>
<assertion id="g">
<text> If a composed constraint is marked as @ReportAsSingleViolation,
and if any of its
@@ -116,7 +116,7 @@
</assertion>
<assertion id="k">
<text>A composing constraint can itself be a composed constraint. In
this case,
- attribute values are overridden re- cursively according to the described
+ attribute values are overridden recursively according to the described
rules</text>
</assertion>
<assertion id="l">