From ffd22681cdc660fa16fcfc1dbed466f0db8acced Mon Sep 17 00:00:00 2001 From: Thomas Heigl Date: Sun, 11 Jul 2021 11:57:53 +0200 Subject: [PATCH] HHH-14724 Test-case demonstrating compilation issues with converters and validation --- tooling/metamodel-generator/hibernate-jpamodelgen.gradle | 1 + .../hibernate/jpamodelgen/test/collectionbasictype/Goods.java | 2 ++ 2 files changed, 3 insertions(+) diff --git a/tooling/metamodel-generator/hibernate-jpamodelgen.gradle b/tooling/metamodel-generator/hibernate-jpamodelgen.gradle index 6b979a476f..e6b7fde363 100644 --- a/tooling/metamodel-generator/hibernate-jpamodelgen.gradle +++ b/tooling/metamodel-generator/hibernate-jpamodelgen.gradle @@ -30,6 +30,7 @@ dependencies { testCompile libraries.junit testCompile libraries.jpa + testCompile libraries.validation testCompile project( ':hibernate-core' ) } diff --git a/tooling/metamodel-generator/src/test/java/org/hibernate/jpamodelgen/test/collectionbasictype/Goods.java b/tooling/metamodel-generator/src/test/java/org/hibernate/jpamodelgen/test/collectionbasictype/Goods.java index b494b62fe0..c1ddafefe9 100644 --- a/tooling/metamodel-generator/src/test/java/org/hibernate/jpamodelgen/test/collectionbasictype/Goods.java +++ b/tooling/metamodel-generator/src/test/java/org/hibernate/jpamodelgen/test/collectionbasictype/Goods.java @@ -10,6 +10,7 @@ import javax.persistence.Convert; import javax.persistence.Entity; import javax.persistence.Id; import javax.persistence.OneToMany; +import javax.validation.constraints.NotNull; import java.util.List; /** @@ -39,6 +40,7 @@ public class Goods { this.productList = productList; } + @NotNull @Convert(converter = StringToListConverter.class) public List getTags() { return tags;