You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bval.apache.org by mb...@apache.org on 2018/02/24 20:09:51 UTC
[1/4] bval git commit: unused import
Repository: bval
Updated Branches:
refs/heads/bv2 ca2212e0c -> ebc06167b
unused import
Project: http://git-wip-us.apache.org/repos/asf/bval/repo
Commit: http://git-wip-us.apache.org/repos/asf/bval/commit/2cdeb84c
Tree: http://git-wip-us.apache.org/repos/asf/bval/tree/2cdeb84c
Diff: http://git-wip-us.apache.org/repos/asf/bval/diff/2cdeb84c
Branch: refs/heads/bv2
Commit: 2cdeb84c9b7a03254e4831b100bcaaa2b33fd94a
Parents: ca2212e
Author: Matt Benson <mb...@apache.org>
Authored: Sat Feb 24 13:56:37 2018 -0600
Committer: Matt Benson <mb...@apache.org>
Committed: Sat Feb 24 13:56:37 2018 -0600
----------------------------------------------------------------------
bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java | 1 -
1 file changed, 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/bval/blob/2cdeb84c/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java
index bd04439..60267c1 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/Metas.java
@@ -32,7 +32,6 @@ import java.lang.reflect.Member;
import java.lang.reflect.Method;
import java.lang.reflect.Parameter;
import java.lang.reflect.Type;
-import java.util.Arrays;
import java.util.Collection;
import java.util.Objects;
[3/4] bval git commit: add descriptor subpackage descriptor to
address the question that has already come up about the meaning of the -D
classname suffix in that package
Posted by mb...@apache.org.
add descriptor subpackage descriptor to address the question that has already come up about the meaning of the -D classname suffix in that package
Project: http://git-wip-us.apache.org/repos/asf/bval/repo
Commit: http://git-wip-us.apache.org/repos/asf/bval/commit/96106915
Tree: http://git-wip-us.apache.org/repos/asf/bval/tree/96106915
Diff: http://git-wip-us.apache.org/repos/asf/bval/diff/96106915
Branch: refs/heads/bv2
Commit: 961069159cd8e5894012926c4e15def2658a0a97
Parents: a7d88a5
Author: Matt Benson <mb...@apache.org>
Authored: Sat Feb 24 14:00:39 2018 -0600
Committer: Matt Benson <mb...@apache.org>
Committed: Sat Feb 24 14:00:39 2018 -0600
----------------------------------------------------------------------
.../bval/jsr/descriptor/package-info.java | 21 ++++++++++++++++++++
1 file changed, 21 insertions(+)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/bval/blob/96106915/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/package-info.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/package-info.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/package-info.java
new file mode 100644
index 0000000..a5b6522
--- /dev/null
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/package-info.java
@@ -0,0 +1,21 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You 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 License for the specific language governing permissions and
+ * limitations under the License.
+ */
+/**
+ * This package houses the implementations and related classes for BV element descriptors, using the {@code D} suffix to
+ * succinctly denote implementations of {@code *Descriptor}.
+ */
+package org.apache.bval.jsr.descriptor;
\ No newline at end of file
[2/4] bval git commit: eschew laziness in descriptor model as TCK
tests (rightly) depend on the creation of the metamodel detecting all issues
eagerly;
address some issues that became apparent with the removal of said laziness
Posted by mb...@apache.org.
eschew laziness in descriptor model as TCK tests (rightly) depend on the creation of the metamodel detecting all issues eagerly;
address some issues that became apparent with the removal of said
laziness
Project: http://git-wip-us.apache.org/repos/asf/bval/repo
Commit: http://git-wip-us.apache.org/repos/asf/bval/commit/a7d88a5c
Tree: http://git-wip-us.apache.org/repos/asf/bval/tree/a7d88a5c
Diff: http://git-wip-us.apache.org/repos/asf/bval/diff/a7d88a5c
Branch: refs/heads/bv2
Commit: a7d88a5c45e7b234bbda0d021573f6f4674c1661
Parents: 2cdeb84
Author: Matt Benson <mb...@apache.org>
Authored: Sat Feb 24 13:58:20 2018 -0600
Committer: Matt Benson <mb...@apache.org>
Committed: Sat Feb 24 13:58:40 2018 -0600
----------------------------------------------------------------------
.../org/apache/bval/jsr/descriptor/BeanD.java | 46 ++++------
.../jsr/descriptor/CascadableContainerD.java | 7 +-
.../apache/bval/jsr/descriptor/ConstraintD.java | 91 ++++++++++----------
.../bval/jsr/descriptor/DescriptorManager.java | 9 +-
.../bval/jsr/descriptor/MetadataReader.java | 15 ++--
.../apache/bval/jsr/descriptor/ParameterD.java | 2 +-
.../bval/jsr/metadata/CompositeBuilder.java | 6 +-
.../bval/jsr/metadata/HierarchyBuilder.java | 5 +-
8 files changed, 92 insertions(+), 89 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/BeanD.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/BeanD.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/BeanD.java
index e1e97ee..b6e7e2e 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/BeanD.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/BeanD.java
@@ -34,33 +34,26 @@ import javax.validation.metadata.PropertyDescriptor;
import org.apache.bval.jsr.metadata.Signature;
import org.apache.bval.jsr.util.ToUnmodifiable;
import org.apache.bval.util.Exceptions;
-import org.apache.bval.util.Lazy;
import org.apache.bval.util.StringUtils;
public class BeanD extends ElementD<Class<?>, MetadataReader.ForBean> implements BeanDescriptor {
- private static boolean constrainedProperty(PropertyDescriptor pd) {
- return pd.hasConstraints() || pd.isCascaded();
- }
-
private final Class<?> beanClass;
-
- private final Lazy<List<Class<?>>> groupSequence;
- private final Lazy<Map<String, PropertyDescriptor>> propertiesMap;
- private final Lazy<Set<PropertyDescriptor>> properties;
- private final Lazy<Map<Signature, ConstructorD>> constructors;
- private final Lazy<Map<Signature, MethodD>> methods;
+ private final List<Class<?>> groupSequence;
+ private final Map<String, PropertyDescriptor> propertiesMap;
+ private final Set<PropertyDescriptor> properties;
+ private final Map<Signature, ConstructorD> constructors;
+ private final Map<Signature, MethodD> methods;
BeanD(MetadataReader.ForBean reader) {
super(reader);
this.beanClass = reader.meta.getHost();
- groupSequence = new Lazy<>(reader::getGroupSequence);
- propertiesMap = new Lazy<>(() -> reader.getProperties(this));
- properties = new Lazy<>(() -> propertiesMap.get().values().stream().filter(BeanD::constrainedProperty)
- .collect(ToUnmodifiable.set()));
- constructors = new Lazy<>(() -> reader.getConstructors(this));
- methods = new Lazy<>(() -> reader.getMethods(this));
+ groupSequence = reader.getGroupSequence();
+ propertiesMap = reader.getProperties(this);
+ properties = propertiesMap.values().stream().filter(DescriptorManager::isConstrained).collect(ToUnmodifiable.set());
+ constructors = reader.getConstructors(this);
+ methods = reader.getMethods(this);
}
@Override
@@ -70,22 +63,21 @@ public class BeanD extends ElementD<Class<?>, MetadataReader.ForBean> implements
@Override
public boolean isBeanConstrained() {
- return hasConstraints() || properties.get().stream().anyMatch(DescriptorManager::isConstrained);
+ return hasConstraints() || properties.stream().anyMatch(DescriptorManager::isConstrained);
}
@Override
public PropertyDescriptor getConstraintsForProperty(String propertyName) {
- return Optional.ofNullable(getProperty(propertyName)).filter(BeanD::constrainedProperty).orElse(null);
+ return Optional.ofNullable(getProperty(propertyName)).filter(DescriptorManager::isConstrained).orElse(null);
}
@Override
public Set<PropertyDescriptor> getConstrainedProperties() {
- return properties.get();
+ return properties;
}
@Override
public MethodDescriptor getConstraintsForMethod(String methodName, Class<?>... parameterTypes) {
- final Map<Signature, MethodD> methods = this.methods.get();
final Signature key = new Signature(methodName, parameterTypes);
return methods.get(key);
}
@@ -93,26 +85,26 @@ public class BeanD extends ElementD<Class<?>, MetadataReader.ForBean> implements
@SuppressWarnings("unlikely-arg-type")
@Override
public Set<MethodDescriptor> getConstrainedMethods(MethodType methodType, MethodType... methodTypes) {
- EnumSet<MethodType> filter = EnumSet.of(methodType, methodTypes);
- return methods.get().values().stream().filter(m -> filter.contains(m.getMethodType()))
+ final EnumSet<MethodType> filter = EnumSet.of(methodType, methodTypes);
+ return methods.values().stream().filter(m -> filter.contains(m.getMethodType()))
.collect(ToUnmodifiable.set());
}
@Override
public ConstructorDescriptor getConstraintsForConstructor(Class<?>... parameterTypes) {
- return constructors.get().get(new Signature(beanClass.getName(), parameterTypes));
+ return constructors.get(new Signature(beanClass.getName(), parameterTypes));
}
@Override
public Set<ConstructorDescriptor> getConstrainedConstructors() {
- return constructors.get().values().stream().collect(ToUnmodifiable.set());
+ return constructors.values().stream().collect(ToUnmodifiable.set());
}
public PropertyDescriptor getProperty(String propertyName) {
Exceptions.raiseIf(StringUtils.isBlank(propertyName), IllegalArgumentException::new,
"propertyName was null/empty/blank");
- return propertiesMap.get().get(propertyName);
+ return propertiesMap.get(propertyName);
}
@Override
@@ -122,7 +114,7 @@ public class BeanD extends ElementD<Class<?>, MetadataReader.ForBean> implements
@Override
public List<Class<?>> getGroupSequence() {
- return groupSequence.get();
+ return groupSequence;
}
public final Type getGenericType() {
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/CascadableContainerD.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/CascadableContainerD.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/CascadableContainerD.java
index 8c76fb0..8e6410a 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/CascadableContainerD.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/CascadableContainerD.java
@@ -30,7 +30,6 @@ import javax.validation.metadata.GroupConversionDescriptor;
import org.apache.bval.jsr.GraphContext;
import org.apache.bval.jsr.util.ToUnmodifiable;
-import org.apache.bval.util.Lazy;
import org.apache.bval.util.Validate;
import org.apache.bval.util.reflection.TypeUtils;
@@ -39,13 +38,13 @@ public abstract class CascadableContainerD<P extends ElementD<?, ?>, E extends A
private final boolean cascaded;
private final Set<GroupConversion> groupConversions;
- private final Lazy<Set<ContainerElementTypeD>> containerElementTypes;
+ private final Set<ContainerElementTypeD> containerElementTypes;
protected CascadableContainerD(MetadataReader.ForContainer<E> reader, P parent) {
super(reader, parent);
cascaded = reader.isCascaded();
groupConversions = reader.getGroupConversions();
- containerElementTypes = new Lazy<>(() -> reader.getContainerElementTypes(this));
+ containerElementTypes = reader.getContainerElementTypes(this);
}
@Override
@@ -66,7 +65,7 @@ public abstract class CascadableContainerD<P extends ElementD<?, ?>, E extends A
@Override
public Set<ContainerElementTypeDescriptor> getConstrainedContainerElementTypes() {
- return containerElementTypes.get().stream().filter(DescriptorManager::isConstrained)
+ return containerElementTypes.stream().filter(DescriptorManager::isConstrained)
.collect(ToUnmodifiable.set());
}
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ConstraintD.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ConstraintD.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ConstraintD.java
index c812cf5..c5000e2 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ConstraintD.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ConstraintD.java
@@ -57,11 +57,18 @@ import org.apache.bval.jsr.util.AnnotationsManager;
import org.apache.bval.jsr.util.ToUnmodifiable;
import org.apache.bval.jsr.valueextraction.ValueExtractors;
import org.apache.bval.util.Exceptions;
-import org.apache.bval.util.Lazy;
import org.apache.bval.util.Validate;
import org.apache.bval.util.reflection.TypeUtils;
public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A> {
+ private enum Optionality {
+ OPTIONAL, REQUIRED;
+
+ public boolean isOptional() {
+ return this == Optionality.OPTIONAL;
+ }
+ }
+
private static <T> Set<T> set(Supplier<T[]> array) {
return Stream.of(array.get()).collect(ToUnmodifiable.set());
}
@@ -69,42 +76,37 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
private final A annotation;
private final Scope scope;
private final Metas<?> meta;
- private final Class<?> validatedType;
-
- private final Lazy<Set<Class<?>>> groups = new Lazy<>(this::computeGroups);
private final Set<Class<? extends Payload>> payload;
+ private final Class<?> validatedType;
- private final Lazy<Boolean> reportAsSingle =
- new Lazy<>(() -> getAnnotation().annotationType().isAnnotationPresent(ReportAsSingleViolation.class));
-
- private final Lazy<ValidateUnwrappedValue> valueUnwrapping = new Lazy<>(this::computeValidateUnwrappedValue);
+ private final Set<Class<?>> groups;
+ private final boolean reportAsSingle;
+ private final ValidateUnwrappedValue valueUnwrapping;
+ private final Map<String, Object> attributes;
- private final Lazy<Map<String, Object>> attributes;
- private final Lazy<Set<ConstraintDescriptor<?>>> composingConstraints;
- private final Lazy<List<Class<? extends ConstraintValidator<A, ?>>>> constraintValidatorClasses;
- private final Lazy<Class<? extends ConstraintValidator<A, ?>>> constraintValidatorClass;
+ private final Set<ConstraintDescriptor<?>> composingConstraints;
+ private final List<Class<? extends ConstraintValidator<A, ?>>> constraintValidatorClasses;
+ private final Class<? extends ConstraintValidator<A, ?>> constraintValidatorClass;
public ConstraintD(A annotation, Scope scope, Metas<?> meta, ApacheValidatorFactory validatorFactory) {
this.annotation = Validate.notNull(annotation, "annotation");
this.scope = Validate.notNull(scope, "scope");
this.meta = Validate.notNull(meta, "meta");
- this.payload = computePayload();
- this.validatedType = computeValidatedType(validatorFactory);
-
- attributes = new Lazy<>(() -> AnnotationsManager.readAttributes(annotation));
- // retain no references to the validatorFactory; only wrap it in lazy
- // suppliers
- Validate.notNull(validatorFactory, "validatorFactory");
- composingConstraints = new Lazy<>(computeComposingConstraints(validatorFactory));
- constraintValidatorClasses = new Lazy<>(computeConstraintValidatorClasses(validatorFactory));
+ payload = computePayload();
+ validatedType = computeValidatedType(validatorFactory);
- final Supplier<Class<? extends ConstraintValidator<A, ?>>> computeConstraintValidatorClass =
- new ComputeConstraintValidatorClass<>(validatorFactory, meta.getValidationTargets(), annotation,
- validatedType);
+ groups = computeGroups();
+ reportAsSingle = annotation.annotationType().isAnnotationPresent(ReportAsSingleViolation.class);
+ valueUnwrapping = computeValidateUnwrappedValue();
+ attributes = AnnotationsManager.readAttributes(annotation);
- constraintValidatorClass = new Lazy<>(computeConstraintValidatorClass);
+ Validate.notNull(validatorFactory, "validatorFactory");
+ composingConstraints = computeComposingConstraints(validatorFactory);
+ constraintValidatorClasses = computeConstraintValidatorClasses(validatorFactory);
+ constraintValidatorClass = new ComputeConstraintValidatorClass<>(validatorFactory, meta.getValidationTargets(),
+ annotation, validatedType).get();
}
@Override
@@ -114,7 +116,7 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
@Override
public Set<Class<?>> getGroups() {
- return groups.get();
+ return groups;
}
@Override
@@ -124,28 +126,27 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
@Override
public List<Class<? extends ConstraintValidator<A, ?>>> getConstraintValidatorClasses() {
- return constraintValidatorClasses.get();
+ return constraintValidatorClasses;
}
@Override
public Map<String, Object> getAttributes() {
- return attributes.get();
+ return attributes;
}
@Override
public Set<ConstraintDescriptor<?>> getComposingConstraints() {
- return composingConstraints.get();
+ return composingConstraints;
}
@Override
public boolean isReportAsSingleViolation() {
- return reportAsSingle.get().booleanValue();
+ return reportAsSingle;
}
@Override
public String getMessageTemplate() {
- final boolean required = true;
- return read(ConstraintAnnotationAttributes.MESSAGE, required);
+ return read(ConstraintAnnotationAttributes.MESSAGE, Optionality.REQUIRED);
}
@Override
@@ -155,7 +156,7 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
@Override
public ValidateUnwrappedValue getValueUnwrapping() {
- return valueUnwrapping.get();
+ return valueUnwrapping;
}
@Override
@@ -184,35 +185,34 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
}
public Class<? extends ConstraintValidator<A, ?>> getConstraintValidatorClass() {
- return constraintValidatorClass.get();
+ return constraintValidatorClass;
}
private <T> T read(ConstraintAnnotationAttributes attr) {
- return read(attr, false);
+ return read(attr, Optionality.OPTIONAL);
}
- private <T> T read(ConstraintAnnotationAttributes attr, boolean required) {
+ private <T> T read(ConstraintAnnotationAttributes attr, Optionality optionality) {
final Class<? extends Annotation> constraintType = annotation.annotationType();
final Optional<T> result =
Optional.of(constraintType).map(attr::analyze).filter(Worker::isValid).map(w -> w.<T> read(annotation));
- Exceptions.raiseIf(required && !result.isPresent(), ConstraintDefinitionException::new,
+ Exceptions.raiseUnless(optionality.isOptional() || result.isPresent(), ConstraintDefinitionException::new,
"Required attribute %s missing from constraint type %s", attr.getAttributeName(), constraintType);
return result.orElse(null);
}
- private Supplier<Set<ConstraintDescriptor<?>>> computeComposingConstraints(
- ApacheValidatorFactory validatorFactory) {
- return () -> Stream.of(validatorFactory.getAnnotationsManager().getComposingConstraints(annotation))
+ private Set<ConstraintDescriptor<?>> computeComposingConstraints(ApacheValidatorFactory validatorFactory) {
+ return Stream.of(validatorFactory.getAnnotationsManager().getComposingConstraints(annotation))
.map(c -> new ConstraintD<>(c, scope, meta, validatorFactory))
.collect(ToUnmodifiable.set(LinkedHashSet::new));
}
@SuppressWarnings("unchecked")
- private Supplier<List<Class<? extends ConstraintValidator<A, ?>>>> computeConstraintValidatorClasses(
+ private List<Class<? extends ConstraintValidator<A, ?>>> computeConstraintValidatorClasses(
ApacheValidatorFactory validatorFactory) {
- return () -> validatorFactory.getConstraintsCache()
+ return validatorFactory.getConstraintsCache()
.getConstraintValidatorClasses((Class<A>) annotation.annotationType());
}
@@ -229,8 +229,7 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
}
private Set<Class<?>> computeGroups() {
- final boolean required = true;
- final Class<?>[] groups = read(ConstraintAnnotationAttributes.GROUPS, required);
+ final Class<?>[] groups = read(ConstraintAnnotationAttributes.GROUPS, Optionality.REQUIRED);
if (groups.length == 0) {
return Collections.singleton(Default.class);
}
@@ -238,8 +237,8 @@ public class ConstraintD<A extends Annotation> implements ConstraintDescriptor<A
}
private Set<Class<? extends Payload>> computePayload() {
- final boolean required = true;
- final Set<Class<? extends Payload>> result = set(() -> read(ConstraintAnnotationAttributes.PAYLOAD, required));
+ final Set<Class<? extends Payload>> result =
+ set(() -> read(ConstraintAnnotationAttributes.PAYLOAD, Optionality.REQUIRED));
Exceptions.raiseIf(result.containsAll(Arrays.asList(Unwrapping.Unwrap.class, Unwrapping.Skip.class)),
ConstraintDeclarationException::new,
"Constraint %s declared at %s specifies conflicting value unwrapping hints", annotation, meta.getHost());
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/DescriptorManager.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/DescriptorManager.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/DescriptorManager.java
index 96a0017..e90527e 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/DescriptorManager.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/DescriptorManager.java
@@ -17,6 +17,7 @@
package org.apache.bval.jsr.descriptor;
import java.util.List;
+import java.util.Optional;
import java.util.concurrent.ConcurrentHashMap;
import java.util.concurrent.ConcurrentMap;
@@ -52,7 +53,13 @@ public class DescriptorManager {
public BeanDescriptor getBeanDescriptor(Class<?> beanClass) {
Validate.notNull(beanClass, IllegalArgumentException::new, "beanClass");
- return beanDescriptors.computeIfAbsent(beanClass, k -> new BeanD(metadataReader.forBean(k, builder(k))));
+
+ // cannot use computeIfAbsent due to likely recursion:
+ if (beanDescriptors.containsKey(beanClass)) {
+ return beanDescriptors.get(beanClass);
+ }
+ final BeanD beanD = new BeanD(metadataReader.forBean(beanClass, builder(beanClass)));
+ return Optional.ofNullable(beanDescriptors.putIfAbsent(beanClass, beanD)).orElse(beanD);
}
private MetadataBuilder.ForBean builder(Class<?> beanClass) {
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/MetadataReader.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/MetadataReader.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/MetadataReader.java
index c2f9f0c..ba49ed4 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/MetadataReader.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/MetadataReader.java
@@ -175,14 +175,15 @@ class MetadataReader {
}
}
}
- if (result != null) {
- Exceptions.raiseUnless(result.contains(meta.getHost()), GroupDefinitionException::new,
- "@%s for %s must contain %<s", GroupSequence.class.getSimpleName(), meta.getHost());
- Exceptions.raiseIf(result.contains(Default.class), GroupDefinitionException::new,
- "@%s for %s must not contain %s", GroupSequence.class.getSimpleName(), meta.getHost(),
- Default.class.getName());
+ if (result == null) {
+ return null;
}
- return result;
+ Exceptions.raiseUnless(result.contains(meta.getHost()), GroupDefinitionException::new,
+ "@%s for %s must contain %<s", GroupSequence.class.getSimpleName(), meta.getHost());
+ Exceptions.raiseIf(result.contains(Default.class), GroupDefinitionException::new,
+ "@%s for %s must not contain %s", GroupSequence.class.getSimpleName(), meta.getHost(),
+ Default.class.getName());
+ return Collections.unmodifiableList(result);
}
}
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ParameterD.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ParameterD.java b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ParameterD.java
index 951eccb..e041275 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ParameterD.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/descriptor/ParameterD.java
@@ -33,7 +33,7 @@ public class ParameterD<P extends ExecutableD<?, ?, P>> extends CascadableContai
private final String name;
private final Class<?> type;
- protected ParameterD(Metas.ForParameter meta, int index, MetadataReader.ForContainer<Parameter> reader, P parent) {
+ ParameterD(Metas.ForParameter meta, int index, MetadataReader.ForContainer<Parameter> reader, P parent) {
super(reader, parent);
Validate.isTrue(index >= 0 && index < meta.getHost().getDeclaringExecutable().getParameterCount(),
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/CompositeBuilder.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/CompositeBuilder.java b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/CompositeBuilder.java
index 52a7407..54ff0f8 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/CompositeBuilder.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/CompositeBuilder.java
@@ -184,8 +184,10 @@ public class CompositeBuilder {
final Set<Integer> parameterCounts = parameterLists.stream().map(List::size).collect(Collectors.toSet());
Validate.validState(parameterCounts.size() == 1, "Mismatched parameter counts: %s", parameterCounts);
- return IntStream.range(0, parameterCounts.iterator().next().intValue())
- .mapToObj(n -> new CompositeBuilder.ForContainer<>(parameterLists.get(n)))
+ final int parameterCount = parameterCounts.iterator().next().intValue();
+ return IntStream.range(0, parameterCount)
+ .mapToObj(n -> new CompositeBuilder.ForContainer<>(
+ parameterLists.stream().map(l -> l.get(n)).collect(Collectors.toList())))
.collect(ToUnmodifiable.list());
}
http://git-wip-us.apache.org/repos/asf/bval/blob/a7d88a5c/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/HierarchyBuilder.java
----------------------------------------------------------------------
diff --git a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/HierarchyBuilder.java b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/HierarchyBuilder.java
index a33ac4c..693c065 100644
--- a/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/HierarchyBuilder.java
+++ b/bval-jsr/src/main/java/org/apache/bval/jsr/metadata/HierarchyBuilder.java
@@ -72,9 +72,12 @@ public class HierarchyBuilder extends CompositeBuilder {
return delegate.getGetters(hierarchyType);
}
+ @SuppressWarnings("unlikely-arg-type")
@Override
public Map<Signature, MetadataBuilder.ForExecutable<Constructor<?>>> getConstructors(Metas<Class<?>> meta) {
- return delegate.getConstructors(hierarchyType);
+ // suppress hierarchical ctors:
+ return hierarchyType.equals(meta.getHost()) ? delegate.getConstructors(hierarchyType)
+ : Collections.emptyMap();
}
@Override
[4/4] bval git commit: rename tck module to remove version
Posted by mb...@apache.org.
rename tck module to remove version
Project: http://git-wip-us.apache.org/repos/asf/bval/repo
Commit: http://git-wip-us.apache.org/repos/asf/bval/commit/ebc06167
Tree: http://git-wip-us.apache.org/repos/asf/bval/tree/ebc06167
Diff: http://git-wip-us.apache.org/repos/asf/bval/diff/ebc06167
Branch: refs/heads/bv2
Commit: ebc06167b26c91f16737606d65decd8dfe429998
Parents: 9610691
Author: Matt Benson <mb...@apache.org>
Authored: Sat Feb 24 14:09:34 2018 -0600
Committer: Matt Benson <mb...@apache.org>
Committed: Sat Feb 24 14:09:34 2018 -0600
----------------------------------------------------------------------
bval-tck/pom.xml | 247 +++++++++++++++++++
.../arquillian/BValArquillianExtension.java | 28 +++
.../org/apache/bval/arquillian/EJBEnricher.java | 58 +++++
.../bval/arquillian/jndi/BValJndiFactory.java | 49 ++++
....jboss.arquillian.core.spi.LoadableExtension | 1 +
bval-tck/src/main/resources/jndi.properties | 17 ++
bval-tck/src/test/resources/arquillian.xml | 28 +++
bval-tck/work-tests-suite.xml | 30 +++
bval-tck11/pom.xml | 247 -------------------
.../arquillian/BValArquillianExtension.java | 28 ---
.../org/apache/bval/arquillian/EJBEnricher.java | 58 -----
.../bval/arquillian/jndi/BValJndiFactory.java | 49 ----
....jboss.arquillian.core.spi.LoadableExtension | 1 -
bval-tck11/src/main/resources/jndi.properties | 17 --
bval-tck11/src/test/resources/arquillian.xml | 28 ---
bval-tck11/work-tests-suite.xml | 30 ---
pom.xml | 2 +-
17 files changed, 459 insertions(+), 459 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/pom.xml
----------------------------------------------------------------------
diff --git a/bval-tck/pom.xml b/bval-tck/pom.xml
new file mode 100644
index 0000000..cd338b7
--- /dev/null
+++ b/bval-tck/pom.xml
@@ -0,0 +1,247 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+Licensed to the Apache Software Foundation (ASF) under one
+or more contributor license agreements. See the NOTICE file
+distributed with this work for additional information
+regarding copyright ownership. The ASF licenses this file
+to you 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 License for the
+specific language governing permissions and limitations
+under the License.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+
+ <parent>
+ <artifactId>bval-parent</artifactId>
+ <groupId>org.apache.bval</groupId>
+ <version>2.0.0-SNAPSHOT</version>
+ </parent>
+
+ <artifactId>bval-tck-runner</artifactId>
+ <name>Apache BVal :: bval-tck (TCK Runner)</name>
+ <description>Aggregates dependencies and runs the JSR-349 TCK</description>
+
+ <properties>
+ <tck.version>2.0.2.Final</tck.version>
+ <owb.version>2.0.4</owb.version>
+ <arquillian.version>1.1.11.Final</arquillian.version>
+ <validation.provider>org.apache.bval.jsr.ApacheValidationProvider</validation.provider>
+ </properties>
+
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-validation_2.0_spec</artifactId>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-atinject_1.0_spec</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-jcdi_2.0_spec</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-annotation_1.3_spec</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-interceptor_1.2_spec</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.specs</groupId>
+ <artifactId>geronimo-ejb_3.1_spec</artifactId>
+ <version>1.0</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tomcat</groupId>
+ <artifactId>tomcat-el-api</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.bval</groupId>
+ <artifactId>bval-core</artifactId>
+ <version>${project.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>commons-lang3</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.bval</groupId>
+ <artifactId>bval-jsr</artifactId>
+ <version>${project.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.commons</groupId>
+ <artifactId>commons-lang3</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.arquillian.container</groupId>
+ <artifactId>arquillian-container-test-spi</artifactId>
+ <version>${arquillian.version}</version>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openwebbeans.arquillian</groupId>
+ <artifactId>owb-arquillian-standalone</artifactId>
+ <version>${owb.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.openwebbeans</groupId>
+ <artifactId>openwebbeans-impl</artifactId>
+ <version>${owb.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.tomcat</groupId>
+ <artifactId>tomcat-jasper-el</artifactId>
+ <version>9.0.5</version>
+ <scope>provided</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.hibernate.beanvalidation.tck</groupId>
+ <artifactId>beanvalidation-tck-tests</artifactId>
+ <version>${tck.version}</version>
+ <exclusions>
+ <exclusion>
+ <groupId>javax.validation</groupId>
+ <artifactId>validation-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.jboss.spec.javax.interceptor</groupId>
+ <artifactId>jboss-interceptors-api_1.2_spec</artifactId>
+ </exclusion>
+ </exclusions>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.arquillian.testng</groupId>
+ <artifactId>arquillian-testng-container</artifactId>
+ <version>${arquillian.version}</version>
+ <scope>test</scope>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.arquillian.protocol</groupId>
+ <artifactId>arquillian-protocol-servlet</artifactId>
+ <version>${arquillian.version}</version>
+ <scope>test</scope>
+ </dependency>
+
+ <dependency>
+ <groupId>org.testng</groupId>
+ <artifactId>testng</artifactId>
+ <version>6.8.21</version>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+
+ <profiles>
+ <profile>
+ <id>tck</id>
+ <activation>
+ <activeByDefault>true</activeByDefault>
+ <property>
+ <name>tck</name>
+ </property>
+ </activation>
+ <build>
+ <plugins>
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-deploy-plugin</artifactId>
+ <configuration>
+ <skip>true</skip>
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-dependency-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>copy-tck-test-suite-file</id>
+ <phase>generate-test-sources</phase>
+ <goals>
+ <goal>copy</goal>
+ </goals>
+ <configuration>
+ <stripVersion>true</stripVersion>
+ <artifactItems>
+ <artifactItem>
+ <groupId>org.hibernate.beanvalidation.tck</groupId>
+ <artifactId>beanvalidation-tck-tests</artifactId>
+ <type>xml</type>
+ <classifier>suite</classifier>
+ <overWrite>false</overWrite>
+ </artifactItem>
+ </artifactItems>
+ </configuration>
+ </execution>
+ </executions>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-plugin</artifactId>
+ <configuration>
+ <suiteXmlFiles>
+ <suiteXmlFile>${project.build.directory}/dependency/beanvalidation-tck-tests-suite.xml
+ </suiteXmlFile>
+ </suiteXmlFiles>
+ <systemProperties>
+ <property>
+ <name>validation.provider</name>
+ <value>${validation.provider}</value>
+ </property>
+ </systemProperties>
+ <parallel>methods</parallel>
+ <threadCount>4</threadCount>
+
+ </configuration>
+ </plugin>
+
+ <plugin>
+ <groupId>org.apache.maven.plugins</groupId>
+ <artifactId>maven-surefire-report-plugin</artifactId>
+ <executions>
+ <execution>
+ <id>generate-test-report</id>
+ <phase>test</phase>
+ <goals>
+ <goal>report-only</goal>
+ </goals>
+ </execution>
+ </executions>
+ <configuration>
+ <outputDirectory>${project.build.directory}/surefire-reports</outputDirectory>
+ <outputName>test-report</outputName>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
+ </profile>
+ </profiles>
+</project>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
----------------------------------------------------------------------
diff --git a/bval-tck/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java b/bval-tck/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
new file mode 100644
index 0000000..7ad860c
--- /dev/null
+++ b/bval-tck/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
@@ -0,0 +1,28 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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 License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.bval.arquillian;
+
+import org.jboss.arquillian.core.spi.LoadableExtension;
+import org.jboss.arquillian.test.spi.TestEnricher;
+
+public class BValArquillianExtension implements LoadableExtension {
+ public void register(final ExtensionBuilder builder) {
+ builder.service(TestEnricher.class, EJBEnricher.class);
+ }
+}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
----------------------------------------------------------------------
diff --git a/bval-tck/src/main/java/org/apache/bval/arquillian/EJBEnricher.java b/bval-tck/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
new file mode 100644
index 0000000..da55ba5
--- /dev/null
+++ b/bval-tck/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
@@ -0,0 +1,58 @@
+/*
+* JBoss, Home of Professional Open Source
+* Copyright 2013, Red Hat, Inc. and/or its affiliates, and individual contributors
+* by the @authors tag. See the copyright.txt in the distribution for a
+* full listing of individual contributors.
+*
+* 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 License for the specific language governing permissions and
+* limitations under the License.
+*/
+package org.apache.bval.arquillian;
+
+import org.jboss.arquillian.test.spi.TestEnricher;
+
+import javax.annotation.Resource;
+import javax.ejb.EJB;
+import javax.validation.Validation;
+import javax.validation.Validator;
+import javax.validation.ValidatorFactory;
+import java.lang.reflect.Field;
+import java.lang.reflect.Method;
+
+// mock a very very simple EJB container (in fact only local bean @Resource Validator* injections)
+public class EJBEnricher implements TestEnricher {
+ public void enrich(final Object testCase) {
+ for (final Field field : testCase.getClass().getDeclaredFields()) {
+ if (field.getAnnotation(EJB.class) != null) {
+ try {
+ final Object instance = field.getType().getConstructor().newInstance();
+ for (final Field f : field.getType().getDeclaredFields()) {
+ if (f.getAnnotation(Resource.class) != null) {
+ if (f.getType().equals(Validator.class)) {
+ f.set(instance,
+ Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator());
+ } else if (f.getType().equals(ValidatorFactory.class)) {
+ f.set(instance, Validation.byDefaultProvider().configure().buildValidatorFactory());
+ }
+ }
+ }
+ field.setAccessible(true);
+ field.set(testCase, instance);
+ } catch (final Exception e) {
+ // no-op
+ }
+ }
+ }
+ }
+
+ public Object[] resolve(Method method) {
+ return new Object[0];
+ }
+}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
----------------------------------------------------------------------
diff --git a/bval-tck/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java b/bval-tck/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
new file mode 100644
index 0000000..3b3d71c
--- /dev/null
+++ b/bval-tck/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
@@ -0,0 +1,49 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements. See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership. The ASF licenses this file
+ * to you 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 License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.bval.arquillian.jndi;
+
+import javax.naming.Context;
+import javax.naming.NamingException;
+import javax.naming.spi.InitialContextFactory;
+import javax.validation.Validation;
+import java.lang.reflect.InvocationHandler;
+import java.lang.reflect.Method;
+import java.lang.reflect.Proxy;
+import java.util.Hashtable;
+
+// mock a context to satisfy lookups
+public class BValJndiFactory implements InitialContextFactory {
+ public Context getInitialContext(final Hashtable<?, ?> environment) throws NamingException {
+ return Context.class.cast(Proxy.newProxyInstance(Thread.currentThread().getContextClassLoader(),
+ new Class<?>[] { Context.class }, new InvocationHandler() {
+ public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable {
+ if (method.getName().equals("lookup") && args != null && args.length == 1
+ && String.class.isInstance(args[0])) {
+ if ("java:comp/ValidatorFactory".equals(args[0])) {
+ return Validation.byDefaultProvider().configure().buildValidatorFactory();
+ }
+ if ("java:comp/Validator".equals(args[0])) {
+ return Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator();
+ }
+ }
+ return null;
+ }
+ }));
+ }
+}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
----------------------------------------------------------------------
diff --git a/bval-tck/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension b/bval-tck/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
new file mode 100644
index 0000000..7e1dc48
--- /dev/null
+++ b/bval-tck/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
@@ -0,0 +1 @@
+org.apache.bval.arquillian.BValArquillianExtension
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/bval-tck/src/main/resources/jndi.properties b/bval-tck/src/main/resources/jndi.properties
new file mode 100644
index 0000000..8a42146
--- /dev/null
+++ b/bval-tck/src/main/resources/jndi.properties
@@ -0,0 +1,17 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you 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 License for the
+# specific language governing permissions and limitations
+# under the License.
+java.naming.factory.initial = org.apache.bval.arquillian.jndi.BValJndiFactory
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/src/test/resources/arquillian.xml
----------------------------------------------------------------------
diff --git a/bval-tck/src/test/resources/arquillian.xml b/bval-tck/src/test/resources/arquillian.xml
new file mode 100644
index 0000000..20bb121
--- /dev/null
+++ b/bval-tck/src/test/resources/arquillian.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<!--
+
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You 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 License for the specific language governing permissions and
+ limitations under the License.
+-->
+<arquillian xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://jboss.org/schema/arquillian
+ http://jboss.org/schema/arquillian/arquillian_1_0.xsd">
+ <container qualifier="owb" default="true">
+ <configuration>
+ <property name="useOnlyArchiveResources">true</property>
+ <property name="useOnlyArchiveResourcesExcludes">META-INF/services/javax.validation.spi.ValidationProvider</property>
+ </configuration>
+ </container>
+</arquillian>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck/work-tests-suite.xml
----------------------------------------------------------------------
diff --git a/bval-tck/work-tests-suite.xml b/bval-tck/work-tests-suite.xml
new file mode 100644
index 0000000..3bb8b11
--- /dev/null
+++ b/bval-tck/work-tests-suite.xml
@@ -0,0 +1,30 @@
+<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to you 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 License for
+ the specific language governing permissions and limitations under the
+ License.
+-->
+<!--
+JUST HERE TO BE ABLE TO RUN TCK ONE BY ONE WHEN DEVELOPING
+think to add -Dvalidation.provider=org.apache.bval.jsr.ApacheValidationProvider to your runner config
+-->
+<suite name="tmp" verbose="1">
+ <test name="tmp">
+ <classes>
+ <class name="org.hibernate.beanvalidation.tck.tests.xmlconfiguration.groupconversion.containerelement.XmlBasedContainerElementGroupConversionValidationTest"/>
+<!--
+ <class name="org.hibernate.beanvalidation.tck.tests.util.ConstraintViolationAssertTest"/>
+-->
+ </classes>
+ </test>
+</suite>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/pom.xml
----------------------------------------------------------------------
diff --git a/bval-tck11/pom.xml b/bval-tck11/pom.xml
deleted file mode 100644
index ed72752..0000000
--- a/bval-tck11/pom.xml
+++ /dev/null
@@ -1,247 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
-Licensed to the Apache Software Foundation (ASF) under one
-or more contributor license agreements. See the NOTICE file
-distributed with this work for additional information
-regarding copyright ownership. The ASF licenses this file
-to you 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 License for the
-specific language governing permissions and limitations
-under the License.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
-
- <parent>
- <artifactId>bval-parent</artifactId>
- <groupId>org.apache.bval</groupId>
- <version>2.0.0-SNAPSHOT</version>
- </parent>
-
- <artifactId>bval-tck11-runner</artifactId>
- <name>Apache BVal :: bval-tck11 (TCK Runner)</name>
- <description>Aggregates dependencies and runs the JSR-349 TCK</description>
-
- <properties>
- <tck.version>2.0.2.Final</tck.version>
- <owb.version>2.0.4</owb.version>
- <arquillian.version>1.1.11.Final</arquillian.version>
- <validation.provider>org.apache.bval.jsr.ApacheValidationProvider</validation.provider>
- </properties>
-
- <dependencies>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-validation_2.0_spec</artifactId>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-atinject_1.0_spec</artifactId>
- <version>1.0</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-jcdi_2.0_spec</artifactId>
- <version>1.0</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-annotation_1.3_spec</artifactId>
- <version>1.0</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-interceptor_1.2_spec</artifactId>
- <version>1.0</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.geronimo.specs</groupId>
- <artifactId>geronimo-ejb_3.1_spec</artifactId>
- <version>1.0</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.tomcat</groupId>
- <artifactId>tomcat-el-api</artifactId>
- </dependency>
- <dependency>
- <groupId>org.apache.bval</groupId>
- <artifactId>bval-core</artifactId>
- <version>${project.version}</version>
- <exclusions>
- <exclusion>
- <groupId>org.apache.commons</groupId>
- <artifactId>commons-lang3</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>org.apache.bval</groupId>
- <artifactId>bval-jsr</artifactId>
- <version>${project.version}</version>
- <exclusions>
- <exclusion>
- <groupId>org.apache.commons</groupId>
- <artifactId>commons-lang3</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>org.jboss.arquillian.container</groupId>
- <artifactId>arquillian-container-test-spi</artifactId>
- <version>${arquillian.version}</version>
- </dependency>
- <dependency>
- <groupId>org.apache.openwebbeans.arquillian</groupId>
- <artifactId>owb-arquillian-standalone</artifactId>
- <version>${owb.version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.openwebbeans</groupId>
- <artifactId>openwebbeans-impl</artifactId>
- <version>${owb.version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.apache.tomcat</groupId>
- <artifactId>tomcat-jasper-el</artifactId>
- <version>9.0.5</version>
- <scope>provided</scope>
- </dependency>
- <dependency>
- <groupId>org.hibernate.beanvalidation.tck</groupId>
- <artifactId>beanvalidation-tck-tests</artifactId>
- <version>${tck.version}</version>
- <exclusions>
- <exclusion>
- <groupId>javax.validation</groupId>
- <artifactId>validation-api</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.jboss.spec.javax.interceptor</groupId>
- <artifactId>jboss-interceptors-api_1.2_spec</artifactId>
- </exclusion>
- </exclusions>
- </dependency>
- <dependency>
- <groupId>org.jboss.arquillian.testng</groupId>
- <artifactId>arquillian-testng-container</artifactId>
- <version>${arquillian.version}</version>
- <scope>test</scope>
- </dependency>
- <dependency>
- <groupId>org.jboss.arquillian.protocol</groupId>
- <artifactId>arquillian-protocol-servlet</artifactId>
- <version>${arquillian.version}</version>
- <scope>test</scope>
- </dependency>
-
- <dependency>
- <groupId>org.testng</groupId>
- <artifactId>testng</artifactId>
- <version>6.8.21</version>
- <scope>test</scope>
- </dependency>
- </dependencies>
-
- <profiles>
- <profile>
- <id>tck</id>
- <activation>
- <activeByDefault>true</activeByDefault>
- <property>
- <name>tck11</name>
- </property>
- </activation>
- <build>
- <plugins>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-deploy-plugin</artifactId>
- <configuration>
- <skip>true</skip>
- </configuration>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-dependency-plugin</artifactId>
- <executions>
- <execution>
- <id>copy-tck-test-suite-file</id>
- <phase>generate-test-sources</phase>
- <goals>
- <goal>copy</goal>
- </goals>
- <configuration>
- <stripVersion>true</stripVersion>
- <artifactItems>
- <artifactItem>
- <groupId>org.hibernate.beanvalidation.tck</groupId>
- <artifactId>beanvalidation-tck-tests</artifactId>
- <type>xml</type>
- <classifier>suite</classifier>
- <overWrite>false</overWrite>
- </artifactItem>
- </artifactItems>
- </configuration>
- </execution>
- </executions>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-plugin</artifactId>
- <configuration>
- <suiteXmlFiles>
- <suiteXmlFile>${project.build.directory}/dependency/beanvalidation-tck-tests-suite.xml
- </suiteXmlFile>
- </suiteXmlFiles>
- <systemProperties>
- <property>
- <name>validation.provider</name>
- <value>${validation.provider}</value>
- </property>
- </systemProperties>
- <parallel>methods</parallel>
- <threadCount>4</threadCount>
-
- </configuration>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-surefire-report-plugin</artifactId>
- <executions>
- <execution>
- <id>generate-test-report</id>
- <phase>test</phase>
- <goals>
- <goal>report-only</goal>
- </goals>
- </execution>
- </executions>
- <configuration>
- <outputDirectory>${project.build.directory}/surefire-reports</outputDirectory>
- <outputName>test-report</outputName>
- </configuration>
- </plugin>
- </plugins>
- </build>
- </profile>
- </profiles>
-</project>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
----------------------------------------------------------------------
diff --git a/bval-tck11/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java b/bval-tck11/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
deleted file mode 100644
index 7ad860c..0000000
--- a/bval-tck11/src/main/java/org/apache/bval/arquillian/BValArquillianExtension.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you 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 License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.bval.arquillian;
-
-import org.jboss.arquillian.core.spi.LoadableExtension;
-import org.jboss.arquillian.test.spi.TestEnricher;
-
-public class BValArquillianExtension implements LoadableExtension {
- public void register(final ExtensionBuilder builder) {
- builder.service(TestEnricher.class, EJBEnricher.class);
- }
-}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
----------------------------------------------------------------------
diff --git a/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java b/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
deleted file mode 100644
index da55ba5..0000000
--- a/bval-tck11/src/main/java/org/apache/bval/arquillian/EJBEnricher.java
+++ /dev/null
@@ -1,58 +0,0 @@
-/*
-* JBoss, Home of Professional Open Source
-* Copyright 2013, Red Hat, Inc. and/or its affiliates, and individual contributors
-* by the @authors tag. See the copyright.txt in the distribution for a
-* full listing of individual contributors.
-*
-* 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 License for the specific language governing permissions and
-* limitations under the License.
-*/
-package org.apache.bval.arquillian;
-
-import org.jboss.arquillian.test.spi.TestEnricher;
-
-import javax.annotation.Resource;
-import javax.ejb.EJB;
-import javax.validation.Validation;
-import javax.validation.Validator;
-import javax.validation.ValidatorFactory;
-import java.lang.reflect.Field;
-import java.lang.reflect.Method;
-
-// mock a very very simple EJB container (in fact only local bean @Resource Validator* injections)
-public class EJBEnricher implements TestEnricher {
- public void enrich(final Object testCase) {
- for (final Field field : testCase.getClass().getDeclaredFields()) {
- if (field.getAnnotation(EJB.class) != null) {
- try {
- final Object instance = field.getType().getConstructor().newInstance();
- for (final Field f : field.getType().getDeclaredFields()) {
- if (f.getAnnotation(Resource.class) != null) {
- if (f.getType().equals(Validator.class)) {
- f.set(instance,
- Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator());
- } else if (f.getType().equals(ValidatorFactory.class)) {
- f.set(instance, Validation.byDefaultProvider().configure().buildValidatorFactory());
- }
- }
- }
- field.setAccessible(true);
- field.set(testCase, instance);
- } catch (final Exception e) {
- // no-op
- }
- }
- }
- }
-
- public Object[] resolve(Method method) {
- return new Object[0];
- }
-}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
----------------------------------------------------------------------
diff --git a/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java b/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
deleted file mode 100644
index 3b3d71c..0000000
--- a/bval-tck11/src/main/java/org/apache/bval/arquillian/jndi/BValJndiFactory.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you 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 License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.bval.arquillian.jndi;
-
-import javax.naming.Context;
-import javax.naming.NamingException;
-import javax.naming.spi.InitialContextFactory;
-import javax.validation.Validation;
-import java.lang.reflect.InvocationHandler;
-import java.lang.reflect.Method;
-import java.lang.reflect.Proxy;
-import java.util.Hashtable;
-
-// mock a context to satisfy lookups
-public class BValJndiFactory implements InitialContextFactory {
- public Context getInitialContext(final Hashtable<?, ?> environment) throws NamingException {
- return Context.class.cast(Proxy.newProxyInstance(Thread.currentThread().getContextClassLoader(),
- new Class<?>[] { Context.class }, new InvocationHandler() {
- public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable {
- if (method.getName().equals("lookup") && args != null && args.length == 1
- && String.class.isInstance(args[0])) {
- if ("java:comp/ValidatorFactory".equals(args[0])) {
- return Validation.byDefaultProvider().configure().buildValidatorFactory();
- }
- if ("java:comp/Validator".equals(args[0])) {
- return Validation.byDefaultProvider().configure().buildValidatorFactory().getValidator();
- }
- }
- return null;
- }
- }));
- }
-}
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
----------------------------------------------------------------------
diff --git a/bval-tck11/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension b/bval-tck11/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
deleted file mode 100644
index 7e1dc48..0000000
--- a/bval-tck11/src/main/resources/META-INF/services/org.jboss.arquillian.core.spi.LoadableExtension
+++ /dev/null
@@ -1 +0,0 @@
-org.apache.bval.arquillian.BValArquillianExtension
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/main/resources/jndi.properties
----------------------------------------------------------------------
diff --git a/bval-tck11/src/main/resources/jndi.properties b/bval-tck11/src/main/resources/jndi.properties
deleted file mode 100644
index 8a42146..0000000
--- a/bval-tck11/src/main/resources/jndi.properties
+++ /dev/null
@@ -1,17 +0,0 @@
-# Licensed to the Apache Software Foundation (ASF) under one
-# or more contributor license agreements. See the NOTICE file
-# distributed with this work for additional information
-# regarding copyright ownership. The ASF licenses this file
-# to you 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 License for the
-# specific language governing permissions and limitations
-# under the License.
-java.naming.factory.initial = org.apache.bval.arquillian.jndi.BValJndiFactory
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/src/test/resources/arquillian.xml
----------------------------------------------------------------------
diff --git a/bval-tck11/src/test/resources/arquillian.xml b/bval-tck11/src/test/resources/arquillian.xml
deleted file mode 100644
index 20bb121..0000000
--- a/bval-tck11/src/test/resources/arquillian.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
-<!--
-
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to You 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 License for the specific language governing permissions and
- limitations under the License.
--->
-<arquillian xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
- xsi:schemaLocation="http://jboss.org/schema/arquillian
- http://jboss.org/schema/arquillian/arquillian_1_0.xsd">
- <container qualifier="owb" default="true">
- <configuration>
- <property name="useOnlyArchiveResources">true</property>
- <property name="useOnlyArchiveResourcesExcludes">META-INF/services/javax.validation.spi.ValidationProvider</property>
- </configuration>
- </container>
-</arquillian>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/bval-tck11/work-tests-suite.xml
----------------------------------------------------------------------
diff --git a/bval-tck11/work-tests-suite.xml b/bval-tck11/work-tests-suite.xml
deleted file mode 100644
index 3bb8b11..0000000
--- a/bval-tck11/work-tests-suite.xml
+++ /dev/null
@@ -1,30 +0,0 @@
-<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
-<!--
- Licensed to the Apache Software Foundation (ASF) under one or more
- contributor license agreements. See the NOTICE file distributed with
- this work for additional information regarding copyright ownership.
- The ASF licenses this file to you 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 License for
- the specific language governing permissions and limitations under the
- License.
--->
-<!--
-JUST HERE TO BE ABLE TO RUN TCK ONE BY ONE WHEN DEVELOPING
-think to add -Dvalidation.provider=org.apache.bval.jsr.ApacheValidationProvider to your runner config
--->
-<suite name="tmp" verbose="1">
- <test name="tmp">
- <classes>
- <class name="org.hibernate.beanvalidation.tck.tests.xmlconfiguration.groupconversion.containerelement.XmlBasedContainerElementGroupConversionValidationTest"/>
-<!--
- <class name="org.hibernate.beanvalidation.tck.tests.util.ConstraintViolationAssertTest"/>
--->
- </classes>
- </test>
-</suite>
http://git-wip-us.apache.org/repos/asf/bval/blob/ebc06167/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index 1ea9278..cc73e25 100644
--- a/pom.xml
+++ b/pom.xml
@@ -697,7 +697,7 @@
<module>bval-jsr</module>
<module>bval-json</module>
<module>bval-extras</module>
- <module>bval-tck11</module>
+ <module>bval-tck</module>
<module>bundle</module>
</modules>