pinot-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From apuc...@apache.org
Subject [incubator-pinot] 01/01: add groovy unit test for sha256 data masking
Date Mon, 19 Jul 2021 19:43:45 GMT
This is an automated email from the ASF dual-hosted git repository.

apucher pushed a commit to branch groovy-data-masking-unit-test
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git

commit a72ecd71839379a4abdd55ab9af5a166dd1e9ee0
Author: Alexander Pucher <alex@alexpucher.com>
AuthorDate: Mon Jul 19 12:43:19 2021 -0700

    add groovy unit test for sha256 data masking
---
 .../apache/pinot/core/data/function/GroovyFunctionEvaluatorTest.java  | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/pinot-core/src/test/java/org/apache/pinot/core/data/function/GroovyFunctionEvaluatorTest.java
b/pinot-core/src/test/java/org/apache/pinot/core/data/function/GroovyFunctionEvaluatorTest.java
index c5086c3..46f1209 100644
--- a/pinot-core/src/test/java/org/apache/pinot/core/data/function/GroovyFunctionEvaluatorTest.java
+++ b/pinot-core/src/test/java/org/apache/pinot/core/data/function/GroovyFunctionEvaluatorTest.java
@@ -83,6 +83,10 @@ public class GroovyFunctionEvaluatorTest {
     genericRow7.putValue("eventType", "CLICK");
     entries.add(new Object[]{"Groovy({eventType == 'IMPRESSION' ? 1: 0}, eventType)", Lists.newArrayList("eventType"),
genericRow7, 0});
 
+    GenericRow genericRow8 = new GenericRow();
+    genericRow8.putValue("ssn", "123-45-6789");
+    entries.add(new Object[]{"Groovy({org.apache.commons.codec.digest.DigestUtils.sha256Hex(ssn)},
ssn)", Lists.newArrayList("ssn"), genericRow8, "01a54629efb952287e554eb23ef69c52097a75aecc0e3a93ca0855ab6d7a31a0"});
+
     return entries.toArray(new Object[entries.size()][]);
   }
 }

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org


Mime
View raw message