You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/08/13 15:06:36 UTC

[GitHub] [arrow] alamb commented on a change in pull request #7949: ARROW-9714: [Rust] [DataFusion] Implement type coercion rule for limit and sort

alamb commented on a change in pull request #7949:
URL: https://github.com/apache/arrow/pull/7949#discussion_r470022124



##########
File path: rust/datafusion/src/optimizer/type_coercion.rs
##########
@@ -183,10 +192,42 @@ mod tests {
     use super::*;
     use crate::execution::context::ExecutionContext;
     use crate::execution::physical_plan::csv::CsvReadOptions;
-    use crate::logicalplan::{col, Operator};
+    use crate::logicalplan::{aggregate_expr, col, lit, Operator};
     use crate::test::arrow_testdata_path;
     use arrow::datatypes::{DataType, Field, Schema};
 
+    #[test]
+    fn test_all_operators() -> Result<()> {
+        let testdata = arrow_testdata_path();
+        let path = format!("{}/csv/aggregate_test_100.csv", testdata);
+
+        let options = CsvReadOptions::new().schema_infer_max_records(100);
+        let plan = LogicalPlanBuilder::scan_csv(&path, options, None)?
+            // filter clause needs the type coercion rule applied

Review comment:
       If you desire to test all operators, as the test is named, perhaps adding `Projection` would also be valuable




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org