Omega359 commented on code in PR #9137:
URL: https://github.com/apache/arrow-datafusion/pull/9137#discussion_r1482959000


##########
datafusion/physical-expr/src/regex_expressions.rs:
##########
@@ -332,10 +482,70 @@ pub fn specialize_regexp_replace<T: OffsetSizeTrait>(
 
 #[cfg(test)]
 mod tests {
-    use super::*;
     use arrow::array::*;
+
     use datafusion_common::ScalarValue;
 
+    use super::*;
+
+    #[test]
+    fn test_case_sensitive_regexp_like() {
+        let values = StringArray::from(vec!["abc"; 5]);
+
+        let patterns =
+            StringArray::from(vec!["^(a)", "^(A)", "(b|d)", "(B|D)", 
"^(b|c)"]);
+
+        let mut expected_builder: BooleanBuilder = BooleanBuilder::new();
+        expected_builder.append_value(true);
+        expected_builder.append_value(false);
+        expected_builder.append_value(true);
+        expected_builder.append_value(false);
+        expected_builder.append_value(false);
+        let expected = expected_builder.finish();

Review Comment:
   This is just me copy/pasting from some other bit of code and not thinking 
too much about it. I am still getting used to Rust's way of doing things :)



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to