From e9cf08aff22579d9962ece47ef2e086502a24161 Mon Sep 17 00:00:00 2001 From: Sander van den Hoek Date: Tue, 15 Oct 2024 12:43:00 +0200 Subject: [PATCH] Re-added less-specific test to ensure regex usage does not trigger an error --- .../test/java/org/molgenis/emx2/sql/TestSqlTypeUtils.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/backend/molgenis-emx2-sql/src/test/java/org/molgenis/emx2/sql/TestSqlTypeUtils.java b/backend/molgenis-emx2-sql/src/test/java/org/molgenis/emx2/sql/TestSqlTypeUtils.java index 15131ef7f4..4b5f25e55c 100644 --- a/backend/molgenis-emx2-sql/src/test/java/org/molgenis/emx2/sql/TestSqlTypeUtils.java +++ b/backend/molgenis-emx2-sql/src/test/java/org/molgenis/emx2/sql/TestSqlTypeUtils.java @@ -68,4 +68,11 @@ void testArrayConversionToMap() { () -> assertEquals(List.of("aa", "bb"), Arrays.asList((String[]) output.get("sTRINGArray")))); } + + @Test + void testWorkingValidationForEmailArray() { + List columns = List.of(column("SPAM blocklist", ColumnType.EMAIL_ARRAY)); + Row row = row("SPAM blocklist", "bob@example.com,ros@example.com"); + assertDoesNotThrow(() -> applyValidationAndComputed(columns, row)); + } }