wiedld commented on code in PR #13866: URL: https://github.com/apache/datafusion/pull/13866#discussion_r1894526384
########## datafusion/core/src/datasource/file_format/parquet.rs: ########## @@ -2335,42 +2347,64 @@ mod tests { async fn parquet_sink_write() -> Result<()> { let parquet_sink = create_written_parquet_sink("file:///").await?; - // assert written - let mut written = parquet_sink.written(); - let written = written.drain(); - assert_eq!( - written.len(), - 1, - "expected a single parquet files to be written, instead found {}", - written.len() - ); + // assert written to proper path + let (path, file_metadata) = get_written(parquet_sink)?; + let path_parts = path.parts().collect::<Vec<_>>(); + assert_eq!(path_parts.len(), 1, "should not have path prefix"); Review Comment: I refactored the tests first, into a series of helpers. May be easier to review in this commit: https://github.com/apache/datafusion/pull/13866/commits/09004c56e6e4b96d3767e03a81f3eb228b3529f1 -- 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: github-unsubscr...@datafusion.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org