@@ -3423,13 +3423,16 @@ mod tests {
34233423 use datafusion:: logical_expr:: ScalarUDF ;
34243424 use datafusion:: physical_plan:: ExecutionPlan ;
34253425 use datafusion:: { assert_batches_eq, physical_plan:: common:: collect, prelude:: SessionContext } ;
3426+ use datafusion_physical_expr_adapter:: PhysicalExprAdapterFactory ;
34263427 use tempfile:: TempDir ;
34273428 use tokio:: sync:: mpsc;
34283429
34293430 use crate :: execution:: { operators:: InputBatch , planner:: PhysicalPlanner } ;
34303431
34313432 use crate :: execution:: operators:: ExecutionError ;
34323433 use crate :: execution:: planner:: literal_to_array_ref;
3434+ use crate :: parquet:: parquet_support:: SparkParquetOptions ;
3435+ use crate :: parquet:: schema_adapter:: SparkPhysicalExprAdapterFactory ;
34333436 use datafusion_comet_proto:: spark_expression:: expr:: ExprStruct ;
34343437 use datafusion_comet_proto:: spark_expression:: ListLiteral ;
34353438 use datafusion_comet_proto:: {
@@ -3439,6 +3442,7 @@ mod tests {
34393442 spark_operator,
34403443 spark_operator:: { operator:: OpStruct , Operator } ,
34413444 } ;
3445+ use datafusion_comet_spark_expr:: EvalMode ;
34423446
34433447 #[ test]
34443448 fn test_unpack_dictionary_primitive ( ) {
@@ -4035,8 +4039,15 @@ mod tests {
40354039 . with_table_parquet_options ( TableParquetOptions :: new ( ) ) ,
40364040 ) as Arc < dyn FileSource > ;
40374041
4042+ let spark_parquet_options = SparkParquetOptions :: new ( EvalMode :: Legacy , "UTC" , false ) ;
4043+
4044+ let expr_adapter_factory: Arc < dyn PhysicalExprAdapterFactory > = Arc :: new (
4045+ SparkPhysicalExprAdapterFactory :: new ( spark_parquet_options, None ) ,
4046+ ) ;
4047+
40384048 let object_store_url = ObjectStoreUrl :: local_filesystem ( ) ;
40394049 let file_scan_config = FileScanConfigBuilder :: new ( object_store_url, source)
4050+ . with_expr_adapter ( Some ( expr_adapter_factory) )
40404051 . with_file_groups ( file_groups)
40414052 . build ( ) ;
40424053
0 commit comments