alamb commented on code in PR #20066:
URL: https://github.com/apache/datafusion/pull/20066#discussion_r2742861761
##########
datafusion/core/tests/physical_optimizer/limit_pushdown.rs:
##########
@@ -98,27 +98,34 @@ fn nested_loop_join_exec(
)?))
}
+fn format_plan(plan: &Arc<dyn ExecutionPlan>) -> String {
+ get_plan_string(plan).join("\n")
+}
+
#[test]
fn transforms_streaming_table_exec_into_fetching_version_when_skip_is_zero()
-> Result<()>
{
let schema = create_schema();
let streaming_table = stream_exec(&schema);
let global_limit = global_limit_exec(streaming_table, 0, Some(5));
- let initial = get_plan_string(&global_limit);
- let expected_initial = [
- "GlobalLimitExec: skip=0, fetch=5",
- " StreamingTableExec: partition_sizes=1, projection=[c1, c2, c3],
infinite_source=true",
- ];
- assert_eq!(initial, expected_initial);
+ let initial = format_plan(&global_limit);
+ insta::assert_snapshot!(
Review Comment:
The point is to use this alternate format which is easier to update and to
diff
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]